Skip to content

Commit

Permalink
add doc script to run after build for local testing, include ANNOds i…
Browse files Browse the repository at this point in the history
…n doc, resolve #3
  • Loading branch information
KonradHoeffner committed Jun 12, 2024
1 parent 93c0bca commit 9d06c79
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 4 deletions.
14 changes: 11 additions & 3 deletions .github/workflows/doc.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,26 @@
name: Generate and Publish Ontology Documentation

# dist branch will not fire push trigger, use manual workflow dispatch.
# See https://github.com/orgs/community/discussions/37103.
# An alternative would be to add tokens and add those to the checkout job of the build workflow but that isn't worth the trouble right now.
on:
workflow_dispatch:
branches:
- dist
push:
branches:
- master
- dist

jobs:
doc:
runs-on: ubuntu-latest
env:
WIDOCO_DOWNLOAD_URL: https://github.com/dgarijo/Widoco/releases/download/v1.4.20/widoco-1.4.20-jar-with-dependencies_JDK-17.jar
WIDOCO_DOWNLOAD_URL: https://github.com/dgarijo/Widoco/releases/download/v1.4.23/widoco-1.4.23-jar-with-dependencies_JDK-17.jar
steps:
- uses: actions/checkout@v4
with:
ref: 'dist'

- name: Cache Widoco
uses: actions/cache@v4
with:
Expand All @@ -27,7 +35,7 @@ jobs:
wget $WIDOCO_DOWNLOAD_URL --progress=dot:giga --output-document=jar/widoco.jar
- name: Run Widoco
run: java -jar jar/widoco.jar -ontFile annodc.owl -rewriteAll -uniteSections -getOntologyMetadata -outFolder .
run: java -jar jar/widoco.jar -ontFile anno.ttl -rewriteAll -uniteSections -getOntologyMetadata -outFolder doc

- name: Rename index-en.html to index.html
run: mv doc/index-en.html doc/index.html
Expand Down
2 changes: 1 addition & 1 deletion annodc.owl
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#">

<owl:Ontology rdf:about="https://annosaxfdm.de/ontology/">
<owl:versionInfo>2024-02-15</owl:versionInfo>
<owl:versionInfo>2024-04-09</owl:versionInfo>
<dct:created rdf:datatype="http://www.w3.org/2001/XMLSchema#date">2023-08-24</dct:created>
<bibo:status rdf:resource="http://purl.org/ontology/bibo/status/published"/>
<rdfs:seeAlso rdf:resource="https://zenodo.org/record/8380382"/>
Expand Down
6 changes: 6 additions & 0 deletions scripts/doc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/bin/sh
# call scripts/combine first
SCRIPTPATH=`dirname "$0"`
BASEPATH="$SCRIPTPATH/.."
BASEPATH=`( cd "$BASEPATH" && pwd )`
widoco -ontFile $BASEPATH/dist/anno.ttl -ontFile $BASEPATH/annods.owl -rewriteAll -uniteSections -getOntologyMetadata -ignoreIndividuals -outFolder /tmp

0 comments on commit 9d06c79

Please sign in to comment.