dotfiles/home/.zsh/cmd/vmc.sh

19 lines
450 B
Bash
Raw Normal View History

2019-07-23 15:54:26 +00:00
### ASDF
# mnemonic [V]ersion [M]anager [C]lean
2019-08-26 18:21:50 +00:00
# uninstall multiple languages at once, async
2019-07-23 15:54:26 +00:00
lang=${1}
if [[ -z $lang ]]; then
lang=$(asdf plugin-list | eval "fzf ${FZF_DEFAULT_OPTS} -m --header='[asdf:clean]'")
fi
if [[ $lang ]]; then
for lng in $(echo $lang); do
for version in $(asdf list $lng | sort -nrk1,1 | eval "fzf ${FZF_DEFAULT_OPTS} -m --header='[asdf:${lng}:clean]'")
2019-12-28 15:28:55 +00:00
do asdf uninstall $lng $version
2019-07-23 15:54:26 +00:00
done
done
fi