++ restic direct option
All checks were successful
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in -4s

This commit is contained in:
Nico Schottelius 2024-09-18 16:21:41 +09:00
parent efcbf765bf
commit 59889c29c4

View file

@ -21,6 +21,10 @@ repo=s3:${endpoint}/${bucket_name}/restic
export RESTIC_PASSWORD="$(pass git co nico-privat >/dev/null 2>&1; pass notebook/restic-password)"
# Allow sing restic directly
if [ $# -ge 1 ]; then
restic -r ${repo} "$@"
else
restic -r ${repo} backup \
--exclude ~/Nextcloud \
--exclude ~/Downloads \
@ -32,3 +36,4 @@ restic -r ${repo} backup \
~/
restic -r ${repo} forget --keep-last 20 --prune
fi