3 # copies a set of custom scripts into the proper location for feisty meow
4 # to merge their functions and aliases with the standard set.
7 source "$FEISTY_MEOW_SCRIPTS/core/functions.sh"
9 # function recustomize()
13 if [ -z "$user" ]; then
14 # use our default example user if there was no name provided.
17 if [ ! -d "$FEISTY_MEOW_APEX/customizing/$user" ]; then
18 echo "The customization folder provided for $user should be:"
19 echo " '$FEISTY_MEOW_APEX/customizing/$user'"
20 echo "but that folder does not exist. Skipping customization."
24 pushd "$FEISTY_MEOW_LOADING_DOCK/custom" &>/dev/null
25 incongruous_files="$(bash "$FEISTY_MEOW_SCRIPTS/files/list_non_dupes.sh" "$FEISTY_MEOW_APEX/customizing/$user" "$FEISTY_MEOW_LOADING_DOCK/custom")"
27 #echo "the incongruous files list is: $incongruous_files"
28 # disallow a single character result, since we get "*" as result when nothing exists yet.
29 if [ ${#incongruous_files} -ge 2 ]; then
30 echo "cleaning unknown older overrides..."
31 perl "$FEISTY_MEOW_SCRIPTS/files/safedel.pl" $incongruous_files
35 echo "copying custom overrides for $user"
36 mkdir -p "$FEISTY_MEOW_LOADING_DOCK/custom" 2>/dev/null
37 perl "$FEISTY_MEOW_SCRIPTS/text/cpdiff.pl" "$FEISTY_MEOW_APEX/customizing/$user" "$FEISTY_MEOW_LOADING_DOCK/custom"
38 if [ -d "$FEISTY_MEOW_APEX/customizing/$user/scripts" ]; then
39 echo "copying custom scripts for $user"
40 \cp -R "$FEISTY_MEOW_APEX/customizing/$user/scripts" "$FEISTY_MEOW_LOADING_DOCK/custom/"