diff options
author | Matt Jones <al2o3cr@gmail.com> | 2008-10-11 13:54:21 -0400 |
---|---|---|
committer | Michael Koziarski <michael@koziarski.com> | 2008-10-13 17:27:25 +0200 |
commit | 9f15870946720ef9a0dbaa3ac336fff8bd149752 (patch) | |
tree | b40988cff37cc44838f003e0920a4959ca502e5b /railties/lib/tasks | |
parent | 0d4dbb3dfaec8355e072d8f758de40a277f2f009 (diff) | |
download | rails-9f15870946720ef9a0dbaa3ac336fff8bd149752.tar.gz rails-9f15870946720ef9a0dbaa3ac336fff8bd149752.tar.bz2 rails-9f15870946720ef9a0dbaa3ac336fff8bd149752.zip |
Make VendorGemSourceIndex handle broken/missing specs generated by previous versions.
Signed-off-by: Michael Koziarski <michael@koziarski.com>
Diffstat (limited to 'railties/lib/tasks')
-rw-r--r-- | railties/lib/tasks/gems.rake | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/railties/lib/tasks/gems.rake b/railties/lib/tasks/gems.rake index 9abdfc56b6..c65dfc7dd4 100644 --- a/railties/lib/tasks/gems.rake +++ b/railties/lib/tasks/gems.rake @@ -65,4 +65,14 @@ namespace :gems do end end end + + desc "Regenerate gem specifications in correct format." + task :refresh_specs => :base do + require 'rubygems' + require 'rubygems/gem_runner' + Rails.configuration.gems.each do |gem| + next unless gem.frozen? && (ENV['GEM'].blank? || ENV['GEM'] == gem.name) + gem.refresh_spec(Rails::GemDependency.unpacked_path) if gem.loaded? + end + end end
\ No newline at end of file |