Skip to content

Commit fe2d571

Browse files
committed
Finish 3.2.1
2 parents ad4cc51 + fc87c00 commit fe2d571

File tree

12 files changed

+518
-477
lines changed

12 files changed

+518
-477
lines changed

.github/workflows/ci.yml

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,16 +19,10 @@ jobs:
1919
strategy:
2020
fail-fast: false
2121
matrix:
22-
ruby:
23-
- 2.6
24-
- 2.7
25-
- 3.0
26-
- 3.1
27-
- ruby-head
28-
- jruby
22+
ruby: [2.6, 2.7, '3.0', 3.1, 3.2, ruby-head, jruby]
2923
steps:
3024
- name: Clone repository
31-
uses: actions/checkout@v2
25+
uses: actions/checkout@v3
3226
- name: Set up Ruby
3327
uses: ruby/setup-ruby@v1
3428
with:
@@ -38,7 +32,7 @@ jobs:
3832
- name: Run tests
3933
run: ruby --version; bundle exec rspec spec || $ALLOW_FAILURES
4034
- name: Coveralls GitHub Action
41-
uses: coverallsapp/github-action@v1.1.2
35+
uses: coverallsapp/github-action@v2
4236
if: "matrix.ruby == '3.0'"
4337
with:
4438
github-token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/generate-docs.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Build & deploy documentation
2+
on:
3+
push:
4+
branches:
5+
- master
6+
workflow_dispatch:
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
name: Update gh-pages with docs
11+
steps:
12+
- name: Clone repository
13+
uses: actions/checkout@v3
14+
- name: Set up Ruby
15+
uses: ruby/setup-ruby@v1
16+
with:
17+
ruby-version: "3.1"
18+
- name: Install required gem dependencies
19+
run: gem install yard --no-document
20+
- name: Build YARD Ruby Documentation
21+
run: yardoc
22+
- name: Deploy
23+
uses: peaceiris/actions-gh-pages@v3
24+
with:
25+
github_token: ${{ secrets.GITHUB_TOKEN }}
26+
publish_dir: ./doc/yard
27+
publish_branch: gh-pages

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
This is a [Ruby][] implementation of [LD Patch][] for [RDF.rb][].
44

5-
[![Gem Version](https://badge.fury.io/rb/ld-patch.png)](https://badge.fury.io/rb/ld-patch)
5+
[![Gem Version](https://badge.fury.io/rb/ld-patch.svg)](https://badge.fury.io/rb/ld-patch)
66
[![Build Status](https://github.com/ruby-rdf/ld-patch/workflows/CI/badge.svg?branch=develop)](https://github.com/ruby-rdf/ld-patch/actions?query=workflow%3ACI)
77
[![Coverage Status](https://coveralls.io/repos/ruby-rdf/ld-patch/badge.svg?branch=develop)](https://coveralls.io/github/ruby-rdf/ld-patch?branch=develop)
88
[![Gitter chat](https://badges.gitter.im/ruby-rdf/rdf.png)](https://gitter.im/ruby-rdf/rdf)
@@ -118,6 +118,6 @@ A copy of the [LD Patch EBNF](file:etc/ld-patch.ebnf) and derived parser files a
118118
[SPARQL]: https://rubygems.org/gems/sparql
119119
[Linked Data]: https://rubygems.org/gems/linkeddata
120120
[SSE]: http://openjena.org/wiki/SSE
121-
[SXP]: https://rubygems.org/gems/sxp-ruby
121+
[SXP]: https://dryruby.github.io/sxp
122122
[LD Patch]: http://www.w3.org/TR/ldpatch/
123-
[LD-Patch doc]: http://rubydoc.info/github/ruby-rdf/ld-patch
123+
[LD-Patch doc]: https://ruby-rdf.github.io/ld-patch

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
3.2.0
1+
3.2.2

etc/doap.ttl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
<> a doap:Project, earl:TestSubject, earl:Software ;
1313
doap:name "LD::Patch" ;
14-
doap:homepage <https://ruby-rdf.github.com/ld-patch> ;
14+
doap:homepage <https://ruby-rdf.github.io/ld-patch> ;
1515
doap:license <https://unlicense.org/1.0/> ;
1616
doap:shortdesc "W3C Linked Data Patch Format for RDF.rb."@en ;
1717
doap:description "Implements the W3C Linked Data Patch Format and operations for RDF.rb."@en ;

etc/earl.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,8 +88,8 @@ <h2>
8888
<dd property='doap:programming-language'>Ruby</dd>
8989
<dt>Home Page</dt>
9090
<dd property='doap:homepage'>
91-
<a href='http://ruby-rdf.github.com/ld-patch'>
92-
http://ruby-rdf.github.com/ld-patch
91+
<a href='https://ruby-rdf.github.io/ld-patch'>
92+
https://ruby-rdf.github.io/ld-patch
9393
</a>
9494
</dd>
9595
<dt>Developer</dt>

etc/earl.jsonld

Lines changed: 453 additions & 453 deletions
Large diffs are not rendered by default.

etc/earl.ttl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
<https://rubygems.org/gems/ld-patch> a doap:Project, earl:TestSubject, earl:Software ;
1212
doap:name "LD::Patch" ;
13-
doap:homepage <http://ruby-rdf.github.com/ld-patch> ;
13+
doap:homepage <https://ruby-rdf.github.io/ld-patch> ;
1414
doap:license <https://unlicense.org/1.0/> ;
1515
doap:shortdesc "W3C Linked Data Patch Format for RDF.rb."@en ;
1616
doap:description """

ld-patch.gemspec

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,13 @@ Gem::Specification.new do |gem|
99
gem.homepage = "https://github.com/ruby-rdf/ld-patch"
1010
gem.license = 'Unlicense'
1111
gem.summary = "W3C Linked Data Patch Format for RDF.rb."
12+
gem.metadata = {
13+
"documentation_uri" => "https://ruby-rdf.github.io/ld-patch",
14+
"bug_tracker_uri" => "https://github.com/ruby-rdf/ld-patch/issues",
15+
"homepage_uri" => "https://github.com/ruby-rdf/ld-patch",
16+
"mailing_list_uri" => "https://lists.w3.org/Archives/Public/public-rdf-ruby/",
17+
"source_code_uri" => "https://github.com/ruby-rdf/ld-patch",
18+
}
1219

1320
gem.authors = ['Gregg Kellogg']
1421
gem.email = '[email protected]'
@@ -23,18 +30,19 @@ Gem::Specification.new do |gem|
2330
gem.required_ruby_version = '>= 2.6'
2431
gem.requirements = []
2532
gem.add_runtime_dependency 'rdf', '~> 3.2'
26-
gem.add_runtime_dependency 'ebnf', '~> 2.2'
33+
gem.add_runtime_dependency 'ebnf', '~> 2.3'
2734
gem.add_runtime_dependency 'sparql', '~> 3.2'
2835
gem.add_runtime_dependency 'sxp', '~> 1.2'
2936
gem.add_runtime_dependency 'rdf-xsd', '~> 3.2'
3037

3138
gem.add_development_dependency 'json-ld', '~> 3.2'
32-
gem.add_development_dependency 'rack', '~> 2.2'
39+
gem.add_development_dependency 'rack', '~> 3.0'
40+
gem.add_development_dependency 'rdf-normalize', '~> 0.6'
3341
gem.add_development_dependency 'rdf-spec', '~> 3.2'
34-
gem.add_development_dependency 'rspec', '~> 3.10'
42+
gem.add_development_dependency 'rspec', '~> 3.12'
3543
gem.add_development_dependency 'rspec-its', '~> 1.3'
3644
gem.add_development_dependency 'yard' , '~> 0.9'
37-
gem.add_development_dependency 'webmock', '~> 3.11'
45+
gem.add_development_dependency 'webmock', '~> 3.18'
3846

3947
gem.post_install_message = nil
4048
end

lib/ld/patch/format.rb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,9 @@ module LD::Patch
1111
#
1212
# @see http://www.w3.org/TR/ldpatch/
1313
class Format < RDF::Format
14-
content_type 'text/ldpatch', extension: :ldp
14+
content_type 'text/ldpatch',
15+
extension: :ldp,
16+
uri: 'http://www.w3.org/ns/formats/LD_Patch'
1517
content_encoding 'utf-8'
1618

1719
##

spec/format_spec.rb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@
2626
specify {expect(described_class.to_sym).to eq :ldpatch}
2727
end
2828

29+
describe "#to_uri" do
30+
specify {expect(described_class.to_uri).to eq RDF::URI('http://www.w3.org/ns/formats/LD_Patch')}
31+
end
32+
2933
describe ".cli_commands" do
3034
require 'rdf/cli'
3135
let(:nt) {File.expand_path("../test-files/1triple.nt", __FILE__)}

spec/suite_helper.rb

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
# Used for Turtle tests
33
require 'rdf/turtle'
44
require 'json/ld'
5+
require 'rdf/normalize'
56

67
# For now, override RDF::Utils::File.open_file to look for the file locally before attempting to retrieve it
78
module RDF::Util
@@ -132,6 +133,7 @@ def entries
132133

133134
class Entry < JSON::LD::Resource
134135
attr_accessor :debug
136+
def format; :normalize; end # for debug output
135137

136138
def base
137139
action.is_a?(Hash) ? action.fetch("base", action["data"]) : action
@@ -151,15 +153,19 @@ def data
151153
end
152154

153155
def target_graph
154-
@graph ||= RDF::Graph.load(CGI.unescape(data), base_uri: base)
156+
@graph ||= RDF::Graph.new do |g|
157+
g << RDF::Reader.open(CGI.unescape(data), base_uri: base)
158+
end
155159
end
156160

157161
def expected
158162
@expected ||= RDF::Util::File.open_file(CGI.unescape(result)) {|f| f.read}
159163
end
160164

161165
def expected_graph
162-
@expected_graph ||= RDF::Graph.load(CGI.unescape(result), base_uri: base)
166+
@expected_graph ||= RDF::Graph.new do |g|
167+
g << RDF::Reader.open(CGI.unescape(result), base_uri: base)
168+
end
163169
end
164170

165171
def evaluate?

0 commit comments

Comments
 (0)