Skip to content

Commit

Permalink
add reenable for task
Browse files Browse the repository at this point in the history
  • Loading branch information
evgeny.pan committed Sep 19, 2024
1 parent f887d38 commit c400f74
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/tasks/clickhouse.rake
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,13 @@ namespace :ch do
migrations_sources_table = :clickhouse_migrations_sources
use_transactions = "false"

Rake::Task["sequel:archive_migrations"].reenable
Rake::Task["sequel:archive_migrations"].invoke(path, migrations_sources_table)

Rake::Task["sequel:rollback_archived_migrations"].reenable
Rake::Task["sequel:rollback_archived_migrations"]
.invoke(path, migrations_table, migrations_sources_table, use_transactions)

Clickhouse::Migrator.migrate(to: ENV.fetch("VERSION", nil))
end

Expand All @@ -49,6 +53,7 @@ namespace :ch do

desc "Rollback any missing migrations for ClickHouse"
task rollback_missing_migrations: :environment do
Rake::Task["sequel:rollback_missing_migrations"].reenable
Rake::Task["sequel:rollback_missing_migrations"].invoke(:clickhouse_migrations, "false")
end
end

0 comments on commit c400f74

Please sign in to comment.