gameon 0.0.0.pre39 → 0.0.0.pre40

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/gameon/base.rb +14 -0
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 52478b70a44924993f6b3b9923bc492b585c80e0
4
- data.tar.gz: 18fa5e934d7be022cdbba9cfe8d394654eba1fff
3
+ metadata.gz: de07caf603612cf670819d2769adbbcfaaca1a38
4
+ data.tar.gz: 709aa7a4ad5802fc782cdf04b4d46a79812a16b9
5
5
  SHA512:
6
- metadata.gz: 540a1afdd367a68a062fe32b36e8bfc873b289c2594621909d566feca2300293288d00fa1861f9f20c74998ae8ee49f7d1037e197a699afc2eb76f5f9a9d8cf2
7
- data.tar.gz: e504418978b622d89793ad88654cc22e07c0f996e69f610e83014e7801f1c1efd20ea4d8d922780a4b783c03b2d79723ef5756f4c877f00530c12c8d4ace0889
6
+ metadata.gz: c1298adbbdaa80d0a0e6c708408927ff8f956a78c25e14b3ef8e90b96f2784692bc9edde3d930687d8ddebfb6ba6be13d62a1c6e75e6e978aff7cd320ddb203f
7
+ data.tar.gz: 0860b0a77413e33d28f4ee876d34eb889c983affc588cbdeeaf29c4fa32f376a89d65234cceaa4448c870102059c41a5999cce6d5367d8867b2e98795a38e408
data/lib/gameon/base.rb CHANGED
@@ -25,6 +25,20 @@ module GameOn
25
25
 
26
26
  module Engine
27
27
  extend Mushin::Engine
28
+ attr_accessor :middlewares, :stack
29
+ def self.run domain_context, activity
30
+ @middlewares = Mushin::DSL.find domain_context, activity
31
+ @stack = Middleware::Builder.new do
32
+ @middlewares.each do |middleware|
33
+ p "Mushin Logging: use #{middleware.name}, #{middleware.opts}, #{middleware.params}"
34
+ use middleware.name, middleware.opts, middleware.params
35
+ end
36
+ end
37
+ @setup_middlewares.each do |setup_middleware|
38
+ @stack.insert_before 0, setup_middleware
39
+ end
40
+ @stack.call
41
+ end
28
42
  end
29
43
 
30
44
  module Env
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gameon
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.0.pre39
4
+ version: 0.0.0.pre40
5
5
  platform: ruby
6
6
  authors:
7
7
  - theotherstupidguy