Remove bogus local declaration in send-pushover

This commit is contained in:
cimryan
2018-10-24 19:55:56 -07:00
parent 8d2d6f9cb8
commit 2915ca8e01

View File

@@ -1,13 +1,13 @@
#!/bin/bash -eu #!/bin/bash -eu
local num_files_moved="$1" NUM_FILES_MOVED="$1"
function log () { function log () {
echo "$( date )" >> "$LOG_FILE" echo "$( date )" >> "$LOG_FILE"
echo "$1" >> "$LOG_FILE" echo "$1" >> "$LOG_FILE"
} }
if [ -r "/root/.teslaCamPushoverCredentials" ] && [ $num_files_moved > 0] if [ -r "/root/.teslaCamPushoverCredentials" ] && [ $NUM_FILES_MOVED > 0]
then then
log "Sending Pushover message for moved files." log "Sending Pushover message for moved files."
@@ -16,6 +16,6 @@ then
curl -F "token=$pushover_app_key" \ curl -F "token=$pushover_app_key" \
-F "user=$pushover_user_key" \ -F "user=$pushover_user_key" \
-F "title=Dashcam Copy Complete" \ -F "title=Dashcam Copy Complete" \
-F "message=$num_files_moved file(s) were copied." \ -F "message=$NUM_FILES_MOVED file(s) were copied." \
https://api.pushover.net/1/messages https://api.pushover.net/1/messages
fi fi