make log-once be script instead of function
authorIan Kelling <ian@iankelling.org>
Wed, 24 Aug 2016 06:43:18 +0000 (23:43 -0700)
committerIan Kelling <ian@iankelling.org>
Wed, 24 Aug 2016 06:43:18 +0000 (23:43 -0700)
log-once [moved from log-once-function with 98% similarity, mode: 0755]

old mode 100644 (file)
new mode 100755 (executable)
similarity index 98%
rename from log-once-function
rename to log-once
index abbec8b..f8938c8
+++ b/log-once
@@ -90,11 +90,13 @@ state in the same directory.
             $out $file <<<"${output[@]}"
             $out $file
         fi
-        exit 1
+        return 1
     elif [[ -f $c$errors ]]; then
         echo "log-once success after failure for $c"
         rm -f $c$errors
     else
         rm -f $c[0-9]* # assuming  no one is putting crazy files names, as this is not exact
     fi
+    return 0
 }
+log-once "$@"