-
Notifications
You must be signed in to change notification settings - Fork 1
69 lines (69 loc) · 2.65 KB
/
migmose.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
name: Run MIGmose
on:
push:
branches:
- master
- migmose
paths:
- 'edi_energy_de/**/*.docx'
- 'dependencies/migmose-requirements.txt'
- '.github/workflows/migmose.yml'
jobs:
check:
name: Parse the Docx Files
runs-on: ubuntu-latest
strategy:
max-parallel: 1
matrix:
format_version: ["FV2504", "FV2410", "FV2404"]
steps:
- name: Check out Git repository
uses: actions/checkout@v4
with:
path: edi_energy_mirror
lfs: true
token: ${{ secrets.MRMIG_PUSH_TOKEN }} # this token expires on 2025-05-15
# token with repo scope
# https://github.com/Hochfrequenz/edi_energy_mirror/settings/secrets/actions/MRAHB_PUSH_TOKEN
- name: Set up Python 3.13
uses: actions/setup-python@v5
with:
python-version: "3.13"
- name: Install dependencies
working-directory: "edi_energy_mirror"
run: |
python -m pip install --upgrade pip
pip install -r dependencies/migmose-requirements.txt
- uses: actions/checkout@v4
with:
token: ${{ secrets.MRMIG_PUSH_TOKEN }}
repository: Hochfrequenz/machine-readable_message-implementation-guide
path: machine-readable_message-implementation-guide
lfs: true
- name: Run Extraction
run: |
migmose -eemp ./edi_energy_mirror -o ./machine-readable_message-implementation-guide -fv ${{ matrix.format_version }} --file-type csv --file-type nested_json --file-type reduced_nested_json
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 20
- name: Install prettier
run: npm install prettier -g
- name: prettier JSON files
run: prettier -w machine-readable_message-implementation-guide
- name: Get current time
uses: srfrnk/current-time@master
id: current-time
with:
format: YYYY-MM-DDTHH-mm-ss
- name: Push results to machine-readable_migs
uses: peter-evans/create-pull-request@v6
with:
path: machine-readable_message-implementation-guide
title: EDI@Energy MIGmose ${{ matrix.format_version }} Changes ${{ steps.current-time.outputs.formattedTime }}
token: ${{ secrets.MRMIG_PUSH_TOKEN }} # this token expires on 2025-05-15
# token with repo scope
# https://github.com/Hochfrequenz/edi_energy_mirror/settings/secrets/actions/MRMIG_PUSH_TOKEN
branch: update-${{ matrix.format_version }}-${{ steps.current-time.outputs.formattedTime }}
reviewers: hf-krechan
assignees: hf-krechan