Class: Gitlab::ClickHouse::MigrationGenerator
- Inherits:
-
ActiveRecord::Generators::MigrationGenerator
- Object
- ActiveRecord::Generators::MigrationGenerator
- Gitlab::ClickHouse::MigrationGenerator
- Defined in:
- lib/generators/gitlab/click_house/migration_generator.rb
Direct Known Subclasses
Instance Method Summary collapse
-
#create_migration_file ⇒ Object
Override create_migration_file to ensure custom template is used.
- #db_migrate_path ⇒ Object
Instance Method Details
#create_migration_file ⇒ Object
Override create_migration_file to ensure custom template is used
27 28 29 30 31 |
# File 'lib/generators/gitlab/click_house/migration_generator.rb', line 27 def create_migration_file set_local_assigns! validate_file_name! migration_template "migration.rb.template", File.join(db_migrate_path, "#{file_name}.rb") end |
#db_migrate_path ⇒ Object
22 23 24 |
# File 'lib/generators/gitlab/click_house/migration_generator.rb', line 22 def db_migrate_path 'db/click_house/migrate/main' end |