mirror of
https://github.com/asdf-vm/asdf.git
synced 2024-11-15 09:38:16 -07:00
d1f0b64c2f
- Remove plugin shims when last version is uninstalled. - Remove shims on plugin-remove When the latest version of a tool is uninstalled, Remove the plugin shims (marked with metadata at #122) Also found lots of missing tests and added them. Closes #67
12 lines
297 B
Bash
12 lines
297 B
Bash
plugin_remove_command() {
|
|
local plugin_name=$1
|
|
check_if_plugin_exists $plugin_name
|
|
|
|
local plugin_path=$(get_plugin_path $plugin_name)
|
|
|
|
rm -rf $plugin_path
|
|
rm -rf $(asdf_dir)/installs/${plugin_name}
|
|
|
|
grep -l "asdf-plugin: ${plugin_name}" $(asdf_dir)/shims/* 2>/dev/null | xargs rm -f
|
|
}
|