trailblazer-rails 0.1.6 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGES.md +5 -0
- data/Gemfile +3 -2
- data/lib/trailblazer/rails/application_controller.rb +3 -0
- data/lib/trailblazer/rails/railtie.rb +9 -7
- data/lib/trailblazer/rails/test/integration.rb +6 -0
- data/lib/trailblazer/rails/version.rb +1 -1
- data/trailblazer-rails.gemspec +2 -1
- metadata +19 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 67b66b38caa7865052bc90f97de4f49aba626616
|
4
|
+
data.tar.gz: 89c1fe8c19b1cf7ceed3690e4807e7c9785efdc6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7cd11282fb7101a0f7f2c9be90bb0ccf6e14898d5871f90ba4bf026646fc998b12882b080e5a687c904818f2005296e60ca8e4e01e46c0d3f02a5103f1a5edbb
|
7
|
+
data.tar.gz: fcf9a0d0ac5d872d1500513684837c9c3c226d35322c3c2ce9f2266a73d82ba75df19b199fc66fd2224e5adf32e8791ed8db9b366968ccb71bee515718b323dc
|
data/CHANGES.md
CHANGED
@@ -1,3 +1,8 @@
|
|
1
|
+
# 0.2.0
|
2
|
+
|
3
|
+
* Use `trailblazer-loader` for loading operations and associated files, now. Note that `operations.rb` now is `operation.rb` (hence the minor bump).
|
4
|
+
* The `Operation::Controller` module is not included into `ApplicationController` automatically.
|
5
|
+
|
1
6
|
# 0.1.6
|
2
7
|
|
3
8
|
* Fix `Controller#run`, which now returns the operation instance instead of the `Else` object.
|
data/Gemfile
CHANGED
@@ -3,5 +3,6 @@ source 'https://rubygems.org'
|
|
3
3
|
# Specify your gem's dependencies in trailblazer-rails.gemspec
|
4
4
|
gemspec
|
5
5
|
|
6
|
-
gem "trailblazer", path: "../trailblazer"
|
7
|
-
|
6
|
+
# gem "trailblazer", path: "../trailblazer"
|
7
|
+
gem "trailblazer", github: "apotonick/trailblazer"
|
8
|
+
gem "trailblazer-loader", github: "trailblazer/trailblazer-loader"
|
@@ -3,13 +3,7 @@ require "rails/railtie"
|
|
3
3
|
module Trailblazer
|
4
4
|
class Railtie < ::Rails::Railtie
|
5
5
|
def self.autoload_operations(app)
|
6
|
-
|
7
|
-
path = f.sub("app/concepts/", "")
|
8
|
-
model = path.sub("/crud.rb", "")
|
9
|
-
|
10
|
-
require_dependency "#{app.root}/app/models/#{model}" # load the model file, first (thing.rb).
|
11
|
-
require_dependency "#{app.root}/#{f}" # load app/concepts/{concept}/crud.rb (Thing::Create, Thing::Update, and so on).
|
12
|
-
end
|
6
|
+
Loader.new.(app.root) { |file| require_dependency(file) }
|
13
7
|
end
|
14
8
|
|
15
9
|
def self.autoload_cells(app)
|
@@ -32,5 +26,13 @@ module Trailblazer
|
|
32
26
|
Trailblazer::Railtie.autoload_cells(app)
|
33
27
|
end
|
34
28
|
end
|
29
|
+
|
30
|
+
# initializer "trailblazer.roar" do
|
31
|
+
# require "trailblazer/rails/roar" #if Object.const_defined?(:Roar)
|
32
|
+
# end
|
33
|
+
|
34
|
+
initializer "trailblazer.application_controller" do
|
35
|
+
require "trailblazer/rails/application_controller"
|
36
|
+
end
|
35
37
|
end
|
36
38
|
end
|
data/trailblazer-rails.gemspec
CHANGED
@@ -10,7 +10,7 @@ Gem::Specification.new do |spec|
|
|
10
10
|
spec.email = ["apotonick@gmail.com"]
|
11
11
|
|
12
12
|
spec.summary = %q{Convenient Rails support for Trailblazer.}
|
13
|
-
spec.homepage = "http://
|
13
|
+
spec.homepage = "http://trailblazer.to"
|
14
14
|
spec.license = "MIT"
|
15
15
|
|
16
16
|
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
@@ -18,6 +18,7 @@ Gem::Specification.new do |spec|
|
|
18
18
|
spec.require_paths = ["lib"]
|
19
19
|
|
20
20
|
spec.add_dependency "trailblazer", ">= 1.0.4"
|
21
|
+
spec.add_dependency "trailblazer-loader", ">= 0.0.1"
|
21
22
|
|
22
23
|
spec.add_development_dependency "bundler", "~> 1.10"
|
23
24
|
spec.add_development_dependency "rake", "~> 10.0"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: trailblazer-rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nick Sutterer
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-12-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: trailblazer
|
@@ -24,6 +24,20 @@ dependencies:
|
|
24
24
|
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: 1.0.4
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: trailblazer-loader
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 0.0.1
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: 0.0.1
|
27
41
|
- !ruby/object:Gem::Dependency
|
28
42
|
name: bundler
|
29
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -183,11 +197,13 @@ files:
|
|
183
197
|
- lib/trailblazer/operation/responder.rb
|
184
198
|
- lib/trailblazer/operation/worker.rb
|
185
199
|
- lib/trailblazer/rails.rb
|
200
|
+
- lib/trailblazer/rails/application_controller.rb
|
186
201
|
- lib/trailblazer/rails/autoloading.rb
|
187
202
|
- lib/trailblazer/rails/railtie.rb
|
203
|
+
- lib/trailblazer/rails/test/integration.rb
|
188
204
|
- lib/trailblazer/rails/version.rb
|
189
205
|
- trailblazer-rails.gemspec
|
190
|
-
homepage: http://
|
206
|
+
homepage: http://trailblazer.to
|
191
207
|
licenses:
|
192
208
|
- MIT
|
193
209
|
metadata: {}
|