diff --git a/bin/backup.sh b/bin/backup.sh new file mode 100755 index 0000000..3003501 --- /dev/null +++ b/bin/backup.sh @@ -0,0 +1,15 @@ +#!/bin/bash +set -aeou pipefail + +RESTIC=/usr/bin/restic + +# some helpers and error handling: +trap 'echo $( date ) Backup interrupted >&2; exit 2' INT TERM + +# shellcheck disable=SC1090 +source "${HOME}"/.restic/restic.env + +$RESTIC backup \ + --exclude-file="$HOME"/.restic/excludes.txt \ + --files-from="$HOME"/.restic/includes.txt \ + --verbose