X-Git-Url: https://feistymeow.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=scripts%2Fcustomize%2Ffred%2Fscripts%2Farchival%2Fupdate_soapbox.sh;fp=scripts%2Fcustomize%2Ffred%2Fscripts%2Farchival%2Fupdate_soapbox.sh;h=5e1b98cc88806b82177763810eb22ef4fd1bf2db;hb=81a3f3b9ce06d5e9f179da2dcfdac07ec1fe0ac4;hp=0000000000000000000000000000000000000000;hpb=fbfb7321ab7a30cde5b99047854e18841d280f29;p=feisty_meow.git diff --git a/scripts/customize/fred/scripts/archival/update_soapbox.sh b/scripts/customize/fred/scripts/archival/update_soapbox.sh new file mode 100644 index 00000000..5e1b98cc --- /dev/null +++ b/scripts/customize/fred/scripts/archival/update_soapbox.sh @@ -0,0 +1,36 @@ +#!/bin/bash + +# updates my little 1 TB "soapbox" style usb drive with items that it should contain. + +source "$FEISTY_MEOW_SCRIPTS/core/launch_feisty_meow.sh" +source "$FEISTY_MEOW_SCRIPTS/archival/shared_updater_parts.sh" + +# where we're backing up to. +TARGET_FOLDER="/media/fred/soapboxdrive" + +sep + +echo Target drive currently has... +ls "$TARGET_FOLDER" +if [ $? -ne 0 ]; then + echo "The target location '$TARGET_FOLDER' is not mounted currently, so cannot be updated." + exit 1 +fi + +# synch all our targets. +for currdir in $ARCHIVE_COLLECTION_LIST; do + synch_directory_to_target "$currdir" "$TARGET_FOLDER/$(basename $currdir)"/ +done + +sep + +# update source code if present. +echo getting latest fred repositories... +pushd "$TARGET_FOLDER" +for currdir in $SOURCE_HIERARCHY_LIST; do + update_source_folders "$curr_dir" +done +sep + +echo Updated all expected portions of the targets successfully. +