Skip to content

Commit

Permalink
Finish 3.2.1
Browse files Browse the repository at this point in the history
  • Loading branch information
gkellogg committed Jan 29, 2022
2 parents 1750b56 + f6dca67 commit 8b2c69b
Show file tree
Hide file tree
Showing 10 changed files with 75 additions and 15 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Expand Up @@ -29,7 +29,7 @@ jobs:
ruby:
- 2.6
- 2.7
- 3.0
- "3.0"
- 3.1
- ruby-head
- jruby
Expand Down
27 changes: 27 additions & 0 deletions .github/workflows/generate-docs.yml
@@ -0,0 +1,27 @@
name: Build & deploy documentation
on:
push:
branches:
- master
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
name: Update gh-pages with docs
steps:
- name: Clone repository
uses: actions/checkout@v2
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: "3.1"
- name: Install required gem dependencies
run: gem install yard --no-document
- name: Build YARD Ruby Documentation
run: yardoc
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./doc/yard
publish_branch: gh-pages
14 changes: 7 additions & 7 deletions README.md
Expand Up @@ -200,7 +200,7 @@ Blank nodes associated with rdf:List statements used as part of a built-in are m
* [SXP][SXP gem] (~> 1.2)

## Documentation
Full documentation available on [RubyDoc.info](https://rubydoc.info/github/ruby-rdf/rdf-n3)
Full documentation available on [RubyDoc.info](https://ruby-rdf.github.io/rdf-n3)

### Principle Classes
* {RDF::N3}
Expand All @@ -220,7 +220,7 @@ Full documentation available on [RubyDoc.info](https://rubydoc.info/github/ruby-
## Resources
* [RDF.rb][RDF.rb]
* [Distiller](http://rdf.greggkellogg.net/distiller)
* [Documentation](https://rubydoc.info/github/ruby-rdf/rdf-n3/)
* [Documentation](https://ruby-rdf.github.io/rdf-n3/)
* [History](file:file.History.html)
* [Notation-3][N3]
* [Team Submission][]
Expand Down Expand Up @@ -262,7 +262,7 @@ see <https://unlicense.org/> or the accompanying {file:UNLICENSE} file.
* <https://github.com/ruby-rdf/rdf-n3>
* <https://lists.w3.org/Archives/Public/public-rdf-ruby/>

[RDF::Turtle]: https://ruby-rdf.github.com/rdf-turtle/
[RDF::Turtle]: https://ruby-rdf.github.io/rdf-turtle/
[Design Issues]: https://www.w3.org/DesignIssues/Notation3.html "Notation-3 Design Issues"
[Team Submission]: https://www.w3.org/TeamSubmission/n3/
[Turtle]: https://www.w3.org/TR/turtle/
Expand All @@ -274,7 +274,7 @@ see <https://unlicense.org/> or the accompanying {file:UNLICENSE} file.
[W3C N3 Community Group]: https://www.w3.org/community/n3-dev/
[N3]: https://w3c.github.io/N3/spec/
[PEG]: https://en.wikipedia.org/wiki/Parsing_expression_grammar
[RDF.rb]: https://ruby-rdf.github.com/rdf
[EBNF gem]: https://ruby-rdf.github.com/ebnf
[SPARQL gem]: https://ruby-rdf.github.com/sparql
[SXP gem]: https://ruby-rdf.github.com/sxp
[RDF.rb]: https://ruby-rdf.github.io/rdf
[EBNF gem]: https://ruby-rdf.github.io/ebnf
[SPARQL gem]: https://ruby-rdf.github.io/sparql
[SXP gem]: https://ruby-rdf.github.io/sxp
2 changes: 1 addition & 1 deletion VERSION
@@ -1 +1 @@
3.2.0
3.2.1
2 changes: 1 addition & 1 deletion lib/rdf/n3.rb
Expand Up @@ -14,7 +14,7 @@ module RDF
# end
# end
#
# @see http://www.rubydoc.info/github/ruby-rdf/rdf/
# @see https://ruby-rdf.github.io/rdf/
# @see https://www.w3.org/TR/REC-rdf-syntax/
#
# @author [Gregg Kellogg](http://greggkellogg.net/)
Expand Down
2 changes: 1 addition & 1 deletion lib/rdf/n3/algebra/str/concatenation.rb
Expand Up @@ -11,7 +11,7 @@ class Concatenation < RDF::N3::Algebra::ListOperator
##
# The string:concatenation operator takes a list of terms cast to strings and either binds the result of concatenating them to the output variable, removes a solution that does equal the literal object.
#
# List entries are stringified using {SPARQL::Algebra::Expression.cast}.
# List entries are stringified using [SPARQL::Algebra::Expression.cast](https://ruby-rdf.github.io/sparql/SPARQL/Algebra/Expression#cast-class_method).
#
# @param [RDF::N3::List] list
# @return [RDF::Term]
Expand Down
2 changes: 1 addition & 1 deletion lib/rdf/n3/reader.rb
Expand Up @@ -46,7 +46,7 @@ class Reader < RDF::Reader

##
# N3 Reader options
# @see http://www.rubydoc.info/github/ruby-rdf/rdf/RDF/Reader#options-class_method
# @see https://ruby-rdf.github.io/rdf/RDF/Reader#options-class_method
def self.options
super + [
RDF::CLI::Option.new(
Expand Down
28 changes: 27 additions & 1 deletion lib/rdf/n3/refinements.rb
Expand Up @@ -173,6 +173,32 @@ def evaluate(bindings, formulae:, **options)

refine ::RDF::Graph do
# Allow a graph to be treated as a term in a statement.
include ::RDF::Term

##
# @overload term?
# Returns `true` if `self` is a {RDF::Term}.
#
# @return [Boolean]
# @overload term?(name)
# Returns `true` if `self` contains the given RDF subject term.
#
# @param [RDF::Resource] value
# @return [Boolean]
def term?(*args)
case args.length
when 0 then true
when 1 then false
else raise ArgumentError("wrong number of arguments (given #{args.length}, expected 0 or 1)")
end
end

##
# Returns itself.
#
# @return [RDF::Value]
def to_term
statements.map(&:terms)
self
end
end
end
2 changes: 1 addition & 1 deletion lib/rdf/n3/writer.rb
Expand Up @@ -63,7 +63,7 @@ class Writer < RDF::Writer

##
# N3 Writer options
# @see http://www.rubydoc.info/github/ruby-rdf/rdf/RDF/Writer#options-class_method
# @see https://ruby-rdf.github.io/rdf/RDF/Writer#options-class_method
def self.options
super + [
RDF::CLI::Option.new(
Expand Down
9 changes: 8 additions & 1 deletion rdf-n3.gemspec
Expand Up @@ -6,10 +6,17 @@ Gem::Specification.new do |gem|
gem.date = File.mtime('VERSION').strftime('%Y-%m-%d')

gem.name = %q{rdf-n3}
gem.homepage = %q{https://ruby-rdf.github.com/rdf-n3}
gem.homepage = %q{https://ruby-rdf.github.io/rdf-n3}
gem.license = 'Unlicense'
gem.summary = %q{Notation3 reader/writer and reasoner for RDF.rb.}
gem.description = %q{RDF::N3 is an Notation-3 reader/writer and reasoner for the RDF.rb library suite.}
gem.metadata = {
"documentation_uri" => "https://ruby-rdf.github.io/rdf-n3",
"bug_tracker_uri" => "https://github.com/ruby-rdf/rdf-n3/issues",
"homepage_uri" => "https://github.com/ruby-rdf/rdf-n3",
"mailing_list_uri" => "https://lists.w3.org/Archives/Public/public-rdf-ruby/",
"source_code_uri" => "https://github.com/ruby-rdf/rdf-n3",
}

gem.authors = %w(Gregg Kellogg)
gem.email = 'public-rdf-ruby@w3.org'
Expand Down

0 comments on commit 8b2c69b

Please sign in to comment.