rbenv-gemset
rbenv-gemset copied to clipboard
Using the plugin in an existing project
In an setup where rbenv is installed and gems are installed too, what are the steps to activate the plugin without re-installing the gems?
It sounds like you were previously just using rbenv
without gemsets, but now you want to try out rbenv-gemset
?
rbenv-gemset
wasn't designed for this, fyi. If you want to, you can try copying (or symlinking) the gem directories to the appropriate directory at ~/.rbenv/versions/<rbenv version name>/gemsets/<gemset name>/gems
You read the use case correctly. The workaround sounds fine. I shall try it. What do you think about extending rbenv-gemset to encompass the use case? It might be a just a script that performs the symlinking as you mentioned to start with.
This isn't a very common use case that I know of, and there are implications for officially "supporting" it, so I'm not so keen on this. You're free to try and let me know how it goes though.
Seems we are automatically fall to "previously just using rbenv without gemsets" if using with rbenv-default-gems.
Just ran into the same issue, I fixed it using bundler
bundle install --redownload
It will reinstall all gems and put the gems in the correct dir (i.e. gemset dir).
EDIT: I know OP said "without re-installing the gems", but maybe someone else finds this question and is fine with re-installing.