Skip to content

Release NOS

Release NOS #78

Workflow file for this run

name: Release NOS
on:
workflow_call:
workflow_dispatch:
jobs:
release:
runs-on: macos-latest
steps:
- name: Get IG-website-release
uses: actions/checkout@main
with:
persist-credentials: false
repository: M-Priour/IG-website-release-test
path: IG-website-release
lfs: true
- name: Init
run: |
cd IG-website-release
git submodule update --init --recursive
- name: DEBUG Workaround GitHub-Actions-MacOS Issue with env.TMPDIR
run: |
echo "TMPDIR=$TMPDIR"
echo "TMPDIR using ENV.TMPDIR=${{ env.TMPDIR }}"
- uses: actions/checkout@v3
with:
path: igRepo
- name: Get Template
uses: actions/checkout@main
with:
repository: ansforge/IG-template-Nos
path: template_nos
- name: Get values from the publication-request.json
id: publicationRequest
uses: RadovanPelka/github-action-json@main
with:
path: igRepo/publication-request.json
- name: get version
id: version
uses: notiz-dev/github-action-json-property@release
with:
path: igRepo/publication-request.json
prop_path: 'version'
- run: echo ${{steps.version.outputs.prop}}
# Persist the FHIR Package Cache between runners.
# Doc: https://confluence.hl7.org/display/FHIR/FHIR+Package+Cache
- name: 🗂️ Cache FHIR Packages
uses: actions/cache@v2
with:
path: |
~/.fhir/packages
key: fhir-packages
- name: Install modules
run: npm install -g fsh-sushi
- name: Run sushi
run: sushi igRepo
# Persist the IG Publisher input-cache between runners.
# Doc: https://build.fhir.org/ig/FHIR/ig-guidance/using-templates.html#igroot-input-cache
- name: 🗂️ Cache IG Publisher input-cache
uses: actions/cache@v2
with:
path: |
igs/${{ env.IG }}/input-cache
key: ig-publisher-input-cache
- uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '17'
# Downloads the newest version of the IG Publisher, this could probable be cached.
- name: 📥 Download IG Publisher
run: wget -q https://github.com/HL7/fhir-ig-publisher/releases/latest/download/publisher.jar
- name: Build and test with Rake
run: |
sudo gem install jekyll
# Builds the HTML page for the IG.
- name: 🏃‍♂️ Run IG Publisher
run : java -Xmx10g -jar publisher.jar publisher -ig igRepo/.
- name: 🏃‍♂️ Run Publisher to release
run : java -Xmx10g -jar publisher.jar -go-publish -source igRepo -web ./IG-website-release/www/ig/ -registry ./IG-website-release/ig-registry/fhir-ig-list.json -history ./IG-website-release/fhir-ig-history-template -templates ./IG-website-release/templates
- name: Setup Python # Set Python version
uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Run script python
run: python igRepo/download.py '/var/folders/24/8k48jl6d249_n_qfxwsl6xvm0000gn/T/ans.fr.nos#${{steps.version.outputs.prop}}-milestone/temp/pages/' './template_nos/includes/template.download.html'
- name: Re-Run jekyll
run : |
cd IG-website-release
jekyll build --destination "./www/ig/nos/${{steps.version.outputs.prop}}/" --source "/var/folders/24/8k48jl6d249_n_qfxwsl6xvm0000gn/T/ans.fr.nos#${{steps.version.outputs.prop}}-milestone/temp/pages"
- name: 1 ZIP JDV PDF
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-jdv-pdf.zip igRepo/input/images/NOS/JDV_*.pdf
- name: 1 ZIP JDV SVS
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-jdv-svs.zip igRepo/input/images/NOS/JDV_*.xml -x "*FHIR*"
- name: 1 ZIP JDV FHIR JSON
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-jdv-fhir-json.zip igRepo/input/images/NOS/JDV_*-FHIR.json
- name: 1 ZIP JDV FHIR XML
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-jdv-fhir-xml.zip igRepo/input/images/NOS/JDV_*-FHIR.xml
- name: 1 ZIP JDV FHIR tabs
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-jdv-tabs.zip igRepo/input/images/NOS/JDV_*.tabs
- name: 2 ZIP TRE PDF
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-tre-pdf.zip igRepo/input/images/NOS/TRE_*.pdf
- name: 2 ZIP TRE SVS
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-tre-svs.zip igRepo/input/images/NOS/TRE*.xml -x "*FHIR*"
- name: 2 ZIP TRE FHIR JSON
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-tre-fhir-json.zip igRepo/input/images/NOS/TRE*-FHIR.json
- name: 2 ZIP TRE FHIR XML
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-tre-fhir-xml.zip igRepo/input/images/NOS/TRE*-FHIR.xml
- name: 2 ZIP TRE FHIR tabs
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-tre-tabs.zip igRepo/input/images/NOS/TRE*.tabs
- name: 3 ZIP ASS PDF
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-ass-pdf.zip igRepo/input/images/NOS/ASS_*.pdf
- name: 3 ZIP ASS SVS
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-ass-svs.zip igRepo/input/images/NOS/ASS*.xml -x "*FHIR*"
- name: 3 ZIP ASS FHIR JSON
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-ass-fhir-json.zip igRepo/input/images/NOS/ASS*-FHIR.json
- name: 3 ZIP ASS FHIR XML
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-ass-fhir-xml.zip igRepo/input/images/NOS/ASS*-FHIR.xml
- name: 3 ZIP ASS FHIR tabs
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-ass-tabs.zip igRepo/input/images/NOS/ASS*.tabs
- name: ZIP Ensemble des NOS au format CSV
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-Fichiers_Publics.zip igRepo/input/images/NOS/*.tabs
- name: ZIP Ensemble des NOS au format XML/SVS
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-Fichiers_Publics-Versions_xml_svs.zip igRepo/input/images/NOS/*.xml -x "*FHIR*"
- name: ZIP Ensemble des NOS au format JSON/FHIR (ZIP)
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-Fichiers_Publics-Versions_json_fhir.zip igRepo/input/images/NOS/*-FHIR.json
- name: ZIP Ensemble des NOS au format XML/FHIR (ZIP)
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/Nos-fichiers_publics-versions_xml_fhir.zip igRepo/input/images/NOS/*-FHIR.xml
- name: ZIP Jeux de valeurs du CI-SIS (ZIP
run : zip -rj IG-website-release/www/ig/nos/${{steps.version.outputs.prop}}/NOS/NOS-Jeux_de_Valeurs_CI-SIS.zip igRepo/input/images/NOS/*CISIS*
- name: Minify
run : |
brew install tdewolff/tap/minify
minify IG-website-release
- name: Commit change
run: |
cd IG-website-release
git config user.name github-actions
git config user.email [email protected]
git add -A
git reset *full-ig.zip*
git reset *.xml1*
git reset *.xml2*
git reset *.json1*
git reset *.json2*
git reset *.xslx*
git commit -m updated
- name: Push changes
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.API_TOKEN_GITHUB }}
directory: IG-website-release
repository : M-Priour/IG-website-release-test