Rbenv exec bundle exec instead of simple exec package

I am trying to configure rbenv:

https://github.com/sstephenson/rbenv#section_2

This works for me with one problem: I have to use rbenv exec in front of everything

So now, to do bundle exec, I do:

rbenv exec bundle exec

How do I get around this?

Edit

After running rbenv rehash, I get:

 $ βž” rbenv rehash $ βž” rails s bash: /usr/local/bin/rails: /usr/local/bin/ruby: bad interpreter: No such file or directory 
+4
source share
1 answer

Really stupid:

I forgot to run exec $SHELL so that my PATH is not updated. Original lines:

 export PATH="$HOME/.rbenv/bin:$PATH" eval "$(rbenv init -)" 

were placed in .bash_profile, but should have been in .bashrc. After the fix, I forgot to open / run the above command again!

Thanks to @Dylan Markov in the comments for pointing me in the right direction :)

+3
source

Source: https://habr.com/ru/post/1394016/


All Articles