Use the --version
parameter (shortcut -v
):
$ gem install rails -v 0.14.1
You can also use version comparators like >=
or ~>
$ gem install rails -v '~> 0.14.0'
Or with newer versions of gem even:
$ gem install rails:0.14.4 rubyzip:'< 1'
…
Successfully installed rails-0.14.4
Successfully installed rubyzip-0.9.9