From defbf9bbf77b258fa5a6d9c4b6a0053722c51cb2 Mon Sep 17 00:00:00 2001 From: Hektor Misplon Date: Tue, 31 Aug 2021 14:28:09 +0200 Subject: [PATCH] Update nvm loading --- .bashrc | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/.bashrc b/.bashrc index bcd42af..9369b07 100644 --- a/.bashrc +++ b/.bashrc @@ -39,15 +39,10 @@ export FZF_DEFAULT_OPTS='--height 38% --reverse --border --prompt="❭ " --point export FZF_COMPLETION_OPTS='-x' # Nvm -lazy_load_nvm() { - unset -f nvm node npm npx - export NVM_DIR="$HOME/.nvm" - [ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" - [ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" -} -nvm() { lazy_load_nvm nvm $@; } -node() { lazy_load_nvm node $@; } -npm() { lazy_load_nvm npm $@; } -npx() { lazy_load_nvm npx $@; } + +export PATH=~/.nvm/versions/node/v14.16.0/bin:$PATH +export NVM_DIR="$HOME/.nvm" +[[ -s "$NVM_DIR/nvm.sh" ]] && source "$NVM_DIR/nvm.sh" --no-use + # Ellipsis when deep in directory export PROMPT_DIRTRIM=2