Created
March 16, 2016 05:34
-
-
Save vadixidav/038a8b3b2aea468983d6 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| for var in "$@" | |
| do | |
| echo "Syncing directory \"$(realpath "${var}")\" to \"/mnt/external/${var}\"" | |
| rsync -a --delete --progress "${var}" "/mnt/external/" | |
| done | |
| sudo btrfs subvolume snapshot -r /mnt/external/ "/mnt/external/snapshot/$(date +%F)" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment