Hacker News new | past | comments | ask | show | jobs | submit login

How do you specify which version you want in your program?



The naive way will just load the highest-numbered version you have installed:

  require 'rack'
When you have rubygems loaded, this is equivalent to:

  gem 'rack', '>=0'
You can specify exact and relative dependencies easily. There are a fuckton of frameworks to handle this for you, many of them oriented around copying the depended-upon gems into your app when it's deployed, as is common in the Java world.


Bundler[1] is one way.

[1] http://gembundler.com/rationale.html




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: