cleaning up some too specialized scripts that fred uses.
[feisty_meow.git] / scripts / core / functions.sh
index 8a2f35865a36c59cad49bda5ef6c63af8c465cf9..c79713379b4b2d30fce7f4d8d073acc288bc9f72 100644 (file)
@@ -77,7 +77,6 @@ if [ -z "$skip_all" ]; then
   # locates a process given a search pattern to match in the process list.
   function psfind() {
     local -a patterns=("${@}")
-    mkdir $TEST_TEMP/grid_logs &>/dev/null
     local PID_DUMP="$(mktemp "$TMP/zz_pidlist.XXXXXX")"
     local -a PIDS_SOUGHT
     if [ "$OS" == "Windows_NT" ]; then
@@ -138,13 +137,13 @@ if [ -z "$skip_all" ]; then
       echo "psa finds processes by pattern, but there was no pattern on the command line."
       return 1
     fi
-    p=$(psfind "$1")
+    p=$(psfind "${@}")
     if [ -z "$p" ]; then
       # no matches.
       return 0
     fi
     echo ""
-    echo "Processes containing \"$1\"..."
+    echo "Processes matching ${@}..."
     echo ""
     if [ -n "$IS_DARWIN" ]; then
       unset fuzil_sentinel
@@ -340,6 +339,16 @@ if [ -z "$skip_all" ]; then
     echo "copying custom overrides for $user"
     mkdir "$FEISTY_MEOW_GENERATED/custom" 2>/dev/null
     perl "$FEISTY_MEOW_SCRIPTS/text/cpdiff.pl" "$FEISTY_MEOW_DIR/customizing/$user" "$FEISTY_MEOW_GENERATED/custom"
+    # set up any custom script files which we'll add as aliases.
+#    if [ -e "$FEISTY_MEOW_GENERATED/custom/scripts" ]; then
+#      echo removing older custom scripts.
+#      rm -rf "$FEISTY_MEOW_GENERATED/custom/scripts"
+#    fi
+    if [ -d "$FEISTY_MEOW_DIR/customizing/$user/scripts" ]; then
+      echo "copying custom scripts for $user"
+      cp -v -R "$FEISTY_MEOW_DIR/customizing/$user/scripts" "$FEISTY_MEOW_GENERATED/custom/"
+    fi
+    echo
     regenerate
   }