42 else |
42 else |
43 pull .asdf/plugins/$LANG |
43 pull .asdf/plugins/$LANG |
44 fi |
44 fi |
45 done |
45 done |
46 |
46 |
47 set +eu |
|
48 . .asdf/asdf.sh |
|
49 set -eu |
|
50 |
|
51 # Transition older stuff to asdf |
47 # Transition older stuff to asdf |
52 if [ -d .rbenv ]; then |
48 if [ -d .rbenv ]; then |
53 echo 'Removing rbenv and moving ruby installs' |
49 echo 'Removing rbenv and moving ruby installs' |
54 |
50 |
55 mkdir -p .asdf/installs |
51 if [ -d .rbenv/versions ]; then |
56 mv .rbenv/versions .asdf/installs/ruby |
52 mkdir -p .asdf/installs |
57 pushd $! |
53 mv .rbenv/versions .asdf/installs/ruby |
58 for ver in *; do |
54 for ver in .asdf/installs/ruby/*; do |
59 asdf reshim ruby $ver |
55 bash -c "asdf reshim ruby $(basename $ver)" |
60 done |
56 done |
61 popd |
57 fi |
62 |
58 |
63 if [ -f .rbenv/version ]; then |
59 if [ -f .rbenv/version ]; then |
64 echo "ruby $(cat .rbenv/version)" >> .tool-versions |
60 echo "ruby $(cat .rbenv/version)" >> .tool-versions |
65 fi |
61 fi |
66 |
62 |
68 fi |
64 fi |
69 |
65 |
70 if [ -d .ndenv ]; then |
66 if [ -d .ndenv ]; then |
71 echo 'Removing ndenv and moving node installs' |
67 echo 'Removing ndenv and moving node installs' |
72 |
68 |
73 mkdir -p .asdf/installs |
69 if [ -d .ndenv/versions ]; then |
74 mv .ndenv/versions .asdf/installs/nodejs |
70 mkdir -p .asdf/installs |
75 pushd $! |
71 mv .ndenv/versions .asdf/installs/nodejs |
76 for ver in *; do |
72 for ver in .asdf/installs/nodejs/*; do |
77 asdf reshim nodejs $ver |
73 bash -c "asdf reshim nodejs $(basename $ver)" |
78 done |
74 done |
79 popd |
75 fi |
80 |
76 |
81 if [ -f .ndenv/version ]; then |
77 if [ -f .ndenv/version ]; then |
82 echo "nodejs $(cat .ndenv/version)" >> .tool-versions |
78 echo "nodejs $(cat .ndenv/version)" >> .tool-versions |
83 fi |
79 fi |
84 |
80 |