aboutsummaryrefslogtreecommitdiffstats
path: root/zsh/path.zsh
diff options
context:
space:
mode:
Diffstat (limited to 'zsh/path.zsh')
-rw-r--r--zsh/path.zsh13
1 files changed, 13 insertions, 0 deletions
diff --git a/zsh/path.zsh b/zsh/path.zsh
new file mode 100644
index 0000000..ef41549
--- /dev/null
+++ b/zsh/path.zsh
@@ -0,0 +1,13 @@
+#!/bin/bash
+
+# Add directories to the PATH and prevent to add the same directory multiple times upon shell reload.
+add_to_path() {
+ if [[ -d "$1" ]] && [[ ":$PATH:" != *":$1:"* ]]; then
+ export PATH="$1:$PATH"
+ fi
+}
+
+# Add ghq to PATH
+add_to_path "$GOPATH/bin"
+add_to_path "/Library/Frameworks/Firebird.framework/Resources/bin"
+