Commit 1ee47e53 by Cuong Tran

Merge pull request #249 from agoodno/run-on-rollback

Runs annotate on 'rake db:rollback' too
parents 0146ee7b 7b330655
......@@ -6,17 +6,19 @@
# Unfortunately it relies on ENV for options; it'd be nice to be able to set options
# in a per-project config file so this task can read them.
namespace :db do
task :migrate do
[:migrate, :rollback].each do |cmd|
task cmd do
Annotate::Migration.update_annotations
end
namespace :migrate do
namespace cmd do
[:change, :up, :down, :reset, :redo].each do |t|
task t do
Annotate::Migration.update_annotations
end
end
end
end
end
module Annotate
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment