Hi,
"die" in perl can print an error message as well as set the return
code of the perl script. I frequently need to print an error message
and exit with the last error code. I'd like to make it one line. Is it
possible in bash?
prog_to_fail || exit $? # how to print an error message as well exit
with the last status code?
--
Regards,
Peng