mirror of
https://github.com/m1ngsama/dotfiles.git
synced 2025-12-24 10:51:24 +00:00
14 lines
444 B
Fish
14 lines
444 B
Fish
function _nvm_list
|
|
set --local versions $nvm_data/*
|
|
|
|
set --query versions[1] &&
|
|
string match --entire --regex -- (
|
|
string replace --all -- $nvm_data/ "" $versions |
|
|
string match --regex -- "v\d.+" |
|
|
string escape --style=regex |
|
|
string join "|"
|
|
) <$nvm_data/.index
|
|
|
|
command --all node |
|
|
string match --quiet --invert --regex -- "^$nvm_data" && echo system
|
|
end
|