]> git.treefish.org Git - backmeupscotty.git/blobdiff - backmeupscotty
removed script name from loglines
[backmeupscotty.git] / backmeupscotty
index dd1471123bf372d0b60455d4b0a1ea9dee9eb5ca..ff0f07ffa66104a53932bc3d428a61f0bdf80ee0 100644 (file)
@@ -7,14 +7,13 @@ ARCHIVE_KEEPNDAYS=30
 BACKUP_RUNEVERYNTHDAY=1
 
 _ERROR_ENCOUNTERED=0
-_UPPERME=$(echo $(basename $0) | tr '[:lower:]' '[:upper:]')
 
 function timestamp {
     date +'[%y-%m-%d|%H:%M:%S]'
 }
 
 function scottyline {
-    echo $(timestamp) $_UPPERME: $@
+    echo $(timestamp) $@
 }
 
 function scottyinfo {
@@ -27,7 +26,10 @@ function scottyinfo {
 
 function scottyerror {
     scottyline $@ >&2
-    _ERROR_ENCOUNTERED=1
+    if [ $_ERROR_ENCOUNTERED -eq 0 ]; then
+       _ERROR_ENCOUNTERED=1
+       scottyline "Going into verbose mode after error encounter." >&2
+    fi
 }
 
 function ssh255 {