aboutsummaryrefslogtreecommitdiffstats
path: root/railties/lib/vendor/bundler/bin/gem_bundler
diff options
context:
space:
mode:
authorYehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com>2009-07-20 18:02:24 -0700
committerYehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com>2009-07-20 18:03:38 -0700
commite7a2496fda92ff4e39c127b065bf51ed6301e772 (patch)
tree5d566b4d073550919e4cd29fc68b131b8901c628 /railties/lib/vendor/bundler/bin/gem_bundler
parentd80316ad3269e11c2be9be0727ae518f5e427d24 (diff)
downloadrails-e7a2496fda92ff4e39c127b065bf51ed6301e772.tar.gz
rails-e7a2496fda92ff4e39c127b065bf51ed6301e772.tar.bz2
rails-e7a2496fda92ff4e39c127b065bf51ed6301e772.zip
Vendor the bundler project
Diffstat (limited to 'railties/lib/vendor/bundler/bin/gem_bundler')
-rwxr-xr-xrailties/lib/vendor/bundler/bin/gem_bundler40
1 files changed, 40 insertions, 0 deletions
diff --git a/railties/lib/vendor/bundler/bin/gem_bundler b/railties/lib/vendor/bundler/bin/gem_bundler
new file mode 100755
index 0000000000..7a8771efee
--- /dev/null
+++ b/railties/lib/vendor/bundler/bin/gem_bundler
@@ -0,0 +1,40 @@
+#!/usr/bin/env ruby
+require "optparse"
+require "bundler"
+
+options = {}
+
+parser = OptionParser.new do |op|
+ op.banner = "Usage: gem_bundler [OPTIONS] [PATH]"
+
+ op.on("-m", "--manifest MANIFEST") do |manifest|
+ options[:manifest] = manifest
+ end
+
+ op.on_tail("-h", "--help", "Show this message") do
+ puts op
+ exit
+ end
+end
+parser.parse!
+
+options[:path] = ARGV.shift
+
+unless options[:path]
+ puts parser
+ puts %(
+ [PATH] must be specified
+ )
+ exit
+end
+
+unless options[:manifest] && File.exist?(options[:manifest])
+ puts parser
+ puts %(
+ MANIFEST must be a valid manifest file
+ )
+ exit
+end
+
+
+Bundler.run(options) \ No newline at end of file