asdf-ruby icon indicating copy to clipboard operation
asdf-ruby copied to clipboard

Need help with asdf-exec

Open psantos10 opened this issue 7 years ago • 3 comments

With rbenv I can do something like:

$ rbenv exec bundle --version

Bundler version 1.16.0

or

$ rbenv exec gem -v

2.6.13

How can I have a similar result with asdf-ruby? I tried this:

$ ~/.asdf/bin/private/asdf-exec ruby bundle --version

But it gives me the following result:

No such command in 2.4.2 of ruby

psantos10 avatar Nov 22 '17 08:11 psantos10

@psantos10 why not just call bundle --version directly? It should be invoked with the correct version of Ruby if you are in the right directory (the same one you set the Ruby version in, or a sub directory of that dir).

Stratus3D avatar Nov 22 '17 16:11 Stratus3D

Hi @Stratus3D

I am trying to create a gem which works with Capistrano for deployment.

Using only bundle install will not work.

I found that, to work I need to run this:

~/.asdf/bin/private/asdf-exec ruby bin/bundle --version

psantos10 avatar Nov 22 '17 17:11 psantos10

asdf just released asdf exec with 0.7.x. Does this suffice for your needs? If so, please let us know.

SeanSith avatar Apr 02 '19 19:04 SeanSith