config/oh-my-zsh/lib/nvm.zsh
2023-02-27 20:04:56 +05:30

6 lines
236 B
Bash

# get the nvm-controlled node.js version
function nvm_prompt_info() {
which nvm &>/dev/null || return
local nvm_prompt=${$(nvm current)#v}
echo "${ZSH_THEME_NVM_PROMPT_PREFIX}${nvm_prompt:gs/%/%%}${ZSH_THEME_NVM_PROMPT_SUFFIX}"
}