aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Robin Obůrka <r.oburka@gmail.com> 2016-08-01 19:30:19 +0200
committerGravatar Robin Obůrka <r.oburka@gmail.com> 2016-08-01 19:30:19 +0200
commit7e206ce3995e080907ddb1a75ca779aff9b3c5b6 (patch)
treeeeeeb473262f6a958691b422af0bb0acfd75b625
parentAdd some more variables to initialization (diff)
downloadbackuper-7e206ce3995e080907ddb1a75ca779aff9b3c5b6.tar.xz
Enable run command only after backup specification
-rw-r--r--backuper.sh1
1 files changed, 1 insertions, 0 deletions
diff --git a/backuper.sh b/backuper.sh
index 826e34a..a354c06 100644
--- a/backuper.sh
+++ b/backuper.sh
@@ -149,6 +149,7 @@ after() {
}
run() {
+ [ -z "$COMMAND" -a -z "$PLACES" ] && error "Specify backup before run command"
title "Run command"
echo "$@"
echo $@ | /usr/bin/time -f "$(time_fmt "Command took")" $REMOTE sh -s