From fbfdfeb44ce215bb0c93564553696d7f1c0c08d9 Mon Sep 17 00:00:00 2001 From: Dragos0000 Date: Wed, 14 Feb 2024 14:49:03 +0000 Subject: [PATCH] added eurovoc modules config --- .../workflows/transform_with_model2owl.yml | 176 +++++++++--------- .../model2owl-config/config-parameters.xsl | 2 +- .../model2owl-config/config-parameters.xsl | 2 +- .../xmi_conceptual_model/demo_ontology_CM.xml | 2 +- 4 files changed, 91 insertions(+), 91 deletions(-) diff --git a/.github/workflows/transform_with_model2owl.yml b/.github/workflows/transform_with_model2owl.yml index dba0729..dfc36a4 100644 --- a/.github/workflows/transform_with_model2owl.yml +++ b/.github/workflows/transform_with_model2owl.yml @@ -120,91 +120,91 @@ jobs: with: github_token: ${{ secrets.GITHUB_TOKEN }} branch: ${{ github.ref }} - transform: - needs: report_and_glossary - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@master - with: - ref: ${{ github.ref }} - - - name: get model2owl - run: | - git clone https://github.com/OP-TED/model2owl.git - pwd - - - name: get-saxon - run: pwd && cd model2owl && make get-saxon - - - name: get-rdflib - run: cd model2owl && make create-virtual-env && make get-rdflib - - - name: transform step - run: | - AVAILABLE_IMPLEMENTATIONS=(demo_ontology demo_ontology_module) - for implementation in "${AVAILABLE_IMPLEMENTATIONS[@]}" - do - echo "-------------------${implementation} transform---------------------------------" - sed -i "s/test\/ePO-default-config/..\/implementation\/${implementation}\/model2owl-config/g" model2owl/config-proxy.xsl - cat model2owl/config-proxy.xsl - - - CM_FILE_NAME=$(echo "${implementation}_CM.xml") - CM_FILE_PATH=$(echo "implementation/$implementation/xmi_conceptual_model/${CM_FILE_NAME}") - OUTPUT_PATH_OWL=$(echo "implementation/$implementation/owl_ontology/") - OUTPUT_PATH_SHACL=$(echo "implementation/$implementation/shacl_shapes/") - - ls -la implementation/$implementation/xmi_conceptual_model/ - echo "CM_FILE_PATH is $CM_FILE_PATH" - echo "OUTPUT_PATH_OWL is $OUTPUT_PATH_OWL" - echo "OUTPUT_PATH_SHACL is $OUTPUT_PATH_SHACL" - - - cd model2owl - ls -la - echo "+++++++++++++++++transform to rdf++++++++++++++++++++++++++++" - make owl-core XMI_INPUT_FILE_PATH=../$CM_FILE_PATH OUTPUT_FOLDER_PATH=../$OUTPUT_PATH_OWL - make owl-restrictions XMI_INPUT_FILE_PATH=../$CM_FILE_PATH OUTPUT_FOLDER_PATH=../$OUTPUT_PATH_OWL - make shacl XMI_INPUT_FILE_PATH=../$CM_FILE_PATH OUTPUT_FOLDER_PATH=../$OUTPUT_PATH_SHACL - - echo "+++++++++++++++++transform to turtle++++++++++++++++++++++++++++" - echo $(ls ../${OUTPUT_PATH_OWL}*.rdf) - make convert-rdf-to-turtle ONTOLOGY_FOLDER_PATH=../$OUTPUT_PATH_OWL - echo $(ls ../${OUTPUT_PATH_SHACL}*.rdf) - make convert-rdf-to-turtle ONTOLOGY_FOLDER_PATH=../$OUTPUT_PATH_SHACL - echo "-------------------end transform---------------------------------" - - - sed -i "s/..\/implementation\/${implementation}\/model2owl-config/test\/ePO-default-config/g" config-proxy.xsl - cd .. - done - shell: bash - - - name: remove unnecessary files - run: | - sudo rm -rf model2owl - shell: bash - - - name: commit files - id: commit - run: | - git config --local user.email "action@github.com" - git config --local user.name "github-actions" - git pull - git status - - git add . - if [ -z "$(git status --porcelain)" ]; then - echo "::set-output name=push::false" - else - git commit -m "Adding transformation files" - echo "::set-output name=push::true" - fi - shell: bash - - - name: Push changes - if: steps.commit.outputs.push == 'true' - uses: ad-m/github-push-action@master - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - branch: ${{ github.ref }} \ No newline at end of file +# transform: +# needs: report_and_glossary +# runs-on: ubuntu-latest +# steps: +# - uses: actions/checkout@master +# with: +# ref: ${{ github.ref }} +# +# - name: get model2owl +# run: | +# git clone https://github.com/OP-TED/model2owl.git +# pwd +# +# - name: get-saxon +# run: pwd && cd model2owl && make get-saxon +# +# - name: get-rdflib +# run: cd model2owl && make create-virtual-env && make get-rdflib +# +# - name: transform step +# run: | +# AVAILABLE_IMPLEMENTATIONS=(demo_ontology demo_ontology_module) +# for implementation in "${AVAILABLE_IMPLEMENTATIONS[@]}" +# do +# echo "-------------------${implementation} transform---------------------------------" +# sed -i "s/test\/ePO-default-config/..\/implementation\/${implementation}\/model2owl-config/g" model2owl/config-proxy.xsl +# cat model2owl/config-proxy.xsl +# +# +# CM_FILE_NAME=$(echo "${implementation}_CM.xml") +# CM_FILE_PATH=$(echo "implementation/$implementation/xmi_conceptual_model/${CM_FILE_NAME}") +# OUTPUT_PATH_OWL=$(echo "implementation/$implementation/owl_ontology/") +# OUTPUT_PATH_SHACL=$(echo "implementation/$implementation/shacl_shapes/") +# +# ls -la implementation/$implementation/xmi_conceptual_model/ +# echo "CM_FILE_PATH is $CM_FILE_PATH" +# echo "OUTPUT_PATH_OWL is $OUTPUT_PATH_OWL" +# echo "OUTPUT_PATH_SHACL is $OUTPUT_PATH_SHACL" +# +# +# cd model2owl +# ls -la +# echo "+++++++++++++++++transform to rdf++++++++++++++++++++++++++++" +# make owl-core XMI_INPUT_FILE_PATH=../$CM_FILE_PATH OUTPUT_FOLDER_PATH=../$OUTPUT_PATH_OWL +# make owl-restrictions XMI_INPUT_FILE_PATH=../$CM_FILE_PATH OUTPUT_FOLDER_PATH=../$OUTPUT_PATH_OWL +# make shacl XMI_INPUT_FILE_PATH=../$CM_FILE_PATH OUTPUT_FOLDER_PATH=../$OUTPUT_PATH_SHACL +# +# echo "+++++++++++++++++transform to turtle++++++++++++++++++++++++++++" +# echo $(ls ../${OUTPUT_PATH_OWL}*.rdf) +# make convert-rdf-to-turtle ONTOLOGY_FOLDER_PATH=../$OUTPUT_PATH_OWL +# echo $(ls ../${OUTPUT_PATH_SHACL}*.rdf) +# make convert-rdf-to-turtle ONTOLOGY_FOLDER_PATH=../$OUTPUT_PATH_SHACL +# echo "-------------------end transform---------------------------------" +# +# +# sed -i "s/..\/implementation\/${implementation}\/model2owl-config/test\/ePO-default-config/g" config-proxy.xsl +# cd .. +# done +# shell: bash +# +# - name: remove unnecessary files +# run: | +# sudo rm -rf model2owl +# shell: bash +# +# - name: commit files +# id: commit +# run: | +# git config --local user.email "action@github.com" +# git config --local user.name "github-actions" +# git pull +# git status +# +# git add . +# if [ -z "$(git status --porcelain)" ]; then +# echo "::set-output name=push::false" +# else +# git commit -m "Adding transformation files" +# echo "::set-output name=push::true" +# fi +# shell: bash +# +# - name: Push changes +# if: steps.commit.outputs.push == 'true' +# uses: ad-m/github-push-action@master +# with: +# github_token: ${{ secrets.GITHUB_TOKEN }} +# branch: ${{ github.ref }} \ No newline at end of file diff --git a/implementation/common_src_ap/model2owl-config/config-parameters.xsl b/implementation/common_src_ap/model2owl-config/config-parameters.xsl index 7ebabb2..0f291fa 100644 --- a/implementation/common_src_ap/model2owl-config/config-parameters.xsl +++ b/implementation/common_src_ap/model2owl-config/config-parameters.xsl @@ -143,7 +143,7 @@ - + diff --git a/implementation/currency_src_ap/model2owl-config/config-parameters.xsl b/implementation/currency_src_ap/model2owl-config/config-parameters.xsl index 95577aa..4222fac 100644 --- a/implementation/currency_src_ap/model2owl-config/config-parameters.xsl +++ b/implementation/currency_src_ap/model2owl-config/config-parameters.xsl @@ -143,7 +143,7 @@ - + diff --git a/implementation/demo_ontology/xmi_conceptual_model/demo_ontology_CM.xml b/implementation/demo_ontology/xmi_conceptual_model/demo_ontology_CM.xml index 55013ac..7bde0cf 100644 --- a/implementation/demo_ontology/xmi_conceptual_model/demo_ontology_CM.xml +++ b/implementation/demo_ontology/xmi_conceptual_model/demo_ontology_CM.xml @@ -1,6 +1,6 @@ - +