Source:
run_some_command EXIT_STATUS=$? if [ "$EXIT_STATUS" -eq "0" ] then # Do work when command exists on success else # Do work for when command has a failure exit fi
#Alternatively:
if run_some_command then # Do work when command exists on success else # Do failure exit work fi
No comments:
Post a Comment