Skip to content

Commit bbfde96

Browse files
committed
Update GitHub workflows
1 parent e4a8cb2 commit bbfde96

File tree

7 files changed

+84
-101
lines changed

7 files changed

+84
-101
lines changed
Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Jobs executed on push to 'main' branch
1+
name: Deployment of documentation
22

33
on:
44
push:
@@ -9,20 +9,16 @@ on:
99
- main
1010

1111
jobs:
12-
test-workflow:
13-
uses: ./.github/workflows/sub.test.yml
14-
1512
doc:
1613
name: Build documentation
1714

18-
needs:
19-
- test-workflow
20-
2115
runs-on: ubuntu-latest
2216

2317
steps:
2418
- name: Checkout code
2519
uses: actions/checkout@v6
20+
with:
21+
submodules: recursive
2622

2723
- name: Set up Python
2824
uses: actions/setup-python@v6
@@ -33,6 +29,7 @@ jobs:
3329
run: |
3430
python -m pip install --upgrade pip
3531
python -m pip install sphinx sphinx-rtd-theme myst-parser
32+
python -m pip install softfloatpy
3633
3734
- name: Build Sphinx documentation
3835
run: |
@@ -43,6 +40,7 @@ jobs:
4340
uses: actions/upload-pages-artifact@v3
4441
with:
4542
path: ./python/docs/build/html
43+
retention-days: 1
4644

4745
doc-deploy:
4846
name: Deploy documentation

.github/workflows/[email protected]

Lines changed: 0 additions & 13 deletions
This file was deleted.

.github/workflows/release.yml

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Jobs executed on release
1+
name: Release of packages
22

33
on:
44
release:
@@ -14,6 +14,8 @@ jobs:
1414
steps:
1515
- name: Checkout code
1616
uses: actions/checkout@v6
17+
with:
18+
submodules: recursive
1719

1820
- name: Set up Python
1921
uses: actions/setup-python@v6
@@ -29,11 +31,12 @@ jobs:
2931
run: |
3032
python -m build
3133
32-
- name: Store distribution
34+
- name: Store built wheel
3335
uses: actions/upload-artifact@v6
3436
with:
3537
name: python-package-distributions
36-
path: dist/
38+
path: dist/simuhw-*.whl
39+
retention-days: 1
3740

3841
pypi:
3942
name: Publish distribution
@@ -56,9 +59,12 @@ jobs:
5659
with:
5760
name: python-package-distributions
5861
path: dist/
62+
merge-multiple: true
5963

6064
- name: Publish distribution to PyPI
6165
uses: pypa/gh-action-pypi-publish@release/v1
66+
with:
67+
verbose: true
6268

6369
github-release:
6470
needs:
@@ -76,11 +82,12 @@ jobs:
7682
with:
7783
name: python-package-distributions
7884
path: dist/
85+
merge-multiple: true
7986

8087
- name: Sign distribution with Sigstore
8188
uses: sigstore/[email protected]
8289
with:
83-
inputs: ./dist/*.tar.gz ./dist/*.whl
90+
inputs: ./dist/*.whl
8491

8592
- name: Upload artifact signatures to GitHub Release
8693
env:

.github/workflows/sub.test.yml

Lines changed: 0 additions & 74 deletions
This file was deleted.

.github/workflows/test.yml

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
name: Tests of codes
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- develop
8+
pull_request:
9+
branches:
10+
- main
11+
- develop
12+
13+
jobs:
14+
test:
15+
name: Test
16+
17+
strategy:
18+
matrix:
19+
os:
20+
- ubuntu-24.04
21+
- ubuntu-24.04-arm
22+
- macos-15
23+
- macos-15-intel
24+
- windows-2025
25+
python-version:
26+
- '3.11'
27+
- '3.12'
28+
- '3.13'
29+
30+
runs-on: ${{ matrix.os }}
31+
32+
steps:
33+
- name: Checkout code
34+
uses: actions/checkout@v6
35+
with:
36+
submodules: recursive
37+
38+
- name: Set up Python
39+
uses: actions/setup-python@v6
40+
with:
41+
python-version: ${{ matrix.python-version }}
42+
43+
- name: Install dependencies
44+
run: |
45+
python -m pip install --upgrade pip
46+
python -m pip install flake8 mypy pytest
47+
python -m pip install softfloatpy
48+
49+
- name: Check coding style with flake8
50+
run: |
51+
python -m flake8 --doctests ./python
52+
53+
- name: Check data types with mypy
54+
run: |
55+
python -m mypy --strict ./python
56+
57+
- name: Test code with pytest
58+
run: |
59+
python -m pytest ./python --doctest-modules

.github/workflows/testpypi.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Jobs executed manually for uploading to TestPyPI
1+
name: Upload of packages to TestPyPI
22

33
on:
44
workflow_dispatch:
@@ -14,6 +14,8 @@ jobs:
1414
steps:
1515
- name: Checkout code
1616
uses: actions/checkout@v6
17+
with:
18+
submodules: recursive
1719

1820
- name: Set up Python
1921
uses: actions/setup-python@v6
@@ -29,11 +31,12 @@ jobs:
2931
run: |
3032
python -m build
3133
32-
- name: Store distribution
34+
- name: Store built wheel
3335
uses: actions/upload-artifact@v6
3436
with:
3537
name: python-package-distributions
36-
path: dist/
38+
path: dist/simuhw-*.whl
39+
retention-days: 1
3740

3841
testpypi:
3942
name: Publish test distribution
@@ -56,8 +59,10 @@ jobs:
5659
with:
5760
name: python-package-distributions
5861
path: dist/
62+
merge-multiple: true
5963

6064
- name: Publish distribution to TestPyPI
6165
uses: pypa/gh-action-pypi-publish@release/v1
6266
with:
6367
repository-url: https://test.pypi.org/legacy/
68+
verbose: true

cspell.config.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ words:
3737
- sigstore
3838
- Simu
3939
- simuhw
40+
- softfloatpy
4041
- SOURCEDIR
4142
- SPHINXBUILD
4243
- SPHINXOPTS

0 commit comments

Comments
 (0)