Permalink
Browse files

Merge branch 'load-gemspec-cache' into 1-0-stable-dev

  • Loading branch information...
2 parents 5b16789 + f8b5066 commit 82311764b0f3e90ca735231e7b3aa294cdd2ff62 @dekellum committed Jan 19, 2012
Showing with 5 additions and 0 deletions.
  1. +5 −0 lib/bundler.rb
View
@@ -229,6 +229,11 @@ def read_file(file)
end
def load_gemspec(file)
+ @gemspec_cache ||= {}
+ @gemspec_cache[File.expand_path(file)] ||= load_gemspec_uncached(file)
+ end
+
+ def load_gemspec_uncached(file)
path = Pathname.new(file)
# Eval the gemspec from its parent directory
Dir.chdir(path.dirname.to_s) do

0 comments on commit 8231176

Please sign in to comment.