sync_machine 1.1.0 → 1.1.1
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 382d073ea7c61af6da6f38ca3a9c014e4913a7b5fd381b6a84e5f0403edacca8
|
4
|
+
data.tar.gz: 67e6f4008630a67ae804f9530f9905fcdd78137e991369f1f43412386dd2074b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: eb69f9a240373ca62e4817c8f5c15c2dfafc14a1e46211dc254608cb031e423104e1ba2ee382e660543cc9414b63cdd49e2293502f5e6bc7434d8a706bbbf2bc
|
7
|
+
data.tar.gz: bcd1474c68ebb58a04169bdd26ae940268cb289968db9855a58e81b15607fae69f364040503d04cda10e03f4d5de8d23a51f4ca1b8d20450878460224d2c42d3
|
data/lib/sync_machine.rb
CHANGED
@@ -3,12 +3,11 @@ require "active_support/core_ext/string"
|
|
3
3
|
require "active_support/hash_with_indifferent_access"
|
4
4
|
require "sync_machine/change_listener"
|
5
5
|
require "sync_machine/ensure_publication"
|
6
|
-
require "sync_machine/ensure_publication/deduper"
|
7
|
-
require "sync_machine/ensure_publication/publication_history"
|
8
6
|
require "sync_machine/ensure_publication_worker"
|
9
7
|
require "sync_machine/find_subjects_worker"
|
10
8
|
require "sync_machine/orm_adapters"
|
11
9
|
require "sync_machine/version"
|
10
|
+
require "sync_machine/railtie" if defined?(Rails::Railtie)
|
12
11
|
|
13
12
|
# A mini-framework for intelligently publishing complex model changes to an
|
14
13
|
# external API..
|
@@ -1,8 +1,3 @@
|
|
1
|
-
Bundler.require(:default)
|
2
|
-
|
3
|
-
require "sync_machine/orm_adapters/active_record_adapter" if Module.const_defined?(:ActiveRecord)
|
4
|
-
require "sync_machine/orm_adapters/mongoid_adapter" if Module.const_defined?(:Mongoid)
|
5
|
-
|
6
1
|
module SyncMachine
|
7
2
|
# Adapt generic SyncMachine functionality to a specific ORM.
|
8
3
|
module OrmAdapters
|
@@ -0,0 +1,11 @@
|
|
1
|
+
module SyncMachine
|
2
|
+
# Initialize SyncMachine inside a Rails application.
|
3
|
+
class Railtie < Rails::Railtie
|
4
|
+
initializer :sync_machine do
|
5
|
+
Module.const_defined?(:ActiveRecord) && \
|
6
|
+
require("sync_machine/orm_adapters/active_record_adapter")
|
7
|
+
Module.const_defined?(:Mongoid) && \
|
8
|
+
require("sync_machine/orm_adapters/mongoid_adapter")
|
9
|
+
end
|
10
|
+
end
|
11
|
+
end
|
data/lib/sync_machine/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sync_machine
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Francis Hwang
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-11-
|
11
|
+
date: 2019-11-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -235,6 +235,7 @@ files:
|
|
235
235
|
- lib/sync_machine/orm_adapters.rb
|
236
236
|
- lib/sync_machine/orm_adapters/active_record_adapter.rb
|
237
237
|
- lib/sync_machine/orm_adapters/mongoid_adapter.rb
|
238
|
+
- lib/sync_machine/railtie.rb
|
238
239
|
- lib/sync_machine/version.rb
|
239
240
|
- sync_machine.gemspec
|
240
241
|
homepage: https://github.com/fhwang/sync_machine
|