提交 94e5b10a 编写于 作者: M Michael Koziarski

Use Gem.find_name instead of search when freezing gems. Prevent false...

Use Gem.find_name instead of search when freezing gems.  Prevent false positive for other gems with rails in the name. Closes #8729 [wselman]



git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7233 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
上级 6391e192
*SVN*
* use Gem.find_name instead of search when freezing gems. Prevent false positives for other gems with rails in the name. Closes #8729 [wselman]
* Automatically generate add/remove column commands in specially named migrations like AddLocationToEvent. Closes #9006 [zenspider]
* Default to plural table name in Rails Generator if ActiveRecord is not present. Closes #8963 [evan]
......
......@@ -7,8 +7,8 @@ namespace :rails do
Gem.manage_gems
rails = (version = ENV['VERSION']) ?
Gem.cache.search('rails', "= #{version}").first :
Gem.cache.search('rails').sort_by { |g| g.version }.last
Gem.cache.find_name('rails', "= #{version}").first :
Gem.cache.find_name('rails').sort_by { |g| g.version }.last
version ||= rails.version
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册