From f7ad2c80310ceb251b67c079da8aaeca208922af Mon Sep 17 00:00:00 2001 From: Chloe Kudryavtsev Date: Tue, 1 Sep 2020 17:55:02 -0400 Subject: zsh: process path first --- dot_zsh/source/00-path.zsh | 23 +++++++++++++++++++++++ dot_zsh/source/path.zsh | 23 ----------------------- 2 files changed, 23 insertions(+), 23 deletions(-) create mode 100644 dot_zsh/source/00-path.zsh delete mode 100644 dot_zsh/source/path.zsh (limited to 'dot_zsh') diff --git a/dot_zsh/source/00-path.zsh b/dot_zsh/source/00-path.zsh new file mode 100644 index 0000000..e29bb56 --- /dev/null +++ b/dot_zsh/source/00-path.zsh @@ -0,0 +1,23 @@ +if (( $+commands[luarocks] )); then + PATH="$PATH:$(luarocks path --lr-bin)" # luarocks puts :s in the output + eval $(luarocks path --no-bin) +fi +if (( $+commands[opam] )); then + eval $(opam env) +fi +if (( $+commands[yarn] )) && [[ ! -f ~/.yarnrc ]]; then + yarn config set global-folder ~/.local/yarn/global + yarn config set prefix ~/.local/yarn +fi + +# high priority +path=( ~/bin $path ) + +# low priority +path+=( + ~/Applications + ~/.local/cargo/bin + ~/.local/go/bin + ~/.local/yarn/bin + ~/.gem/ruby/*/bin(N) +) diff --git a/dot_zsh/source/path.zsh b/dot_zsh/source/path.zsh deleted file mode 100644 index e29bb56..0000000 --- a/dot_zsh/source/path.zsh +++ /dev/null @@ -1,23 +0,0 @@ -if (( $+commands[luarocks] )); then - PATH="$PATH:$(luarocks path --lr-bin)" # luarocks puts :s in the output - eval $(luarocks path --no-bin) -fi -if (( $+commands[opam] )); then - eval $(opam env) -fi -if (( $+commands[yarn] )) && [[ ! -f ~/.yarnrc ]]; then - yarn config set global-folder ~/.local/yarn/global - yarn config set prefix ~/.local/yarn -fi - -# high priority -path=( ~/bin $path ) - -# low priority -path+=( - ~/Applications - ~/.local/cargo/bin - ~/.local/go/bin - ~/.local/yarn/bin - ~/.gem/ruby/*/bin(N) -) -- cgit v1.2.3