Vruby alpha – like virtualenv, but for ruby(github.com) |
Vruby alpha – like virtualenv, but for ruby(github.com) |
Then for each project I would copy the entire ruby installation to my project root in a folder called "vruby". To load ruby for that project I would run "source vruby/bin/activate". It would setup all the environment variables with GEM_HOME pointing to a ".gem" folder under the project's root. Therefore gems are isolated to each project. To unload, I just close the terminal.
The vruby project automates this workflow, by installing a binary ruby using Traveling Ruby and symlinking it to the local project using GNU stow. The plan is to eventually support multiple Ruby versions and more platforms than just my Linux box. Unfortunately, I no longer do Ruby full time and don't have the bandwidth to make it as robust as I'd like. If you like this solution and need help setting it up, don't be afraid to get in touch.