From 7aa35636ce07183d3eaba3921b7a61be98e5cb74 Mon Sep 17 00:00:00 2001 From: Starbeamrainbowlabs Date: Sun, 4 Dec 2016 09:56:50 +0000 Subject: [PATCH] Update backup script --- backup | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/backup b/backup index b0ac32d..b1cb357 100755 --- a/backup +++ b/backup @@ -3,12 +3,18 @@ if [[ -z "$1" ]] then echo Error: Not settings file specified! + echo Settings files are located in ~/.config/backups. + echo To use one, simply specify it\'s name. e.g. \'backup riftgate\' would use the \'~/.config/riftgate.config\' backup configuration file. exit fi -. "$1" +CONFIG_FILE=~/.config/backups/$1.config -echo "Backing up to ${BACKUP_DIRECTORY}." +echo Using config file ${CONFIG_FILE}. + +. "${CONFIG_FILE}" + +echo "Backing '${SOURCE_DIRECTORY}' up to '${BACKUP_DIRECTORY}'." if [[ ! -w "${BACKUP_DIRECTORY}" ]] then