ros-apartment 2.8.1 → 3.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.rubocop.yml +20 -80
- data/.rubocop_todo.yml +393 -20
- data/.ruby-version +1 -0
- data/Appraisals +30 -38
- data/CHANGELOG.md +5 -3
- data/Gemfile +0 -8
- data/README.md +15 -6
- data/Rakefile +3 -17
- data/lib/apartment/active_record/connection_handling.rb +18 -7
- data/lib/apartment/active_record/postgresql_adapter.rb +43 -0
- data/lib/apartment/active_record/schema_migration.rb +1 -1
- data/lib/apartment/adapters/jdbc_postgresql_adapter.rb +2 -4
- data/lib/apartment/adapters/postgresql_adapter.rb +19 -26
- data/lib/apartment/adapters/trilogy_adapter.rb +29 -0
- data/lib/apartment/console.rb +0 -16
- data/lib/apartment/log_subscriber.rb +21 -9
- data/lib/apartment/migrator.rb +3 -21
- data/lib/apartment/model.rb +3 -1
- data/lib/apartment/railtie.rb +7 -23
- data/lib/apartment/tasks/task_helper.rb +12 -0
- data/lib/apartment/version.rb +1 -1
- data/lib/apartment.rb +24 -19
- data/lib/tasks/apartment.rake +23 -39
- data/ros-apartment.gemspec +25 -13
- metadata +132 -41
- data/.circleci/config.yml +0 -78
- data/.github/ISSUE_TEMPLATE.md +0 -21
- data/.github/workflows/changelog.yml +0 -63
- data/.story_branch.yml +0 -5
- data/HISTORY.md +0 -496
- data/TODO.md +0 -50
- data/docker-compose.yml +0 -33
- data/gemfiles/rails_4_2.gemfile +0 -25
- data/gemfiles/rails_5_0.gemfile +0 -23
- data/gemfiles/rails_5_1.gemfile +0 -23
- data/gemfiles/rails_5_2.gemfile +0 -19
- data/gemfiles/rails_6_0.gemfile +0 -23
- data/gemfiles/rails_master.gemfile +0 -23
- data/lib/apartment/reloader.rb +0 -22
@@ -1,23 +0,0 @@
|
|
1
|
-
# This file was generated by Appraisal
|
2
|
-
|
3
|
-
source "http://rubygems.org"
|
4
|
-
|
5
|
-
gem "rails", git: "https://github.com/rails/rails.git"
|
6
|
-
gem "rubocop"
|
7
|
-
|
8
|
-
group :local do
|
9
|
-
gem "guard-rspec", "~> 4.2"
|
10
|
-
gem "pry"
|
11
|
-
end
|
12
|
-
|
13
|
-
platforms :ruby do
|
14
|
-
gem "sqlite3", "~> 1.4"
|
15
|
-
end
|
16
|
-
|
17
|
-
platforms :jruby do
|
18
|
-
gem "activerecord-jdbc-adapter", "~> 52.0"
|
19
|
-
gem "activerecord-jdbcpostgresql-adapter", "~> 52.0"
|
20
|
-
gem "activerecord-jdbcmysql-adapter", "~> 52.0"
|
21
|
-
end
|
22
|
-
|
23
|
-
gemspec path: "../"
|
data/lib/apartment/reloader.rb
DELETED
@@ -1,22 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
module Apartment
|
4
|
-
class Reloader
|
5
|
-
# Middleware used in development to init Apartment for each request
|
6
|
-
# Necessary due to code reload (annoying). When models are reloaded, they no longer have the proper table_name
|
7
|
-
# That is prepended with the schema (if using postgresql schemas)
|
8
|
-
# I couldn't figure out how to properly hook into the Rails reload process *after* files are reloaded
|
9
|
-
# so I've used this in the meantime.
|
10
|
-
#
|
11
|
-
# Also see apartment/console for the re-definition of reload! that re-init's Apartment
|
12
|
-
#
|
13
|
-
def initialize(app)
|
14
|
-
@app = app
|
15
|
-
end
|
16
|
-
|
17
|
-
def call(env)
|
18
|
-
Tenant.init
|
19
|
-
@app.call(env)
|
20
|
-
end
|
21
|
-
end
|
22
|
-
end
|