adding a script for archiving our trac repository.
[feisty_meow.git] / scripts / archival / backup_trac.sh
diff --git a/scripts/archival/backup_trac.sh b/scripts/archival/backup_trac.sh
new file mode 100755 (executable)
index 0000000..950c7c9
--- /dev/null
@@ -0,0 +1,16 @@
+#!/bin/bash
+
+# backs up our trac repository.
+
+trac_path="$1"; shift
+
+if [ -z "$trac_path" ]; then
+  echo This script needs the path to the trac database.
+  exit 1
+fi
+
+sep='_'
+
+tar -czf /z/stuffing/archives/trac_bkup_$(date +"%Y$sep%m$sep%d$sep%H%M$sep%S" | tr -d '/\n/').tar.gz "$trac_path" &>$TMP/zz_backup_trac.log
+
+