14 lines
262 B
Bash
14 lines
262 B
Bash
# vim: set ft=sh:
|
|
|
|
cmdline_param ()
|
|
{
|
|
read cmdline < /proc/cmdline
|
|
for param in ${cmdline}; do
|
|
case "${param}" in
|
|
$1=*) echo "${param##*=}"; break ;;
|
|
*) continue ;;
|
|
esac
|
|
done
|
|
[ -n "${2}" ] && echo "${2}"
|
|
}
|