mirror of
https://git.yoctoproject.org/poky
synced 2026-05-01 15:32:12 +02:00
Cleanup the whitespace in functions, replace the 4 whitespaces indent with tab. (From OE-Core rev: 60df57a54ebfe8fa1c1574bcd7900c58810aa2d2) Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
393 B
393 B
--Shell-script--
functions This file contains functions to be used by most or all
shell scripts in the /etc/init.d directory.
machine_id() { # return the machine ID
awk 'BEGIN { FS=": " } /Hardware/
{ gsub(" ", "_", $2); print tolower($2) } ' </proc/cpuinfo
}
killproc() { # kill the named process(es)
pid=/bin/pidof $1
[ "$pid" != "" ] && kill $pid
}