Skip to content

Commit

Permalink
Add new GitHub CI action to test code generation
Browse files Browse the repository at this point in the history
Signed-off-by: Steffen Vogel <[email protected]>
  • Loading branch information
stv0g committed Jun 21, 2024
1 parent f13ad68 commit c4c8358
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 1 deletion.
49 changes: 49 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: Build

on:
pull_request:
push:
branches:
- main

jobs:
build:
name: Generate code

runs-on: ubuntu-latest

strategy:
matrix:
language:
- java
- javascript
- python
- modernpython
- cpp

schema:
- CGMES_2.4.15_27JAN2020

steps:
- name: Checkout repo
uses: actions/checkout@v4

- name: Setup Python
uses: actions/setup-python@v5

- name: Generate code
run: |
python -m venv venv
. venv/bin/activate
pip install .
cimgen \
--outdir=output/${{matrix.language}} \
--schemadir=cgmes_schema/${{matrix.schema}} \
--langdir=${{matrix.language}}
- name: Create artifact
uses: actions/upload-artifact@v4
with:
name: ${inputs.schema}-${{ matrix.language }}
path: output/${inputs.language}
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ dependencies = [
"beautifulsoup4 >= 4.12.2, < 5"
]

requires-python = ">=3.11"
requires-python = ">=3.10"

classifiers = [
"Development Status :: 5 - Production/Stable",
Expand Down

0 comments on commit c4c8358

Please sign in to comment.