m/fzf
1
0
mirror of https://github.com/junegunn/fzf.git synced 2025-11-18 00:03:39 -05:00

updated ASDF examples

Sidney Liebrand
2017-09-03 23:44:06 +02:00
parent 1bb47fee12
commit f3b49f7a0d

@@ -529,19 +529,21 @@ To search for windows and show which is currently active, add [ftwind](https://g
```sh
# Install one or more versions of specified language
# e.g. `vmi rust` # => fzf multimode, tab to mark, enter to install
# if no plugin is supplied (e.g. `vmi<CR>`), fzf will list them for you
# Mnemonic [V]ersion [M]anager [I]nstall
vmi() {
local lang=${1}
if [[ ! $lang ]]; then
lang=$(asdf plugin-list | fzf)
fi
if [[ $lang ]]; then
local versions=$(asdf list-all $lang | fzf -m)
if [[ $versions ]]; then
for version in $(echo $versions);
do; asdf install $lang $version; done;
fi
else
echo 'Please supply installed asdf plugin'
return 1
fi
}
```
@@ -549,19 +551,21 @@ vmi() {
```sh
# Remove one or more versions of specified language
# e.g. `vmi rust` # => fzf multimode, tab to mark, enter to remove
# if no plugin is supplied (e.g. `vmi<CR>`), fzf will list them for you
# Mnemonic [V]ersion [M]anager [C]lean
vmc() {
local lang=${1}
if [[ ! $lang ]]; then
lang=$(asdf plugin-list | fzf)
fi
if [[ $lang ]]; then
local versions=$(asdf list $lang | fzf -m)
if [[ $versions ]]; then
for version in $(echo $versions);
do; asdf uninstall $lang $version; done;
fi
else
echo 'Please supply installed asdf plugin'
return 1
fi
}
```