I\'m writing a script to download a bunch of files, and I want it to inform when a particular file doesn\'t exist.
r=`wget -q www.someurl.com` if [ $r -ne 0
$r is the text output of wget (which you've captured with backticks). To access the return code, use the $? variable.
$r
$?