Sha256: 6d90b4ea0da95a9ef87379e5941662cf9459dd633db96c003b38681c8d64311a

Contents?: true

Size: 1.09 KB

Versions: 15

Compression:

Stored size: 1.09 KB

Contents

module ArJdbc
  module Tasks

    def self.register_tasks(pattern, task)
      ActiveRecord::Tasks::DatabaseTasks.register_task(pattern, task)
    end

    # support adapter: mariadb (as if it were mysql)
    register_tasks(/mariadb/, ActiveRecord::Tasks::MySQLDatabaseTasks)

    require 'arjdbc/tasks/jdbc_database_tasks'
    require 'arjdbc/tasks/sqlite_database_tasks_patch'
    require 'arjdbc/tasks/mssql_database_tasks'
    #require 'arjdbc/tasks/db2_database_tasks'
    #require 'arjdbc/tasks/derby_database_tasks'
    #require 'arjdbc/tasks/h2_database_tasks'
    #require 'arjdbc/tasks/hsqldb_database_tasks'

    # re-invent built-in (but deprecated on 4.0) tasks :
    # tasks for custom (JDBC) adapters :
    #register_tasks(/db2/, DB2DatabaseTasks)
    #register_tasks(/derby/, DerbyDatabaseTasks)
    #register_tasks(/h2/, H2DatabaseTasks)
    #register_tasks(/hsqldb/, HSQLDBDatabaseTasks)
    # (default) generic JDBC task :
    register_tasks(/^jdbc$/, JdbcDatabaseTasks)
    register_tasks(/sqlserver/, MSSQLDatabaseTasks)

    # NOTE: no need to register "built-in" adapters such as MySQL

  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
activerecord-jdbc-alt-adapter-61.3.0-java lib/arjdbc/tasks/database_tasks.rb
activerecord-jdbc-alt-adapter-60.3.0-java lib/arjdbc/tasks/database_tasks.rb
activerecord-jdbc-alt-adapter-61.2.0-java lib/arjdbc/tasks/database_tasks.rb
activerecord-jdbc-alt-adapter-60.2.0-java lib/arjdbc/tasks/database_tasks.rb
activerecord-jdbc-alt-adapter-61.1.0-java lib/arjdbc/tasks/database_tasks.rb
activerecord-jdbc-alt-adapter-61.0.0-java lib/arjdbc/tasks/database_tasks.rb
activerecord-jdbc-alt-adapter-60.1.0-java lib/arjdbc/tasks/database_tasks.rb
activerecord-jdbc-alt-adapter-52.6.0-java lib/arjdbc/tasks/database_tasks.rb
activerecord-jdbc-alt-adapter-60.0.0-java lib/arjdbc/tasks/database_tasks.rb
activerecord-jdbc-alt-adapter-52.5.1-java lib/arjdbc/tasks/database_tasks.rb
activerecord-jdbc-alt-adapter-52.4.0-java lib/arjdbc/tasks/database_tasks.rb
activerecord-jdbc-alt-adapter-52.2.3-java lib/arjdbc/tasks/database_tasks.rb
activerecord-jdbc-alt-adapter-52.2.2-java lib/arjdbc/tasks/database_tasks.rb
activerecord-jdbc-alt-adapter-52.2.1-java lib/arjdbc/tasks/database_tasks.rb
activerecord-jdbc-alt-adapter-52.2.0-java lib/arjdbc/tasks/database_tasks.rb