added audio repo in backup script

This commit is contained in:
2024-02-12 00:34:36 +01:00
parent 83de6e9837
commit d4e70e33f5
2 changed files with 9 additions and 2 deletions

View File

@@ -47,6 +47,7 @@ borg create --progress --stats --exclude-caches \
--exclude $HOME/tmp \ --exclude $HOME/tmp \
--exclude $HOME/.local/Steam \ --exclude $HOME/.local/Steam \
--exclude $HOME/.local/share/Steam \ --exclude $HOME/.local/share/Steam \
--exclude $HOME/Audio \
$ARCHIVE $SRC && if ! $LOCAL; then date +%s > $HOME/.lastbak; fi $ARCHIVE $SRC && if ! $LOCAL; then date +%s > $HOME/.lastbak; fi
@@ -63,9 +64,14 @@ then
echo "backing up Photo archive..." echo "backing up Photo archive..."
cd "/run/media/$USER/$DISK/photos" cd "/run/media/$USER/$DISK/photos"
git annex sync git annex sync
set +e # set +e
git annex mirror --from=origin
# set -e
git annex sync
echo "backing up Audio archive..."
cd "/run/media/$USER/$DISK/audio"
git annex sync
git annex mirror --from=origin git annex mirror --from=origin
set -e
git annex sync git annex sync
cd / cd /
udisksctl unmount -b "/dev/disk/by-label/$DISK" udisksctl unmount -b "/dev/disk/by-label/$DISK"

View File

@@ -12,6 +12,7 @@
home.stateVersion = "23.11"; # Please read the comment before changing. home.stateVersion = "23.11"; # Please read the comment before changing.
home.packages = with pkgs; [ home.packages = with pkgs; [
openssl
feh feh
killall killall
sshfs sshfs