commit 3900adb86d5c283db6a018ad083dc23a38f1b7b9 parent 0bda55bd9b164391558336eca876ba6992a05f7e Author: GeaRSiX <gearsix@tuta.io> Date: Sat, 8 Feb 2020 14:07:31 +0000 added src/backup.sh small bugfix on src/while-true.sh Diffstat:
A | src/backup.sh | | | 7 | +++++++ |
M | src/while-true.sh | | | 2 | +- |
2 files changed, 8 insertions(+), 1 deletion(-)
diff --git a/src/backup.sh b/src/backup.sh @@ -0,0 +1,7 @@ +#!/bin/sh +# backup +# description: backup $1 to $1.bak +# e.g.$ backup ~/.bashrc + +cp $1 $1.bak + diff --git a/src/while-true.sh b/src/while-true.sh @@ -6,7 +6,7 @@ while [ true ]; do clear $1 - if [[ -e $2 ]]; then + if [ $2 ]; then sleep $2 else sleep 1