pinnymz / migration_comments

Comments for your migrations
MIT License
173 stars 31 forks source link

Suppress execute_comment if column options not have :comment #4

Closed kamipo closed 12 years ago

kamipo commented 12 years ago

Especially if column was a primary key in MySQL, auto_increment is lost by execute_comment.

pinnymz commented 12 years ago

Thanks for the patch, but can you provide a test case you are trying to cover with this code? Or at least some pseudocode so I can understand better exactly what the problem is.

pinnymz commented 12 years ago

The test case demonstrates the problem well. However, the fix suggested breaks functionality for SQLite3. I'll see if I can find a proper workaround. Thanks for your input!

pinnymz commented 12 years ago

AutoIncrement is now fixed, along with working comments on the primary_key field (which was broken for MySQL and SQLite).