aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.zsh.before/path.zsh9
1 files changed, 8 insertions, 1 deletions
diff --git a/.zsh.before/path.zsh b/.zsh.before/path.zsh
index f463e69..9b1579f 100644
--- a/.zsh.before/path.zsh
+++ b/.zsh.before/path.zsh
@@ -1,5 +1,5 @@
# < BEFORE $PATH
-PATH=$HOME/bin:$PATH
+#PATH=$HOME/bin:$PATH
# > BEFORE
# < AFTER $PATH
@@ -14,6 +14,13 @@ PATH=$HOME/bin:$PATH
## RVM
PATH=$PATH:$HOME/.rvm/bin # Add RVM to PATH for scripting
+
+# replace /usr/local/bin once with $HOME/bin:/usr/local/bin in $PATH
+autoload -U regexp-replace
+if [[ "$PATH" != *dave/bin:/usr/local/sbin* ]];then
+ regexp-replace PATH '/usr/local/bin:' '$HOME/bin:/usr/local/sbin:'
+fi
+
## RASPBERRY PI
if [[ "$HOST" == *pitheunlord* ]]; then
PATH=$PATH:"/opt/vc/bin:/opt/vc/sbin"