Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

23 lines (19 sloc) 0.645 kb
BUNDLER_VERSION="1.0.0"
namespace :bundle do
desc "Install the gems needed according to the Gemfile"
task :expand => :ensure_bundler_available do
system("bundle install")
fail "bundler failed" unless $? == 0
end
task :ensure_bundler_available do
`gem list -i bundler -v '#{BUNDLER_VERSION}'`
unless $? == 0
puts "Installing bundler #{BUNDLER_VERSION}"
system("gem install bundler -v '#{BUNDLER_VERSION}'")
unless $? == 0
fail "Install failed.\nPlease fix the problem and try again or manually install bundler #{BUNDLER_VERSION}."
end
end
end
end
task :default => :'bundle:expand'
Jump to Line
Something went wrong with that request. Please try again.