Permalink
Browse files

Make migration generator only report on exact duplicate names, not pa…

…rtial dupliate names. Closes #3442.

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3413 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
1 parent 302533b commit 30c6bd9b31098332d6357d3ab614941646cbe0e2 Marcel Molina committed Jan 13, 2006
Showing with 3 additions and 1 deletion.
  1. +2 −0 railties/CHANGELOG
  2. +1 −1 railties/lib/rails_generator/commands.rb
View
@@ -1,5 +1,7 @@
*SVN*
+* Make migration generator only report on exact duplicate names, not partial dupliate names. #3442 [jeremy@planetargon.com Marcel Molina Jr.]
+
* Fix typo in mailer generator USAGE. #3458 [chriztian.steinmeier@gmail.com]
* Ignore version mismatch between pg_dump and the database server. #3457 [simon.stapleton@gmail.com]
@@ -61,7 +61,7 @@ def migration_directory(relative_path)
end
def existing_migrations(file_name)
- Dir.glob("#{@migration_directory}/[0-9]*_#{file_name}.rb")
+ Dir.glob("#{@migration_directory}/[0-9]*_*.rb").grep(/[0-9]+_#{file_name}.rb$/)
end
def migration_exists?(file_name)

0 comments on commit 30c6bd9

Please sign in to comment.