Gemset? Why should I compartamentalize my ruby dependencies if I am already using a Bundler? Isn’t that redundant? Yes, you are correct.
Recently, I have been configuring a Jenkins server to run our builds at work. We run a number of rails projects on the same ubuntu box, some on ruby 1.8.7 and some on 1.9.3. We run RVM and create a gemset for each project. RVM causes a number of issues when you are running bash scripts (jenkins runs each build using a shell script). Instead of whining about RVM, I much prefer to walk you through the process of replacing it with rbenv.
With proper bundler user, gemsets are unnessecary. Instead, define the gems required for a project in the project’s Gemfile. Then, run bundle install. rbenv is easily configured(see below!) to install gems to a projects’ vendor directory instead the default system gems.
Each application will be confined to only using gems defined in its Gemfile. However, please remember to refrain from installing gems with the gem install, except for global gems. The only gem that you should install manually is Bundler.
rvm implodegem uninstall rvm[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"brew updatebrew install rbenvbrew install ruby-buildrbenv install 1.9.3-p327rbenv install 2.0.0-preview2BUNDLE_PATH: vendorBUNDLE_BIN: vendor/binstubsBUNDLE_DISABLE_SHARED_GEMS: "1"~/.bashrcPATH=vendor/binstubs:$PATHif [ -f ~/.bashrc ]; thensource ~/.bashrcfisource ~/.bash_profileSpecial thanks to Harry Marr for his directions that inspired this post.
Perhaps I should tweet more. Hmm?
is my employer.
Email, skype, carrier pigeon, messenger owl...