Skip to content

Commit

Permalink
Merge pull request INCATools#830 from INCATools/fix-placeholder-impor…
Browse files Browse the repository at this point in the history
…t-modules

Fix placeholder import modules
  • Loading branch information
gouttegd authored Mar 20, 2023
2 parents a36ec2c + 91c7cda commit 94ea343
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 28 deletions.
48 changes: 22 additions & 26 deletions template/_dynamic_files.jinja2
Original file line number Diff line number Diff line change
Expand Up @@ -195,20 +195,18 @@ imports/%_import.owl: mirror/%.owl
#}
^^^ src/ontology/imports/merged_import.owl
<?xml version="1.0"?>
<rdf:RDF
xml:base="{{ project.uribase }}/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:owl="http://www.w3.org/2002/07/owl#"
xmlns:oboInOwl="http://www.geneontology.org/formats/oboInOwl#"
xmlns:xml="http://www.w3.org/XML/1998/namespace"
xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
xmlns:obo="http://purl.obolibrary.org/obo/">
<owl:Ontology rdf:about="{{ project.uribase }}/{% if project.uribase_suffix is not none %}{{ project.uribase_suffix }}{% else %}{{ project.id }}{% endif %}/imports/merged_import.owl"/>
Prefix(:=<{{ project.uribase }}/{% if project.uribase_suffix is not none %}{{ project.uribase_suffix }}{% else %}{{ project.id }}{% endif %}/imports/merged_import.owl>)
Prefix(obo:=<http://purl.obolibrary.org/obo/>)
Prefix(owl:=<http://www.w3.org/2002/07/owl#>)
Prefix(rdf:=<http://www.w3.org/1999/02/22-rdf-syntax-ns#>)
Prefix(xml:=<http://www.w3.org/XML/1998/namespace>)
Prefix(xsd:=<http://www.w3.org/2001/XMLSchema#>)
Prefix(rdfs:=<http://www.w3.org/2000/01/rdf-schema#>)
Prefix(oboInOwl:=<http://www.geneontology.org/formats/oboInOwl#>)

<!-- This is a placeholder, it will be regenerated when makefile is first executed -->
</rdf:RDF>
Ontology(<{{ project.uribase }}/{% if project.uribase_suffix is not none %}{{ project.uribase_suffix }}{% else %}{{ project.id }}{% endif %}/imports/merged_import.owl>
# This is a placeholder, it will be regenerated when makefile is first executed.
)
{% else %}
{#-
Expand All @@ -217,20 +215,18 @@ imports/%_import.owl: mirror/%.owl
#}
{% for imp in project.import_group.products %}
^^^ src/ontology/imports/{{ imp.id }}_import.owl
<?xml version="1.0"?>
<rdf:RDF
xml:base="{{ project.uribase }}/"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:owl="http://www.w3.org/2002/07/owl#"
xmlns:oboInOwl="http://www.geneontology.org/formats/oboInOwl#"
xmlns:xml="http://www.w3.org/XML/1998/namespace"
xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
xmlns:obo="http://purl.obolibrary.org/obo/">
<owl:Ontology rdf:about="{{ project.uribase }}/{% if project.uribase_suffix is not none %}{{ project.uribase_suffix }}{% else %}{{ project.id }}{% endif %}/imports/{{ imp.id }}_import.owl"/>
Prefix(:=<{{ project.uribase }}/{% if project.uribase_suffix is not none %}{{ project.uribase_suffix }}{% else %}{{ project.id }}{% endif %}/imports/{{ imp.id }}_import.owl>)
Prefix(obo:=<http://purl.obolibrary.org/obo/>)
Prefix(owl:=<http://www.w3.org/2002/07/owl#>)
Prefix(rdf:=<http://www.w3.org/1999/02/22-rdf-syntax-ns#>)
Prefix(xml:=<http://www.w3.org/XML/1998/namespace>)
Prefix(xsd:=<http://www.w3.org/2001/XMLSchema#>)
Prefix(rdfs:=<http://www.w3.org/2000/01/rdf-schema#>)
Prefix(oboInOwl:=<http://www.geneontology.org/formats/oboInOwl#>)

<!-- This is a placeholder, it will be regenerated when makefile is first executed -->
</rdf:RDF>
Ontology(<{{ project.uribase }}/{% if project.uribase_suffix is not none %}{{ project.uribase_suffix }}{% else %}{{ project.id }}{% endif %}/imports/{{ imp.id }}_import.owl>
# This is a placeholder, it will be regenerated when makefile is first executed.
)
{% endfor %}
{% endif %}
{#-
Expand Down
2 changes: 0 additions & 2 deletions template/src/ontology/catalog-v001.xml.jinja2
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,9 @@
{% if project.import_group is defined %}
{% if project.import_group.use_base_merging %}
<uri name="{{project.uribase}}/{% if project.uribase_suffix is not none %}{{ project.uribase_suffix }}{% else %}{{ project.id }}{% endif %}/imports/merged_import.owl" uri="imports/merged_import.owl"/>
<uri name="{{project.uribase}}/{% if project.uribase_suffix is not none %}{{ project.uribase_suffix }}{% else %}{{ project.id }}{% endif %}/imports/merged_import.obo" uri="imports/merged_import.obo"/>
{% else %}
{% for imp in project.import_group.products %}
<uri name="{{project.uribase}}/{% if project.uribase_suffix is not none %}{{ project.uribase_suffix }}{% else %}{{ project.id }}{% endif %}/imports/{{imp.id}}_import.owl" uri="imports/{{imp.id}}_import.owl"/>
<uri name="{{project.uribase}}/{% if project.uribase_suffix is not none %}{{ project.uribase_suffix }}{% else %}{{ project.id }}{% endif %}/imports/{{imp.id}}_import.obo" uri="imports/{{imp.id}}_import.obo"/>
{% endfor %}
{% endif %}
{% endif %}
Expand Down

0 comments on commit 94ea343

Please sign in to comment.