Permalink
Browse files

patch from Dave Turnbull

  • Loading branch information...
1 parent 158c7b4 commit 5e250519b9d04addb276e0f86f02f973b7769b22 Reg Braithwaite committed Nov 9, 2008
Showing with 4 additions and 1 deletion.
  1. +4 −1 config/requirements.rb
View
@@ -5,7 +5,10 @@
%w[rake hoe newgem rubigen].each do |req_gem|
begin
require req_gem
- rescue LoadError
+ rescue LoadError => e
+ if r = e.to_s.match(/Could not find RubyGem (.*?) \(/)
+ req_gem = r[1]
+ end
puts "This Rakefile requires the '#{req_gem}' RubyGem."
puts "Installation: gem install #{req_gem} -y"
exit

0 comments on commit 5e25051

Please sign in to comment.