]> git.ozlabs.org Git - petitboot/blob - utils/pb-sysinfo
ui/ncurses: unpost ncurses menu in pmenu cleanup path
[petitboot] / utils / pb-sysinfo
1 #!/bin/sh
2
3 case "$1" in
4 '--type')
5         tr -d '\0' < /proc/device-tree/model
6         ;;
7 '--id')
8         tr -d '\0' < /proc/device-tree/system-id
9         ;;
10 '--debug-enabled')
11         exec >/dev/null 2>&1
12         nvram --print-config=petitboot,debug? | grep -q true && exit 0
13         grep -Fq petitboot.debug /proc/cmdline && exit 0
14         exit 1
15         ;;
16 esac