aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xbin/cron13
1 files changed, 12 insertions, 1 deletions
diff --git a/bin/cron b/bin/cron
index 3df00548c5b..9ade7a06a49 100755
--- a/bin/cron
+++ b/bin/cron
@@ -3,4 +3,15 @@
# Arquivo automatic syncronizer.
#
-cd /var/cache/sites/arquivo && /usr/bin/ionice -c 3 /usr/bin/nice -n 19 /usr/bin/git annex add . && /usr/bin/ionice -c 3 /usr/bin/nice -n 19 /usr/bin/git annex sync &> /dev/null
+# Parameters
+CWD="`/bin/pwd`"
+GIT="/usr/bin/git"
+NICE="/usr/bin/nice -n 19"
+IONICE="/user/bin/ionice -c 3"
+ARCHIVE="/var/cache/sites/arquivo"
+
+# Run
+cd $ARCHIVE
+$IONICE $NICE $GIT annex add . && \
+$IONICE $NICE $GIT annex sync &> /dev/null
+cd $CWD