X-Git-Url: http://rtime.felk.cvut.cz/gitweb/novaboot.git/blobdiff_plain/939b83b12b95e44031e85883354cae18498c8506..6dcb21a0b297867324ee581a6a5306afbd965577:/server/novaboot-shell diff --git a/server/novaboot-shell b/server/novaboot-shell index 72d6d1d..846ea1b 100755 --- a/server/novaboot-shell +++ b/server/novaboot-shell @@ -113,6 +113,20 @@ run_console() { eval "$1" } +# Run novaboot with the same configuration as specified in +# ~/.novaboot-shell, but allow the caller to extend of override them +# via parameters of this function. +run_novaboot() { + nbscript=$1 + shift + OLD_IFS=$IFS + # Split $target_config below by newlines, not by words + IFS=" +" + novaboot "$nbscript" $target_config --server="$HOME/tftproot" --reset-cmd="${reset_cmd:?}" --remote-cmd="${console_cmd:?}" "$@" + IFS=$OLD_IFS +} + # run_subcommand should be called only after permission checks and/or locking run_subcommand() { read_config