bin/barg: add

This commit is contained in:
xeruf 2021-11-07 04:05:53 +01:00
parent 6879d89e88
commit 7a31182526
1 changed files with 6 additions and 0 deletions

6
.local/bin/scripts/barg Executable file
View File

@ -0,0 +1,6 @@
#!/bin/sh
# Backup root filesystem with borg
cd /
sudo borg create --progress --stats \
$(echo $IGNOREDIRS_PURE -x 'software-challenge/*/build' -x 'emacs/.local' | sed 's|-x \([^ ]\+\)|-e */\1 -e \1|g') \
/mnt/backup/borg::$(hostname)-system-$(date -u +"%y%m%d") etc home root