gemlock1
Generate a lockdown list of a set of gems
Usage
gemlock [options]
GEM_NAME-VERSION ...
Overview
gemlock will generate a list of require_gem statements that will lock down the versions for the gem given in the command line. It will specify exact versions in the requirements list to ensure that the gems loaded will always be consistent. A full recursive search of all effected gems will be generated.
Options
-
-v, --verbose -
Verbose output
-s,--[no-]strict-
Fail if unable to satisfy a dependency
-
-h, --help -
Show this message
-
-V, --version -
Show version
Examples
-
gemlock rails-1.0.0 > lockdown.rb
will produce in lockdown.rb:
-
require "rubygems" gem 'rails', '= 1.0.0' gem 'rake', '= 0.7.0.1' gem 'activesupport', '= 1.2.5' gem 'activerecord', '= 1.13.2' gem 'actionpack', '= 1.11.2' gem 'actionmailer', '= 1.1.5' gem 'actionwebservice', '= 1.0.0'
Just load lockdown.rb from your application to ensure that the current versions are loaded. Make sure that lockdown.rb is loaded before any other require statements.