3
I've a Synology NAS running DSM. I've created a bash script to check if a certain file is present within a certain folder. The script runs by a schedule and returns the result to me by email.
The problem is I get too many emails just saying the script ran ok.
The DSM task scheduler allows to send the email only if script terminates abnormally.
My question is: how can I force the script to terminate abnormally?
I would do so in order to get an email if the file I'm looking for doesn't exist.