generated from ansforge/IG-modele
-
Notifications
You must be signed in to change notification settings - Fork 0
236 lines (171 loc) · 10.5 KB
/
release-inside.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
# publish on ig
name: Release new package
on:
workflow_call:
workflow_dispatch:
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Get IG-website-release
uses: actions/checkout@main
with:
persist-credentials: false
repository: ansforge/IG-website-release
path: IG-website-release
- name: Init
run: |
cd IG-website-release
git submodule update --init --recursive
- uses: actions/checkout@v3
with:
path: igRepo
- name: Get From site esante
run: |
#Creation des répertoires d'init
#mkdir ./igRepo/input/images/NOS/
mkdir ./igRepo/input/NOS
#Recuperation des NOS en json
wget -q https://esante.gouv.fr/sites/default/files/media_entity/documents/NOS-Fichiers_Publics-Versions_json_fhir.zip
unzip NOS-Fichiers_Publics-Versions_json_fhir.zip -d ./igRepo/input/NOS
#Suppression des fichiers en erreur
rm ./igRepo/input/NOS/TRE_R13-Commune-FHIR.json
rm ./igRepo/input/NOS/ASS_X12-CommuneDeptRegionOM-FHIR.json
rm ./igRepo/input/NOS/JDV_J120-CommuneHistorisee-FHIR.json
rm ./igRepo/input/NOS/JDV_J124-Commune-FHIR.json
#rm ./input/NOS/ASS_A11-CorresModeleCDA-XdsFormatCode-CISIS-FHIR.json
#rm ./input/NOS/ASS_X16-CorrespondanceType-Classe-DMP-FHIR.json
rm ./igRepo/input/NOS/JDV_J151-BodySiteBodyTemperature-ENS-FHIR.json
rm ./igRepo/input/NOS/ASS_*
# Install .NET runtime
- name: Setup .NET Core SDK
uses: actions/setup-dotnet@v2
with:
dotnet-version: '6.x.x'
# Install Java runtime (only needed if you want to run the offical HL7 Java validator)
- name: Setup Java JDK
uses: actions/setup-java@v3
with:
distribution: 'microsoft'
java-version: '17'
- name : firely
run : dotnet tool install --global Firely.Terminal --version 3.0.0
- name: Check Firely Terminal Version
run: |
CHECK_FIRELY_TERMINAL_VERSION=$(fhir -v | tr '\n' ' ') # Print everything in a single line
echo "FIRELY_TERMINAL_VERSION: $CHECK_FIRELY_TERMINAL_VERSION"
- name: Run bake hl7.fhir.fr.core
run: |
fhir install hl7.fhir.fr.core 1.1.0
fhir bake --package hl7.fhir.fr.core
# 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 Sushi
run: npm install -g fsh-sushi
- name: Install ruby and jekyll
run: |
sudo apt-get install ruby-full
sudo gem install jekyll
# 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: Run sushi
run: sushi igRepo
- name: 🏃♂️ Run IG Publisher
run : java -Xmx8192m -jar publisher.jar publisher -ig igRepo/.
- name: Get From site esante
run: |
#Recuperation des fichier .json
wget -q https://esante.gouv.fr/sites/default/files/media_entity/documents/NOS-Fichiers_Publics-Versions_json_fhir.zip
cp NOS-Fichiers_Publics-Versions_json_fhir.zip ./IG-website-release/www/ig/nos/NOS
unzip NOS-Fichiers_Publics-Versions_json_fhir.zip -d ./IG-website-release/www/ig/nos/NOS
#Recucperation des fichiers .tabs
wget -q https://esante.gouv.fr/sites/default/files/media_entity/documents/NOS-Fichiers_Publics.zip
cp NOS-Fichiers_Publics.zip ./IG-website-release/www/ig/nos/NOS/
unzip NOS-Fichiers_Publics.zip -d ./IG-website-release/www/ig/nos/NOS
#Recupération des fichiers SVS
wget -q https://esante.gouv.fr/sites/default/files/media_entity/documents/NOS-Fichiers_Publics-Versions_xml_svs.zip
cp NOS-Fichiers_Publics-Versions_xml_svs.zip ./IG-website-release/www/ig/nos/NOS
unzip NOS-Fichiers_Publics-Versions_xml_svs.zip -d ./IG-website-release/www/ig/nos/NOS
#Recupération des fichiers xml Fhir
wget -q https://esante.gouv.fr/sites/default/files/media_entity/documents/nos-fichiers_publics-versions_xml_fhir.zip
cp nos-fichiers_publics-versions_xml_fhir.zip ./IG-website-release/www/ig/nos/NOS
unzip nos-fichiers_publics-versions_xml_fhir.zip -d ./IG-website-release/www/ig/nos/NOS
#Recuperation des fichiers PDF
wget -q https://esante.gouv.fr/sites/default/files/media_entity/documents/NOS-Fichiers_Publics_JDV-Versions_pdf.zip
cp NOS-Fichiers_Publics_JDV-Versions_pdf.zip ./IG-website-release/www/ig/nos/NOS
unzip NOS-Fichiers_Publics_JDV-Versions_pdf.zip -d ./IG-website-release/www/ig/nos/NOS
wget -q https://esante.gouv.fr/sites/default/files/media_entity/documents/NOS-Fichiers_Publics_TRE_ASS-Versions_pdf.zip
cp NOS-Fichiers_Publics_TRE_ASS-Versions_pdf.zip ./IG-website-release/www/ig/nos/NOS
unzip NOS-Fichiers_Publics_TRE_ASS-Versions_pdf.zip -d ./IG-website-release/www/ig/nos/NOS
- name: Install rename
run : sudo apt install rename
- name: Rename TRE
run : rename -v 's/TRE_/CodeSystem-TRE-/' ./IG-website-release/www/ig/nos/NOS/*
- name: Rename JDV
run : rename -v 's/JDV_/ValueSet-JDV-/' ./IG-website-release/www/ig/nos/NOS/*
- name: 1 ZIP JDV PDF
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-jdv-pdf.zip ./IG-website-release/www/ig/nos/NOS/*JDV-*.pdf
- name: 1 ZIP JDV SVS
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-jdv-svs.zip ./IG-website-release/www/ig/nos/NOS/*JDV-*.xml -x "*FHIR*"
- name: 1 ZIP JDV FHIR JSON
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-jdv-fhir-json.zip ./IG-website-release/www/ig/nos/NOS/*JDV-*-FHIR.json
- name: 1 ZIP JDV FHIR XML
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-jdv-fhir-xml.zip ./IG-website-release/www/ig/nos/NOS/*JDV-*-FHIR.xml
- name: 1 ZIP JDV FHIR tabs
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-jdv-tabs.zip ./IG-website-release/www/ig/nos/NOS/*JDV-*.tabs
- name: 2 ZIP TRE PDF
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-tre-pdf.zip ./IG-website-release/www/ig/nos/NOS/*TRE-*.pdf
- name: 2 ZIP TRE SVS
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-tre-svs.zip ./IG-website-release/www/ig/nos/NOS/*TRE*.xml -x "*FHIR*"
- name: 2 ZIP TRE FHIR JSON
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-tre-fhir-json.zip ./IG-website-release/www/ig/nos/NOS/*TRE*-FHIR.json
- name: 2 ZIP TRE FHIR XML
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-tre-fhir-xml.zip ./IG-website-release/www/ig/nos/NOS/*TRE*-FHIR.xml
- name: 2 ZIP TRE FHIR tabs
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-tre-tabs.zip ./IG-website-release/www/ig/nos/NOS/*TRE*.tabs
- name: 3 ZIP ASS PDF
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-ass-pdf.zip ./IG-website-release/www/ig/nos/NOS/ASS_*.pdf
- name: 3 ZIP ASS SVS
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-ass-svs.zip ./IG-website-release/www/ig/nos/NOS/ASS*.xml -x "*FHIR*"
- name: 3 ZIP ASS FHIR JSON
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-ass-fhir-json.zip ./IG-website-release/www/ig/nos/NOS/ASS*-FHIR.json
- name: 3 ZIP ASS FHIR XML
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-ass-fhir-xml.zip ./IG-website-release/www/ig/nos/NOS/ASS*-FHIR.xml
- name: 3 ZIP ASS FHIR tabs
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-ass-tabs.zip ./IG-website-release/www/ig/nos/NOS/ASS*.tabs
- name: ZIP Ensemble des NOS au format CSV
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-Fichiers_Publics.zip ./IG-website-release/www/ig/nos/NOS/*.tabs
- name: ZIP Ensemble des NOS au format XML/SVS
run : zip -rj ./IG-website-release/www/ig/nos/NOS-Fichiers_Publics-Versions_xml_svs.zip ./IG-website-release/www/ig/nos/NOS/*.xml -x "*FHIR*"
- name: ZIP Ensemble des NOS au format JSON/FHIR (ZIP)
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-Fichiers_Publics-Versions_json_fhir.zip ./IG-website-release/www/ig/nos/NOS/*-FHIR.json
#- name: ZIP Ensemble des NOS au format XML/FHIR (ZIP)
# run : zip -rj ./IG-website-release/www/ig/nos/NOS/Nos-fichiers_publics-versions_xml_fhir.zip ./IG-website-release/www/ig/nos/NOS/*-FHIR.xml
- name: ZIP Jeux de valeurs du CI-SIS (ZIP
run : zip -rj ./IG-website-release/www/ig/nos/NOS/NOS-Jeux_de_Valeurs_CI-SIS.zip ./IG-website-release/www/ig/nos/NOS/*CISIS*
# Builds the HTML page for the IG.
- name: 🏃♂️ Generate package registry
run : java -Dfile.encoding=UTF-8 -jar publisher.jar -generate-package-registry ./IG-website-release
- name: 🏃♂️ Run Publisher to release
run : java -Dfile.encoding=UTF-8 -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: Commit change on IG-website-release
run: |
cd IG-website-release
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git add -A
git commit -m updated
- name: Push changes on IG-website-release
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.ANS_IG_API_TOKEN }}
directory: IG-website-release
repository : ansforge/IG-website-release
force : true