asdf/lib/commands/list-all.sh

15 lines
313 B
Bash
Raw Normal View History

2015-05-17 00:46:56 -07:00
list_all_command() {
local plugin_name=$1
local plugin_path=$(get_plugin_path $plugin_name)
2015-05-17 11:20:51 -07:00
check_if_plugin_exists $plugin_path
2015-05-21 22:17:44 -07:00
2015-05-21 22:19:07 -07:00
local versions=$(bash ${plugin_path}/bin/list-all)
2015-05-07 22:58:07 -07:00
2015-05-17 00:46:56 -07:00
IFS=' ' read -a versions_list <<< "$versions"
2015-05-07 22:58:07 -07:00
2015-05-17 00:46:56 -07:00
for version in "${versions_list[@]}"
do
echo "${version}"
done
}