simple_ams 0.2.1 → 0.2.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (42) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/ruby.yml +28 -0
  3. data/.rubocop.yml +56 -0
  4. data/CHANGELOG.md +22 -0
  5. data/Gemfile +2 -2
  6. data/README.md +665 -116
  7. data/Rakefile +3 -3
  8. data/bin/console +3 -3
  9. data/lib/simple_ams.rb +34 -33
  10. data/lib/simple_ams/adapters/ams.rb +26 -32
  11. data/lib/simple_ams/adapters/jsonapi.rb +47 -64
  12. data/lib/simple_ams/document.rb +38 -37
  13. data/lib/simple_ams/document/fields.rb +36 -37
  14. data/lib/simple_ams/document/forms.rb +7 -9
  15. data/lib/simple_ams/document/generics.rb +35 -37
  16. data/lib/simple_ams/document/links.rb +7 -9
  17. data/lib/simple_ams/document/metas.rb +7 -11
  18. data/lib/simple_ams/document/primary_id.rb +14 -17
  19. data/lib/simple_ams/document/relations.rb +99 -109
  20. data/lib/simple_ams/dsl.rb +73 -71
  21. data/lib/simple_ams/methy.rb +2 -2
  22. data/lib/simple_ams/options.rb +267 -265
  23. data/lib/simple_ams/options/adapter.rb +2 -2
  24. data/lib/simple_ams/options/concerns/filterable.rb +29 -34
  25. data/lib/simple_ams/options/concerns/mod.rb +4 -0
  26. data/lib/simple_ams/options/concerns/name_value_hash.rb +25 -26
  27. data/lib/simple_ams/options/concerns/tracked_properties.rb +15 -17
  28. data/lib/simple_ams/options/concerns/value_hash.rb +25 -26
  29. data/lib/simple_ams/options/fields.rb +1 -1
  30. data/lib/simple_ams/options/forms.rb +1 -2
  31. data/lib/simple_ams/options/generics.rb +2 -4
  32. data/lib/simple_ams/options/includes.rb +1 -1
  33. data/lib/simple_ams/options/links.rb +1 -1
  34. data/lib/simple_ams/options/metas.rb +1 -1
  35. data/lib/simple_ams/options/primary_id.rb +1 -1
  36. data/lib/simple_ams/options/relations.rb +9 -7
  37. data/lib/simple_ams/options/type.rb +1 -2
  38. data/lib/simple_ams/renderer.rb +43 -41
  39. data/lib/simple_ams/version.rb +1 -1
  40. data/simple_ams.gemspec +17 -17
  41. metadata +30 -27
  42. data/.travis.yml +0 -5
@@ -1,3 +1,3 @@
1
1
  module SimpleAMS
2
- VERSION = "0.2.1"
2
+ VERSION = '0.2.6'.freeze
3
3
  end
data/simple_ams.gemspec CHANGED
@@ -1,29 +1,29 @@
1
- # coding: utf-8
2
- lib = File.expand_path("../lib", __FILE__)
1
+ lib = File.expand_path('lib', __dir__)
3
2
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
- require "simple_ams/version"
3
+ require 'simple_ams/version'
5
4
 
6
5
  Gem::Specification.new do |spec|
7
- spec.name = "simple_ams"
6
+ spec.name = 'simple_ams'
8
7
  spec.version = SimpleAMS::VERSION
9
- spec.authors = ["Filippos Vasilakis"]
10
- spec.email = ["vasilakisfil@gmail.com"]
8
+ spec.authors = ['Filippos Vasilakis']
9
+ spec.email = ['vasilakisfil@gmail.com']
11
10
 
12
- spec.summary = %q{ActiveModel Serializers, simplified.}
13
- spec.description = %q{ActiveModel Serializers, simplified.}
14
- spec.homepage = "https://github.com/vasilakisfil/simple-ams"
11
+ spec.summary = 'ActiveModel Serializers, simplified.'
12
+ spec.description = 'ActiveModel Serializers, simplified.'
13
+ spec.homepage = 'https://github.com/vasilakisfil/SimpleAMS'
15
14
 
16
15
  spec.files = `git ls-files -z`.split("\x0").reject do |f|
17
16
  f.match(%r{^(test|spec|features)/})
18
17
  end
19
- spec.bindir = "exe"
18
+ spec.bindir = 'exe'
20
19
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
21
- spec.require_paths = ["lib"]
20
+ spec.require_paths = ['lib']
21
+ spec.required_ruby_version = '>= 2.4'
22
22
 
23
- spec.add_development_dependency "bundler", "~> 2.0.2"
24
- spec.add_development_dependency "rake", "~> 10.0"
25
- spec.add_development_dependency "rspec", "~> 3.0"
26
- spec.add_development_dependency "faker", "~> 1.8.5"
27
- spec.add_development_dependency "pry", "~> 0.11.3"
28
- spec.add_development_dependency "simplecov"
23
+ spec.add_development_dependency 'faker', '~> 2.16'
24
+ spec.add_development_dependency 'pry', '~> 0.14.0'
25
+ spec.add_development_dependency 'rake', '>= 12.3.3'
26
+ spec.add_development_dependency 'rspec', '~> 3.0'
27
+ spec.add_development_dependency 'rubocop', '~> 0.93.1'
28
+ spec.add_development_dependency 'simplecov', '~> 0.21.2'
29
29
  end
metadata CHANGED
@@ -1,99 +1,99 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: simple_ams
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Filippos Vasilakis
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-12-02 00:00:00.000000000 Z
11
+ date: 2021-03-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: bundler
14
+ name: faker
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 2.0.2
19
+ version: '2.16'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 2.0.2
26
+ version: '2.16'
27
27
  - !ruby/object:Gem::Dependency
28
- name: rake
28
+ name: pry
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '10.0'
33
+ version: 0.14.0
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: '10.0'
40
+ version: 0.14.0
41
41
  - !ruby/object:Gem::Dependency
42
- name: rspec
42
+ name: rake
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - "~>"
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
- version: '3.0'
47
+ version: 12.3.3
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - "~>"
52
+ - - ">="
53
53
  - !ruby/object:Gem::Version
54
- version: '3.0'
54
+ version: 12.3.3
55
55
  - !ruby/object:Gem::Dependency
56
- name: faker
56
+ name: rspec
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - "~>"
60
60
  - !ruby/object:Gem::Version
61
- version: 1.8.5
61
+ version: '3.0'
62
62
  type: :development
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
- version: 1.8.5
68
+ version: '3.0'
69
69
  - !ruby/object:Gem::Dependency
70
- name: pry
70
+ name: rubocop
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
73
  - - "~>"
74
74
  - !ruby/object:Gem::Version
75
- version: 0.11.3
75
+ version: 0.93.1
76
76
  type: :development
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.11.3
82
+ version: 0.93.1
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: simplecov
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
- - - ">="
87
+ - - "~>"
88
88
  - !ruby/object:Gem::Version
89
- version: '0'
89
+ version: 0.21.2
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
- - - ">="
94
+ - - "~>"
95
95
  - !ruby/object:Gem::Version
96
- version: '0'
96
+ version: 0.21.2
97
97
  description: ActiveModel Serializers, simplified.
98
98
  email:
99
99
  - vasilakisfil@gmail.com
@@ -101,9 +101,11 @@ executables: []
101
101
  extensions: []
102
102
  extra_rdoc_files: []
103
103
  files:
104
+ - ".github/workflows/ruby.yml"
104
105
  - ".gitignore"
105
106
  - ".rspec"
106
- - ".travis.yml"
107
+ - ".rubocop.yml"
108
+ - CHANGELOG.md
107
109
  - Gemfile
108
110
  - README.md
109
111
  - Rakefile
@@ -126,6 +128,7 @@ files:
126
128
  - lib/simple_ams/options.rb
127
129
  - lib/simple_ams/options/adapter.rb
128
130
  - lib/simple_ams/options/concerns/filterable.rb
131
+ - lib/simple_ams/options/concerns/mod.rb
129
132
  - lib/simple_ams/options/concerns/name_value_hash.rb
130
133
  - lib/simple_ams/options/concerns/tracked_properties.rb
131
134
  - lib/simple_ams/options/concerns/value_hash.rb
@@ -141,7 +144,7 @@ files:
141
144
  - lib/simple_ams/renderer.rb
142
145
  - lib/simple_ams/version.rb
143
146
  - simple_ams.gemspec
144
- homepage: https://github.com/vasilakisfil/simple-ams
147
+ homepage: https://github.com/vasilakisfil/SimpleAMS
145
148
  licenses: []
146
149
  metadata: {}
147
150
  post_install_message:
@@ -152,14 +155,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
152
155
  requirements:
153
156
  - - ">="
154
157
  - !ruby/object:Gem::Version
155
- version: '0'
158
+ version: '2.4'
156
159
  required_rubygems_version: !ruby/object:Gem::Requirement
157
160
  requirements:
158
161
  - - ">="
159
162
  - !ruby/object:Gem::Version
160
163
  version: '0'
161
164
  requirements: []
162
- rubygems_version: 3.0.3
165
+ rubygems_version: 3.2.3
163
166
  signing_key:
164
167
  specification_version: 4
165
168
  summary: ActiveModel Serializers, simplified.
data/.travis.yml DELETED
@@ -1,5 +0,0 @@
1
- sudo: false
2
- language: ruby
3
- rvm:
4
- - 2.4.1
5
- before_install: gem install bundler -v 1.15.4