X-Git-Url: http://git.ozlabs.org/?a=blobdiff_plain;f=utils%2Fpb-console;h=ef9ed0f61d455a8fc85757611d0dab374fa8e90c;hb=f110c98b582be12c9d4ac4a13a7bf5aff2b7dd57;hp=00b25acf44c8d996bafaf178673805766a0f88b0;hpb=6e2d2e78a178a40bcbce903020626c62f74bf046;p=petitboot diff --git a/utils/pb-console b/utils/pb-console index 00b25ac..ef9ed0f 100644 --- a/utils/pb-console +++ b/utils/pb-console @@ -6,63 +6,139 @@ ui=petitboot-nc shell=sh - +getty=/sbin/getty +use_getty=0 detach=0 +pb_config=pb-config usage() { cat >&2 <$console 2>&1 + PATH=/usr/bin:/usr/sbin:/bin:/sbin fi +PATH=/var/lib/pb-plugins/bin:$PATH +export PATH -if [ "$detach" = 1 ] +verbose_opt= +if $pb_config debug | grep -q enabled then - ( - pb_loop - ) & -else - pb_loop + verbose_opt=--verbose fi + +# kernel messages may write over the ncurses ui - change log level to only +# show particularly important messages +dmesg -n 1 + +while : +do + $ui $verbose_opt + reset + echo "Exiting petitboot. Type 'exit' to return." + echo "You may run 'pb-sos' to gather diagnostic data" + $shell +done