script to order terms in provo
authorTim L <lebot@rpi.edu>
Sat, 19 Jan 2013 11:58:21 -0500
changeset 5431 038b8ff4a82f
parent 5430 199e7d1b5656
child 5432 94e2d6d571a5
script to order terms in provo
ontology/bin/publish-ordered-owl.sh
ontology/term-order.csv
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/ontology/bin/publish-ordered-owl.sh	Sat Jan 19 11:58:21 2013 -0500
@@ -0,0 +1,15 @@
+#!/bin/bash
+
+rapper -g -o turtle ProvenanceOntology.owl > prov-o.ttl
+
+# https://github.com/timrdf/prov-lodspeakr/blob/master/components/services/prov-o/cross-reference.py
+# deployed on http://aquarius.tw.rpi.edu/prov-wg/prov-o
+# depends on the ordering attributes to be mixed in to the OWL at:
+# https://dvcs.w3.org/hg/prov/file/tip/ontology/working-dir/ProvenanceOntology-ordered.owl
+rapper -qg -o turtle ProvenanceOntology.owl                             > working-dir/ProvenanceOntology-ordered.ttl
+echo "@prefix prov: <http://www.w3.org/ns/prov#> ."                    >> working-dir/ProvenanceOntology-ordered.ttl
+cat term-order.csv | awk '$1 ~ /</ {i++; print $1,"prov:order",i,"."}' >> working-dir/ProvenanceOntology-ordered.ttl
+rapper -qg -o rdfxml working-dir/ProvenanceOntology-ordered.ttl         > working-dir/ProvenanceOntology-ordered.owl
+
+hg commit ProvenanceOntology.owl prov-o.ttl working-dir/ProvenanceOntology-ordered.owl -m 'auto publish of prov-o as OWL, TTL, and OWL+order'
+hg push
--- a/ontology/term-order.csv	Sat Jan 19 11:58:02 2013 -0500
+++ b/ontology/term-order.csv	Sat Jan 19 11:58:21 2013 -0500
@@ -6,13 +6,13 @@
 # use: cat term-order.csv | awk '$1 ~ /</ {i++; print $1,"prov:order",i,"."}'
 
 <http://www.w3.org/ns/prov#Entity>
-   <http://www.w3.org/ns/prov#value>
    <http://www.w3.org/ns/prov#alternateOf>
    <http://www.w3.org/ns/prov#specializationOf>
    <http://www.w3.org/ns/prov#generatedAtTime>
    <http://www.w3.org/ns/prov#wasGeneratedBy>
    <http://www.w3.org/ns/prov#wasDerivedFrom>
    <http://www.w3.org/ns/prov#hadPrimarySource>
+   <http://www.w3.org/ns/prov#value>
    <http://www.w3.org/ns/prov#wasQuotedFrom>
    <http://www.w3.org/ns/prov#wasRevisionOf>
    <http://www.w3.org/ns/prov#invalidatedAtTime>