First page Back Continue Last page Overview Graphics
Commands and Operators
Many built-in commands available. “man bash” contains complete list. “help <command>” gives usage info for each command, or just “help” to list built-ins.
Some commands exist as both built-in and separate binaries, i.e.: true, test, time (use “type” command)
There aren't really “operators” in bash, but the test command, abbreviated as [, gives illusion
- MHZ=$(grep "cpu MHz" /proc/cpuinfo | cut -d : -f2)
- MHZINT=`awk -F. '{print $0}'`
- if [ $MHZINT -lt 500 ]
- then
- echo “Your machine is slow. Blame jtate."
- fi
$() and `` converts commands' standard out into args.
- grep :`id -g`: /etc/passwd
Notes: