Skip to content

Commit f1286d5

Browse files
CI: Add HTML build and automated merge action
1 parent e4b9ca3 commit f1286d5

File tree

1 file changed

+37
-8
lines changed

1 file changed

+37
-8
lines changed

.github/workflows/main.yml

+37-8
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,5 @@
11
name: pyGIMLi CI
22

3-
env:
4-
# Current bug in openblas core detection: https://stackoverflow.com/a/66057286
5-
OPENBLAS_CORETYPE: ARMV8
6-
GIMLI_NUM_THREADS: 4
7-
OMP_THREAD_LIMIT: 4
8-
93
on:
104
push:
115
branches:
@@ -16,6 +10,7 @@ on:
1610

1711
jobs:
1812
pgcore:
13+
name: Building pgcore & bindings
1914
runs-on: self-hosted
2015
steps:
2116
- uses: actions/checkout@v4
@@ -34,9 +29,43 @@ jobs:
3429
run: make pygimli J=4
3530
working-directory: build
3631
pgtest:
32+
name: Running tests
3733
runs-on: self-hosted
3834
needs: pgcore
35+
env:
36+
OPENBLAS_CORETYPE: "ARMV8" # current bug in OpenBlas core detection
3937
steps:
40-
- name: Run Python tests
41-
run: OPENBLAS_CORETYPE="ARMV8" python3 -c "import pygimli; pygimli.test(show=False, onlydoctests=True)"
38+
- name: Run pg.test()
39+
run: python3 -c "import pygimli; pygimli.test(show=False)"
40+
working-directory: source
41+
- name: Install as development package
4242
working-directory: source
43+
run: pip install -e .
44+
docs:
45+
name: Build website with examples
46+
needs: pgtest
47+
runs-on: self-hosted
48+
env:
49+
DISPLAY: ":99.0"
50+
PYVISTA_OFF_SCREEN: True
51+
steps:
52+
- name: Set up headless display
53+
uses: pyvista/setup-headless-display-action@v2
54+
- name: Running sphinx
55+
working-directory: build
56+
run: make doc
57+
merging:
58+
name: Merging dev into master
59+
runs-on: self-hosted
60+
needs: docs
61+
if: github.ref == 'refs/heads/dev' # Only merge from dev
62+
steps:
63+
- name: Merge into master
64+
uses: devmasx/merge-branch@master
65+
with:
66+
type: now
67+
target_branch: master
68+
github_token: ${{ secrets.GITHUB_TOKEN }}
69+
70+
71+

0 commit comments

Comments
 (0)