X-Git-Url: https://feistymeow.org/gitweb/?a=blobdiff_plain;f=scripts%2Farchival%2Fbackup_trac.sh;h=f96e5ae5acbf4cd868a13f45dd82c231a47bd80d;hb=cda88dd71737e14cbe882c550fc14d6e44d9c13a;hp=950c7c9b84e23e852e76566cca956f44a6b1a546;hpb=8fb860c4200e4a59eee541b10ceb6ff3570ac175;p=feisty_meow.git diff --git a/scripts/archival/backup_trac.sh b/scripts/archival/backup_trac.sh old mode 100755 new mode 100644 index 950c7c9b..f96e5ae5 --- a/scripts/archival/backup_trac.sh +++ b/scripts/archival/backup_trac.sh @@ -1,16 +1,13 @@ #!/bin/bash -# backs up our trac repository. +# backs up a trac repository into a tar.gz file. -trac_path="$1"; shift - -if [ -z "$trac_path" ]; then - echo This script needs the path to the trac database. - exit 1 -fi +export WORKDIR="$( \cd "$(\dirname "$0")" && \pwd )" # obtain the script's working directory. -sep='_' +trac_path="$1"; shift +archive_path="$1"; shift -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 +# call our arbitrary backer upper, since this is a simple single directory case. +bash $WORKDIR/backup_arbitrary.sh "$trac_path" "$archive_path" "trac_bkup"