Skip to content

Commit a1f4cb4

Browse files
author
Andy Newton
committed
prepping for release of 0.7.0
1 parent 5027903 commit a1f4cb4

File tree

3 files changed

+30
-5
lines changed

3 files changed

+30
-5
lines changed

.travis.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,13 @@ os:
55
rvm:
66
- 2.1.3
77
- 2.3.4
8-
- 2.4.0
8+
- 2.4
9+
- jruby-9.1
10+
matrix:
11+
exclude:
12+
- rvm: 2.1.3
13+
os: osx
14+
- rvm: jruby-9.1
15+
os: osx
916
script:
1017
- "bundle exec rake test"

README.md

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -109,13 +109,18 @@ which can be found [here](https://raw.githubusercontent.com/arineng/jcr/09/draft
109109
* 0.6.3 - XOR experimentation which was never merged
110110
* 0.6.4 - Version that matches -07 of the draft specification
111111
* 0.6.5 - Fixed a bug with roots and empty object and array rules
112-
* next
112+
* 0.7.0
113113
* Tracks the -09 draft
114114
* Fixes to allow annotations for groups in arrays and objects
115115
* Text output is now proper JCR
116116
* Fixed issue with multiple files on the command line with MacOS
117117
* Support for Ruby 2.4
118-
* Dropped Ruby 1.8, 1.9, and 2.0. Now only testing against 2.1, 2.3 and 2.4
118+
* Dropped Ruby 1.8, 1.9, and 2.0. CI testing on:
119+
* Linux 2.1, 2.3, 2.4, and JRuby 9.1
120+
* OSX 2.3 and 2.4
121+
* Fixes to ABNF in multi-line directives
122+
* Much better CLI and programmatic validation failure information and structures
123+
* Fixes to print errors when the JCR fails to parse
119124

120125
The current version of the JCR specification can be found
121126
[here](https://raw.githubusercontent.com/arineng/jcr/07/draft-newton-json-content-rules.txt)
@@ -165,18 +170,30 @@ Usage: jcr [OPTIONS] [JSON_FILES]
165170
166171
Evaluates JSON against JSON Content Rules (JCR).
167172
173+
If -J is not specified, JSON_FILES is used.
168174
If JSON_FILES is not specified, standard input (STDIN) is used.
169175
170176
Use -v to see results, otherwise check the exit code.
171177
172178
Options
173179
-r FILE file containing ruleset
174180
-R STRING string containing ruleset. Should probably be quoted
175-
-s STRING name of root rule. All roots will be tried if none is specified
181+
--test-jcr parse and test the JCR only
182+
-S STRING name of root rule. All roots will be tried if none is specified
176183
-o FILE file containing overide ruleset (option can be repeated)
177184
-O STRING string containing overide rule (option can be repeated)
185+
-J STRING string containing JSON to evaluate. Should probably be quoted
178186
-v verbose
187+
-q quiet
179188
-h display help
189+
190+
Return codes:
191+
0 = success
192+
1 = parsing or other bad condition
193+
2 = fall through bad condition
194+
3 = unsuccessful evaluation of JSON
195+
196+
JCR Version 0.7.0
180197
```
181198

182199
## Usage as a Library
@@ -186,6 +203,7 @@ It is easy to call the JCR Validator from Ruby programs. The `examples` director
186203
* `simple.rb` is a simple and basic example
187204
* `override.rb` shows how to override specific rules in a ruleset.
188205
* `callback.rb` demonstrates how to do custom validation with callbacks
206+
* `trace_failures.rb` demonstrates how to access validation failure information
189207

190208
### Custom Validation Using Callbacks
191209

lib/jcr/version.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,6 @@
1515

1616
module JCR
1717

18-
VERSION = "0.6.5"
18+
VERSION = "0.7.0"
1919

2020
end

0 commit comments

Comments
 (0)