dotfiles/fish/functions/_nvm_version_deactivate.fish
2024-09-01 17:44:44 +05:30

5 lines
239 B
Fish

function _nvm_version_deactivate --argument-names ver
test "$nvm_current_version" = "$ver" && set --erase nvm_current_version
set --local index (contains --index -- $nvm_data/$ver/bin $PATH) &&
set --erase PATH[$index]
end