2015-05-18 22:14:08 -07:00
|
|
|
#!/usr/bin/env bash
|
2015-05-17 03:44:20 -07:00
|
|
|
|
2019-01-19 19:09:53 -07:00
|
|
|
# remove this asdf-exec file when releasing >=0.6.5
|
|
|
|
echo "asdf is self upgrading shims to new asdf exec ..."
|
2015-05-14 18:06:17 -07:00
|
|
|
|
2019-01-19 03:12:52 -07:00
|
|
|
asdf_dir="$(dirname "$(dirname "$(dirname "$0")")")"
|
|
|
|
# shellcheck source=lib/utils.sh
|
|
|
|
source "$asdf_dir/lib/utils.sh"
|
|
|
|
rm "$(asdf_data_dir)"/shims/*
|
|
|
|
"$asdf_dir"/bin/asdf reshim
|
|
|
|
shim_name=$(basename "$2")
|
2015-05-10 10:25:42 -07:00
|
|
|
|
2019-01-19 03:12:52 -07:00
|
|
|
echo "asdf: now running $shim_name"
|
2015-05-21 02:05:26 -07:00
|
|
|
|
2019-01-19 03:12:52 -07:00
|
|
|
exec "$shim_name" "${@:3}"
|