Script for Pushover notification in shell
pushover [ -t <title> -u <user_key> -a <app_token> -s <sound> ] [message]
Flags:
- -t title: add a message title
- -u user_key: ovverride
USER_KEYvariable. This is mandatory ifUSER_KEYis empty - -a app_token: ovverride
APP_TOKENvariable. This is mandatory ifAPP_TOKENis empty - -s sound: specify the sound to use for your message (default sound: pushover)
- -d: dryrun
The message is optional: if empty the value of DEFAULT_MESSAGE variable is sent (default: "Shell Message")
pushover -u <user_key> -a <app_key> this is my messageIf USER_KEY and APP_TOKEN variables are not empty you can omit "-u" and "-a" parameters:
pushover this is my messageYou can send message with command standard output:
echo "this is the output of my command" | pushover -t "Long command complete"