Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
Oh My Zsh
Commits
5c73cb67
Commit
5c73cb67
authored
Nov 08, 2013
by
isquariel
Browse files
Added nvm.zsh to detect current Node.js version
parent
e30a1243
Changes
1
Show whitespace changes
Inline
Side-by-side
lib/nvm.zsh
0 → 100644
View file @
5c73cb67
# get the node.js version
function
nvm_prompt_info
()
{
[
-f
$HOME
/.nvm/nvm.sh
]
||
return
local
nvm_prompt
nvm_prompt
=
$(
node
-v
2>/dev/null
)
[[
"
${
nvm_prompt
}
x"
==
"x"
]]
&&
return
nvm_prompt
=
${
nvm_prompt
:1
}
echo
"
${
ZSH_THEME_NVM_PROMPT_PREFIX
}${
nvm_prompt
}${
ZSH_THEME_NVM_PROMPT_SUFFIX
}
"
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment