tyrant 0.0.2 → 0.0.3

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
  SHA1:
3
- metadata.gz: 0686d74d8af9df770a7c8eedd729b6e375e0bed2
4
- data.tar.gz: f079966822ca11c34637655e8d520b96941f664e
3
+ metadata.gz: ae6e5bc3c5f10b700b4fa7a1b9367bdb38dab643
4
+ data.tar.gz: e4bfa297faa7fbab867970e1ef4e9498a4fd12ac
5
5
  SHA512:
6
- metadata.gz: b46e96e5e3c37e22069bd40c05633940ccd00974c0a6805f7805c793b518271e080c35b44c9107404c5577d1f3039554cf85546e2bd0d458c3c90d9d4b83a2f9
7
- data.tar.gz: a716baf50d9fa237adc43eb47d0ec6da6e01dfeb0b565df26de551eb6a64ff11fffc7828c0820256ef6bc5d1a9e93968186b36f3b4f86fa1a8b405c5fce661de
6
+ metadata.gz: abbd72e5015f4cb98c20e27cba271c8ec62346faeaf5d20da9b8d7ea27a7e411cb91fa627d7b97c3b2e5e21bdeb67fd5373c3870f4d6d237f3ac84cb3f5bb300
7
+ data.tar.gz: 016cf7f97167627ca66ee74e771791dbc91176a0340e17ae2840908e76e33b1c3f2c1922851d8dce50c49e0948e711349b999eac406b5251edb76341558d91f2
@@ -0,0 +1,3 @@
1
+ # 0.0.3
2
+
3
+ * Require `warden` as dependency.
data/README.md CHANGED
@@ -43,7 +43,7 @@ You can also run the public API in any other Ruby environment, e.g. a console or
43
43
  Tyrant::SignIn.run(params)
44
44
  ```
45
45
 
46
- Tyrant provides forms for all workflow steps. using Reform objects that are embedded into the operations.
46
+ Tyrant provides forms for all workflow steps. using [Reform](https://github.com/apotonick/reform) objects that are embedded into the operations.
47
47
 
48
48
 
49
49
  => Customize with inheritance, or override. Or just don't use the operation and write your own "step".
@@ -3,13 +3,14 @@ module Tyrant
3
3
  require "warden"
4
4
 
5
5
  # DISCUSS: it will be configurable what user class etc. and might be moved to Ops.
6
+ # DISCUSS: this should actually use Tyrant::Session to log in and out user?
6
7
  config.app_middleware.use Warden::Manager do |config|
7
8
  Warden::Manager.serialize_into_session do |user|
8
9
  user.id
9
10
  end
10
11
 
11
12
  Warden::Manager.serialize_from_session do |id|
12
- User.find_by(id: id)
13
+ User.find_by(id: id) # Session.sign_in!(user) or something!
13
14
  end
14
15
  end
15
16
  end
@@ -1,12 +1,16 @@
1
1
  require "trailblazer/operation"
2
+ require "trailblazer/operation/model"
2
3
  require "active_model"
3
4
  require "reform/form/active_model/validations" # TODO: this will get replaced with Lotus.
4
5
  require "reform/form/validation/unique_validator.rb"
6
+
7
+
8
+
5
9
  module Tyrant
6
10
  # SignUp will come and implement to-be-confirmed sign up.
7
11
  class SignUp < Trailblazer::Operation
8
12
  class Confirmed < Trailblazer::Operation
9
- include CRUD
13
+ include Model
10
14
  model User, :create
11
15
 
12
16
  contract do
@@ -1,3 +1,3 @@
1
1
  module Tyrant
2
- VERSION = "0.0.2"
2
+ VERSION = "0.0.3"
3
3
  end
@@ -24,9 +24,10 @@ Gem::Specification.new do |spec|
24
24
 
25
25
  spec.add_development_dependency "activemodel"
26
26
 
27
- spec.add_dependency "trailblazer"
27
+ spec.add_dependency "trailblazer", "~> 1.0"
28
28
  spec.add_dependency "reform", "~> 2.0"
29
29
  spec.add_dependency "disposable", ">= 0.1.11"
30
30
 
31
+ spec.add_dependency "warden"
31
32
  spec.add_dependency "bcrypt"
32
33
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tyrant
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nick Sutterer
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2015-09-04 00:00:00.000000000 Z
11
+ date: 2015-12-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -70,16 +70,16 @@ dependencies:
70
70
  name: trailblazer
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
- - - ">="
73
+ - - "~>"
74
74
  - !ruby/object:Gem::Version
75
- version: '0'
75
+ version: '1.0'
76
76
  type: :runtime
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
- - - ">="
80
+ - - "~>"
81
81
  - !ruby/object:Gem::Version
82
- version: '0'
82
+ version: '1.0'
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: reform
85
85
  requirement: !ruby/object:Gem::Requirement
@@ -108,6 +108,20 @@ dependencies:
108
108
  - - ">="
109
109
  - !ruby/object:Gem::Version
110
110
  version: 0.1.11
111
+ - !ruby/object:Gem::Dependency
112
+ name: warden
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - ">="
116
+ - !ruby/object:Gem::Version
117
+ version: '0'
118
+ type: :runtime
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - ">="
123
+ - !ruby/object:Gem::Version
124
+ version: '0'
111
125
  - !ruby/object:Gem::Dependency
112
126
  name: bcrypt
113
127
  requirement: !ruby/object:Gem::Requirement
@@ -131,6 +145,7 @@ extra_rdoc_files: []
131
145
  files:
132
146
  - ".gitignore"
133
147
  - ".travis.yml"
148
+ - CHANGES.md
134
149
  - Gemfile
135
150
  - LICENSE.txt
136
151
  - README.md
@@ -167,4 +182,3 @@ signing_key:
167
182
  specification_version: 4
168
183
  summary: Agnostic authorization for Trailblazer.
169
184
  test_files: []
170
- has_rdoc: