Skip to content

Commit 2d314c7

Browse files
committed
Release 1.1.6.
* Add :simple_compact_iri option to only use simple terms when creating compact IRIs. * Enable SSL mode, and don't verify, when retrieving files. * Added Context#from_vocabulary and script/gen_context to generate a JSON-LD context given an RDFS/OWL/schema.org vocabulary. * Make loading remote context error fail, even if validate is not set (#11). * Added :frame option to writer to specify frame to be used instead of context. * Added Context#reverse_term to find a term definition reversed from that requested. * Make Context#mappings, #mapping, and #languages private (used only in tests). * Make Context#alias and #coerce protected. * Added Context#find_definition to find a term definition. * Detect lists having nodes shared across different graphs, and add fromRdf test to check for this.
2 parents f8fcb52 + 8711acc commit 2d314c7

27 files changed

+32379
-413
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@
99

1010
JSON::LD parses and serializes [JSON-LD][] into [RDF][] and implements expansion, compaction and framing API interfaces.
1111

12+
JSON::LD can now be used to create a _context_ from an RDFS/OWL definition, and optionally include a JSON-LD representation of the ontology itself. This is currently accessed through the `script/gen_context` script.
13+
1214
Install with `gem install json-ld`
1315

1416
## Examples

Rakefile

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,17 @@ RSpec::Core::RakeTask.new("doc:spec") do |spec|
3131
spec.rspec_opts = ["--format", "html", "-o", "doc/spec.html"]
3232
end
3333

34+
desc "Generate schema.org context"
35+
task :schema_context do
36+
%x(
37+
script/gen_context http://schema.org/docs/schema_org_rdfa.html \
38+
--vocab http://schema.org/ \
39+
--prefix 'schema http://schema.org/' \
40+
--body --hier \
41+
--o etc/schema.org.jsonld
42+
)
43+
end
44+
3445
# Presentation building
3546
namespace :presentation do
3647
desc "Clean presentation files"

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.1.5
1+
1.1.6

bin/jsonld

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/usr/bin/env ruby
22
require 'rubygems'
3-
$:.unshift(File.expand_path(File.join(File.dirname(__FILE__), "..", 'lib')))
3+
$:.unshift(File.expand_path("../../lib", __FILE__))
44
begin
55
require 'linkeddata'
66
rescue LoadError
@@ -62,7 +62,7 @@ rescue
6262
end
6363

6464
parser_options = {
65-
:base => "",
65+
:base => nil,
6666
:progress => false,
6767
:validate => false,
6868
:strict => false,

0 commit comments

Comments
 (0)