-
Notifications
You must be signed in to change notification settings - Fork 0
51 lines (44 loc) · 1.62 KB
/
scenepro-entities.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
name: Export Scenepro entities to Artsdata
on:
workflow_dispatch:
jobs:
transform-scenepro-entities:
runs-on: ubuntu-latest
container:
image: ontotext/refine:1.2.0
options: --user root
ports:
- 7333:7333
steps:
- name: Install requirements
id: step-1
run: apk update && apk add curl && apk add util-linux && apk add coreutils
- name: Run Onto Refine server
id: step-2
run: /opt/ontorefine/dist/bin/ontorefine &
- name: Download scenepro entities
id: step-3
run: |
curl 'https://public-api.scenepro.ca/capacoa/organizations/diffuser/0/200?networkId=2' \
-H "Ocp-Apim-Subscription-Key: 44c4455927594abfb8127ec918b93c73;product=capacoa" >> entities.json
- name: Download mapping file
id: step-4
run: |
curl 'https://raw.githubusercontent.com/culturecreates/artsdata-planet-scenepro/main/ontorefine/mapping.json' >> mapping.json
- name: Transform entities in JSON to RDF
id: step-5
run: |
/opt/ontorefine/dist/bin/ontorefine-cli \
transform entities.json \
-u http://localhost:7333 \
--configurations config.json \
-f json >> scenepro-entities.ttl
- name: Commit changes to GitHub
id: step-6
run: |
git pull
git config --global user.email "[email protected]"
git config --global user.name "GitHub Actions"
git add scenepro-entities.ttl
git commit -m "Add ScenePro entities TTL file"
git push