June 2006
Intermediate to advanced
64 pages
2h 42m
English
:
:
Null command. Returns an exit status of 0. See this Example and the ones under case. The line is still processed for side effects, such as variable and command substitutions, or I/O redirection.
Check whether someone is logged in:
if who | grep $1 > /dev/null then : # Do nothing if user is found else echo "User $1 is not logged in" fi
Read now
Unlock full access