lacerda 1.0.1 → 1.1.0

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: 495c3cdcc8303a7c44e10ca0ab729e48dae46949
4
- data.tar.gz: 9431a4f40d54aa68c8136b4204029b81bc02658c
3
+ metadata.gz: 1c72c775cac5fa6c427773de8b002da68b01cead
4
+ data.tar.gz: 1b6adc7418567927bddd5ac87a7af26e859bd335
5
5
  SHA512:
6
- metadata.gz: 67acddb1e68d5f6f6e09242aa7c85b20c190d045aeecfed4c87ff8eb7eb04477e3ce635e7b21c8f8be2848c4a293d5298ba900fa8073619b7385b4cc3a07ff45
7
- data.tar.gz: b583d4b4f064e07a21e4f9e3981de683c624f886975c711c641f75530deac69504c0a02e0ddde7b25f18a4be9bb02b8448d60dff574f23fb8c29ed66b288bdef
6
+ metadata.gz: c0d3f4a41eb11d90c348d73f5295830461ee32c31f30cf14e84831acc453f99b0112081707abb4305c7aeda9a766947065e67eab60eeb2404185d116df3a39e6
7
+ data.tar.gz: aeace94ffb4d71e354124fd1d0a58b9563e8c55b8ad2baccf6a11559fa924980b9597c24930a335de42f6920c106c8adf189c5fc7f80d4c101b44ae7ecabc5a1
data/CHANGELOG.markdown CHANGED
@@ -1,3 +1,6 @@
1
+ # 1.1.0
2
+ - Update blumquist to show prettier errors
3
+
1
4
  # 1.0.0
2
5
  - Support multitype arrays
3
6
 
data/lacerda.gemspec CHANGED
@@ -25,7 +25,7 @@ Gem::Specification.new do |spec|
25
25
  spec.add_runtime_dependency "json-schema", ["~> 2.6"]
26
26
 
27
27
  spec.add_runtime_dependency "colorize"
28
- spec.add_runtime_dependency "blumquist", ["~> 0.7"]
28
+ spec.add_runtime_dependency "blumquist", ["~> 0.8"]
29
29
  spec.add_runtime_dependency "lounge_lizard", [">= 0.1.3", "~> 0.1"]
30
30
 
31
31
  spec.add_runtime_dependency "tins"
@@ -35,20 +35,22 @@ module Lacerda
35
35
  # Pluck out Data structures from it
36
36
  data_structures = data_structures_from_blueprint_ast(ast_file)
37
37
 
38
+ basename = File.basename(filename)
39
+ file_type = basename[/(consume|publish)\.mson$/]
40
+ if file_type.blank?
41
+ raise Error, "Invalid filename #{basename}, can't tell if it's a publish or consume schema"
42
+ end
43
+
38
44
  # Generate json schema from each contained data structure
39
45
  schema = {
40
46
  "$schema" => "http://json-schema.org/draft-04/schema#",
47
+ "id" => file_type.gsub('.mson', '.schema.json'),
41
48
  "title" => service_scope,
42
49
  "definitions" => {},
43
50
  "type" => "object",
44
51
  "properties" => {},
45
52
  }
46
53
 
47
- basename = File.basename(filename)
48
- if !basename.end_with?("publish.mson") and !basename.end_with?("consume.mson")
49
- raise Error, "Invalid filename #{basename}, can't tell if it's a publish or consume schema"
50
- end
51
-
52
54
  # The json schema we're constructing contains every known
53
55
  # object type in the 'definitions'. So if we have definitions for
54
56
  # the objects User, Post and Tag, the schema will look like this:
@@ -1,3 +1,3 @@
1
1
  module Lacerda
2
- VERSION = '1.0.1'
2
+ VERSION = '1.1.0'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lacerda
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jannis Hermanns
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-05-22 00:00:00.000000000 Z
11
+ date: 2017-08-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -72,14 +72,14 @@ dependencies:
72
72
  requirements:
73
73
  - - "~>"
74
74
  - !ruby/object:Gem::Version
75
- version: '0.7'
75
+ version: '0.8'
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.7'
82
+ version: '0.8'
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: lounge_lizard
85
85
  requirement: !ruby/object:Gem::Requirement
@@ -287,7 +287,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
287
287
  version: '0'
288
288
  requirements: []
289
289
  rubyforge_project:
290
- rubygems_version: 2.6.10
290
+ rubygems_version: 2.6.12
291
291
  signing_key:
292
292
  specification_version: 4
293
293
  summary: Markdown publish/consume contract parser and validator