From 267d18b483d62ff5a9b65660287e7f0d88035d19 Mon Sep 17 00:00:00 2001 From: Brett Weiland Date: Thu, 15 Oct 2020 09:00:37 -0500 Subject: new file: ewd --- ewd | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100755 ewd diff --git a/ewd b/ewd new file mode 100755 index 0000000..a745f3c --- /dev/null +++ b/ewd @@ -0,0 +1,19 @@ +#!/bin/bash +pass="no_fuck_YOUR_chicken_strips_you_whore" +email_to="19132286776@messaging.sprintpcs.com" +$@ +return_code=$? +echo "Command has completed. Now notifying..." +if [ $return_code -eq 0 ]; then + ssmtp $email_to -ap $pass << EOF +To: $email_to +From: bpc_courier@bpcspace.com +The command "$@" completed successfully. Congrats. +EOF +else + ssmtp $email_to -ap $pass << EOF +To: $email_to +From: bpc_courier@bpcspace.com +The command "$@" has failed with error code $return_code. Sorry... :( +EOF +fi -- cgit v1.2.3