fitting 2.10.0 → 2.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f8a58b7be52158cd26f8ae3fd7454cbc89512610
4
- data.tar.gz: cb6bb15b054e2ec15e6262d16e3c697932d81640
3
+ metadata.gz: 9fe2c40a89499b32b2a4989a88cb8d294c420191
4
+ data.tar.gz: cd0deaa0b1fb6003bc6c58054def0843fa22e656
5
5
  SHA512:
6
- metadata.gz: ffb5323b7ab335ad9f2ad966c7bfd2249b9388dcc9d434f35eff2f7626ba97ce3a5ac5f6bf386041840f7db397fe8c596ae52c95406e584120558865340a8742
7
- data.tar.gz: 8db3c993339889701401ec962e0576f31ea746cbec06e3c5f326fe07487527cec79d36a20a7de0c5949418ebf2e2aaee5b9c269e03446a740530a0006535d51e
6
+ metadata.gz: 1e2e177b230a274a1e53d2eb525f6f59f89ffcdcc9ae4392183f0021ae727f3a4d48499dd870bf853ea49a21d7eeec00c9196f1659506348d14dae07287688e3
7
+ data.tar.gz: a4ae0ec1d99a3f6b9d9e9fd10bcdeaf592be1335ada092481dece76250da9caa5f4f3cf084d290f792bb16fa897fe361a0967c4c739f918fcedb53a4e8d3bac9
@@ -1,5 +1,15 @@
1
1
  # Change log
2
2
 
3
+ ### 2.11.0 - 2019-09-09
4
+
5
+ * features
6
+ * crafter_apib_path
7
+ * drafter_4_apib_path
8
+ * drafter_4_yaml_path
9
+
10
+ * fixes
11
+ * crafter_yaml_path
12
+
3
13
  ### 2.10.0 - 2019-09-05
4
14
 
5
15
  * features
data/README.md CHANGED
@@ -167,15 +167,27 @@ If your project uses several prefixes, for each one you need to create a separat
167
167
 
168
168
  ### apib_path
169
169
 
170
- Path to API Blueprint documentation. There must be an installed [drafter](https://github.com/apiaryio/drafter) to parse it.
170
+ Path to API Blueprint v3 documentation. There must be an installed [drafter](https://github.com/apiaryio/drafter) to parse it.
171
171
 
172
172
  ### drafter_yaml_path
173
173
 
174
- Path to API Blueprint documentation pre-parsed with `drafter` and saved to a YAML file.
174
+ Path to API Blueprint v3 documentation pre-parsed with `drafter` and saved to a YAML file.
175
+
176
+ ### drafter_4_apib_path
177
+
178
+ Path to API Blueprint v4 documentation. There must be an installed [drafter](https://github.com/apiaryio/drafter) to parse it.
179
+
180
+ ### drafter_4_yaml_path
181
+
182
+ Path to API Blueprint v4 documentation pre-parsed with `drafter` and saved to a YAML file.
183
+
184
+ ### crafter_apib_path
185
+
186
+ Path to API Blueprint v4 documentation.
175
187
 
176
188
  ### crafter_yaml_path
177
189
 
178
- Path to API Blueprint documentation pre-parsed with `crafter` and saved to a YAML file.
190
+ Path to API Blueprint v4 documentation pre-parsed with `crafter` and saved to a YAML file.
179
191
 
180
192
  ### tomogram_json_path
181
193
 
@@ -5,6 +5,10 @@ module Fitting
5
5
  class Legacy
6
6
  attr_accessor :apib_path,
7
7
  :drafter_yaml_path,
8
+ :crafter_apib_path,
9
+ :crafter_yaml_path,
10
+ :drafter_4_apib_path,
11
+ :drafter_4_yaml_path,
8
12
  :strict,
9
13
  :prefix,
10
14
  :white_list,
@@ -20,12 +24,18 @@ module Fitting
20
24
  end
21
25
 
22
26
  def tomogram
23
- @tomogram ||= if @crafter_yaml_path
27
+ @tomogram ||= if @crafter_apib_path || @crafter_yaml_path
24
28
  Tomograph::Tomogram.new(
25
29
  prefix: @prefix,
26
- apib_path: @apib_path,
30
+ crafter_apib_path: @crafter_apib_path,
27
31
  crafter_yaml_path: @crafter_yaml_path
28
32
  )
33
+ elsif @drafter_4_apib_path || @drafter_4_yaml_path
34
+ Tomograph::Tomogram.new(
35
+ prefix: @prefix,
36
+ drafter_4_apib_path: @drafter_4_apib_path,
37
+ drafter_4_yaml_path: @drafter_4_yaml_path
38
+ )
29
39
  else Tomograph::Tomogram.new(
30
40
  prefix: @prefix,
31
41
  apib_path: @apib_path,
@@ -6,7 +6,10 @@ module Fitting
6
6
  attr_reader :title
7
7
  attr_accessor :apib_path,
8
8
  :drafter_yaml_path,
9
+ :crafter_apib_path,
9
10
  :crafter_yaml_path,
11
+ :drafter_4_apib_path,
12
+ :drafter_4_yaml_path,
10
13
  :tomogram_json_path,
11
14
  :strict,
12
15
  :prefix,
@@ -19,7 +22,10 @@ module Fitting
19
22
  def initialize(yaml, title = 'fitting')
20
23
  @apib_path = yaml['apib_path']
21
24
  @drafter_yaml_path = yaml['drafter_yaml_path']
25
+ @crafter_apib_path = yaml['crafter_apib_path']
22
26
  @crafter_yaml_path = yaml['crafter_yaml_path']
27
+ @drafter_4_apib_path = yaml['drafter_4_apib_path']
28
+ @drafter_4_yaml_path = yaml['drafter_4_yaml_path']
23
29
  @tomogram_json_path = yaml['tomogram_json_path']
24
30
  @strict = yaml['strict']
25
31
  @prefix = yaml['prefix']
@@ -33,12 +39,17 @@ module Fitting
33
39
  end
34
40
 
35
41
  def tomogram
36
- @tomogram ||= if @crafter_yaml_path
42
+ @tomogram ||= if @crafter_yaml_path || @crafter_apib_path
37
43
  Tomograph::Tomogram.new(
38
44
  prefix: @prefix,
39
- apib_path: @apib_path,
45
+ crafter_apib_path: @crafter_apib_path,
40
46
  crafter_yaml_path: @crafter_yaml_path,
41
- tomogram_json_path: @tomogram_json_path
47
+ )
48
+ elsif @drafter_4_apib_path || @drafter_4_yaml_path
49
+ Tomograph::Tomogram.new(
50
+ prefix: @prefix,
51
+ drafter_4_apib_path: @drafter_4_apib_path,
52
+ drafter_4_yaml_path: @drafter_4_yaml_path,
42
53
  )
43
54
  else
44
55
  Tomograph::Tomogram.new(
@@ -1,3 +1,3 @@
1
1
  module Fitting
2
- VERSION = '2.10.0'.freeze
2
+ VERSION = '2.11.0'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fitting
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.10.0
4
+ version: 2.11.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - d.efimov
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-09-05 00:00:00.000000000 Z
11
+ date: 2019-09-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json-schema