Uses global gemset after local gemset #20
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This will force rbenv to always look for gems in the global gemset, but it will use a local one if specified. It works great on my machine. Note, however, there is no easy way to install gems to that gemset at the moment. If you want to try it out you can run
rbenv gemset create global
. Note to install gems you'll have either change your.rbenv-gemsets
to only point to global then change it back or create a directory with a.rbenv-gemsets
that has only "global". Then you can switch to that directory to install gems then switch back. I do have a plan for installing, but I don't have time to finish it now. Essentially I'm thinking of implementing anrbenv gemset install [--gemset name] [--global] NAME
command that will install a gem to the gemset specified. Could the--gemset
switch be useful for scripting?What do you all think of this solution? Is there a problem I'm not seeing?