This commit is contained in:
2022-01-20 22:46:18 -08:00
parent a13c18f93d
commit 60be955549
5 changed files with 72 additions and 3 deletions

View File

@@ -0,0 +1,37 @@
HOMEEXCLUDE := --exclude /.Trash \
--exclude .DS_Store \
--exclude /.Spotlight-V100 \
--exclude /.cache \
--exclude /.fseventsd \
--exclude /Library/Caches \
--exclude /Library/Mail \
--exclude /Library/Metadata/CoreSpotlight \
--exclude /tmp
ROOTEXCLUDE := --exclude /.Trash \
--exclude /proc \
--exclude /dev \
--exclude /.fseventsd \
--exclude .DS_Store \
--exclude /System/Volumes/Data/Volumes \
--exclude /private/var/vm \
--exclude /System/Volumes/Data/nix \
--exclude System/Volumes/Data/Users/sneak \
--exclude /System/Volumes/Data/.fseventsd \
--exclude /System/Volumes/Data/.Spotlight-V100 \
--exclude /System/Volumes/Data/private/var/folders \
--exclude /Volumes
OPTS := -avP --delete --delete-excluded --delete-before
HOMEOPTS := $(OPTS) $(HOMEEXCLUDE)
ROOTOPTS := $(OPTS) $(ROOTEXCLUDE)
default: synchome syncroot
synchome:
rsync $(HOMEOPTS) $(HOME)/ ./2021-01-12.nostromo.sneakhome/ | tee -a $(shell date +%Y-%m-%d).homesync.log
syncroot:
rsync $(ROOTOPTS) / ./2021-01-12.nostromo.root/ | tee -a $(shell date +%Y-%m-%d).rootsync.log

View File

@@ -0,0 +1,21 @@
#!/bin/bash
DST="root@lstor1.local:/srv/lstor1/backup/temp-nostromo-migration"
SRC=""
sudo rsync -avP \
--delete --delete-excluded \
--exclude /proc \
--exclude /dev \
--exclude /.fseventsd \
--exclude /private/var/vm \
--exclude /System/Volumes/Data/Volumes \
--exclude /System/Volumes/Data/nix \
--exclude /System/Volumes/Data/.fseventsd \
--exclude /System/Volumes/Data/.Spotlight-V100 \
--exclude /System/Volumes/Data/Users/sneak/.Trash \
--exclude /System/Volumes/Data/Users/sneak/.cache \
--exclude /System/Volumes/Data/Users/sneak/Library/Caches \
--exclude /System/Volumes/Data/private/var/folders \
--exclude /Volumes \
"$SRC"/ "$DST"/