ps ax | grep [h]podder > /dev/null 2>&1 if [ $? -eq 0 ]; then echo "hi" fi #hpodder > ~/tmp/hpodder Output to stdout: "hi" No errors!