2 ms·
I imagine most people have sets of macros they habitually add to any sufficiently complex script they're modifying... yelp(){ es=$1 shift echo "$
by cduzz 3y ago
I imagine most people have sets of macros they habitually add to any sufficiently complex script they're modifying...
yelp(){
es=$1
shift
echo "$@" >&2
exit $es
}
test -d /tmp/goober || yelp 33 "couldn't find goober!"
(yes, I'm sure there are standards for exit status ranges and 33 is not such a thing)