I wanted to know if it was possible to code that kind of line in a BASH program I would like to have something that looks like:
if set -e
echo "Error"
fi
Actually my teacher just told that set -e stops the program when there is an error. I don't really know how it works. What I want is that when there is an error at any part of the program it does echo "Error"
I'm just learning how to use bash so my knowledge isn't very good yet.