Skip to content

Commit 020a928

Browse files
committed
chore: update actions
1 parent a2339c5 commit 020a928

File tree

4 files changed

+108
-108
lines changed

4 files changed

+108
-108
lines changed

.github/workflows/biosimulators_dispatch.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,11 @@ jobs:
99
runs-on: ubuntu-latest
1010

1111
steps:
12-
- name: Get tag
13-
id: tag
14-
run: echo "::set-output name=version::${GITHUB_REF#refs/tags/}"
1512
- name: Dispatch new release version to BioSimulators
1613
uses: benc-uk/workflow-dispatch@v1
1714
with:
1815
workflow: Continuous integration
1916
repo: biosimulators/Biosimulators_COBRApy
2017
ref: dev
2118
token: ${{ secrets.BIOSIM_DISPATCH_TOKEN }}
22-
inputs: '{ "simulatorVersion": "${{ steps.tag.outputs.version }}", "simulatorVersionLatest": "true" }'
19+
inputs: '{ "simulatorVersion": "${{ github.ref_name }}", "simulatorVersionLatest": "true" }'

.github/workflows/lint.yml

Lines changed: 27 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@ name: Lint
33
on:
44
push:
55
branches:
6-
- stable
7-
- devel
6+
- stable
7+
- devel
88
tags:
9-
- '[0-9]+.[0-9]+.[0-9]+'
10-
- '[0-9]+.[0-9]+.[0-9]+a[0-9]+'
9+
- "[0-9]+.[0-9]+.[0-9]+"
10+
- "[0-9]+.[0-9]+.[0-9]+a[0-9]+"
1111
pull_request:
1212
branches:
13-
- stable
14-
- devel
13+
- stable
14+
- devel
1515

1616
jobs:
1717
lint:
@@ -20,25 +20,27 @@ jobs:
2020
fail-fast: false
2121
matrix:
2222
os: [ubuntu-latest]
23-
python-version: ['3.10']
23+
python-version: ["3.11"]
2424
timeout-minutes: 60
2525

2626
steps:
27-
- uses: actions/checkout@v2
28-
- name: Set up Python ${{ matrix.python-version }}
29-
uses: actions/setup-python@v2
30-
with:
31-
python-version: ${{ matrix.python-version }}
32-
- name: Install dependencies
33-
run: |
34-
python -m pip install --upgrade pip setuptools wheel
35-
python -m pip install tox tox-gh-actions
36-
- name: isort
37-
run:
38-
tox -e isort
39-
- name: black
40-
run:
41-
tox -e black
42-
- name: flake8
43-
run:
44-
tox -e flake8
27+
- uses: actions/checkout@v4
28+
29+
- name: Set up Python ${{ matrix.python-version }}
30+
uses: actions/setup-python@v4
31+
with:
32+
python-version: ${{ matrix.python-version }}
33+
34+
- name: Install dependencies
35+
run: |
36+
python -m pip install --upgrade pip setuptools wheel
37+
python -m pip install tox tox-gh-actions
38+
39+
- name: isort
40+
run: tox -e isort
41+
42+
- name: black
43+
run: tox -e black
44+
45+
- name: flake8
46+
run: tox -e flake8

.github/workflows/main.yml

Lines changed: 61 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@ name: CI-CD
33
on:
44
push:
55
branches:
6-
- stable
7-
- devel
6+
- stable
7+
- devel
88
tags:
9-
- '[0-9]+.[0-9]+.[0-9]+'
10-
- '[0-9]+.[0-9]+.[0-9]+a[0-9]+'
9+
- "[0-9]+.[0-9]+.[0-9]+"
10+
- "[0-9]+.[0-9]+.[0-9]+a[0-9]+"
1111
pull_request:
1212
branches:
13-
- stable
14-
- devel
13+
- stable
14+
- devel
1515

1616
jobs:
1717
test:
@@ -20,71 +20,70 @@ jobs:
2020
fail-fast: false
2121
matrix:
2222
os: [ubuntu-latest, macos-latest, windows-latest]
23-
python-version: ['3.8', '3.9', '3.10', '3.11']
23+
python-version: ["3.8", "3.11"]
2424
timeout-minutes: 360
2525

2626
steps:
27-
- uses: actions/checkout@v2
28-
- name: Set up Python ${{ matrix.python-version }}
29-
uses: actions/setup-python@v2
30-
with:
31-
python-version: ${{ matrix.python-version }}
32-
- name: Install dependencies
33-
run: |
34-
python -m pip install --upgrade pip setuptools wheel
35-
python -m pip install tox tox-gh-actions
36-
- name: Test with tox
37-
run:
38-
tox -- --benchmark-skip
39-
timeout-minutes: 60
40-
- name: Report coverage
41-
shell: bash
42-
run: bash <(curl -s https://codecov.io/bash)
27+
- uses: actions/checkout@v4
28+
- name: Set up Python ${{ matrix.python-version }}
29+
uses: actions/setup-python@v4
30+
with:
31+
python-version: ${{ matrix.python-version }}
32+
- name: Install dependencies
33+
run: |
34+
python -m pip install --upgrade pip setuptools wheel
35+
python -m pip install tox tox-gh-actions
36+
- name: Test with tox
37+
run: tox -- --benchmark-skip
38+
timeout-minutes: 60
39+
- name: Report coverage
40+
shell: bash
41+
run: bash <(curl -s https://codecov.io/bash)
4342

4443
release:
4544
needs: test
46-
if: startsWith(github.ref, 'refs/tags')
45+
if: github.ref_type == 'tag'
4746
runs-on: ${{ matrix.os }}
4847
strategy:
4948
matrix:
5049
os: [ubuntu-latest]
51-
python-version: [3.8]
50+
python-version: ["3.11"]
51+
permissions:
52+
contents: write
5253

5354
steps:
54-
- uses: actions/checkout@v2
55-
- name: Set up Python ${{ matrix.python-version }}
56-
uses: actions/setup-python@v2
57-
with:
58-
python-version: ${{ matrix.python-version }}
59-
- name: Get tag
60-
id: tag
61-
run: echo "::set-output name=version::${GITHUB_REF#refs/tags/}"
62-
- name: Install dependencies
63-
run: |
64-
python -m pip install --upgrade pip setuptools wheel
65-
python -m pip install build twine
66-
- name: Build package
67-
run: python -m build
68-
- name: Publish to PyPI
69-
env:
70-
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
71-
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
72-
run:
73-
twine upload --skip-existing --non-interactive dist/*
74-
- name: Create GitHub release
75-
uses: actions/create-release@v1
76-
env:
77-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
78-
with:
79-
tag_name: ${{ github.ref }}
80-
release_name: ${{ github.ref }}
81-
body_path: "release-notes/${{ steps.tag.outputs.version }}.md"
82-
draft: false
83-
prerelease: false
84-
- name: Publish to website
85-
run: ./scripts/deploy_website.sh
86-
shell: bash
87-
env:
88-
TAG: ${{ steps.tag.outputs.version }}
89-
WORKSPACE: ${{ github.workspace }}
90-
WEBSITE_DEPLOY_TOKEN: ${{ secrets.WEBSITE_DEPLOY_TOKEN }}
55+
- uses: actions/checkout@v4
56+
57+
- name: Set up Python ${{ matrix.python-version }}
58+
uses: actions/setup-python@v4
59+
with:
60+
python-version: ${{ matrix.python-version }}
61+
62+
- name: Install dependencies
63+
run: |
64+
python -m pip install --upgrade pip setuptools wheel
65+
python -m pip install build twine
66+
67+
- name: Build package
68+
run: python -m build
69+
70+
- name: Publish to PyPI
71+
env:
72+
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
73+
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
74+
run: twine upload --skip-existing --non-interactive dist/*
75+
76+
- name: GH release
77+
uses: softprops/action-gh-release@v1
78+
with:
79+
body_path: "release-notes/${{ github.ref_name }}.md"
80+
draft: false
81+
prerelease: false
82+
83+
- name: Publish to website
84+
run: ./scripts/deploy_website.sh
85+
shell: bash
86+
env:
87+
TAG: ${{ github.ref_name }}
88+
WORKSPACE: ${{ github.workspace }}
89+
WEBSITE_DEPLOY_TOKEN: ${{ secrets.WEBSITE_DEPLOY_TOKEN }}

.github/workflows/safety.yml

Lines changed: 19 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@ name: Safety
33
on:
44
push:
55
branches:
6-
- stable
7-
- devel
6+
- stable
7+
- devel
88
tags:
9-
- '[0-9]+.[0-9]+.[0-9]+'
10-
- '[0-9]+.[0-9]+.[0-9]+a[0-9]+'
9+
- "[0-9]+.[0-9]+.[0-9]+"
10+
- "[0-9]+.[0-9]+.[0-9]+a[0-9]+"
1111

1212
jobs:
1313
safety:
@@ -16,19 +16,21 @@ jobs:
1616
fail-fast: false
1717
matrix:
1818
os: [ubuntu-latest, macos-latest, windows-latest]
19-
python-version: ['3.8', '3.9', '3.10', '3.11']
19+
python-version: ["3.8", "3.9", "3.10", "3.11"]
2020
timeout-minutes: 120
2121

2222
steps:
23-
- uses: actions/checkout@v2
24-
- name: Set up Python ${{ matrix.python-version }}
25-
uses: actions/setup-python@v2
26-
with:
27-
python-version: ${{ matrix.python-version }}
28-
- name: Install dependencies
29-
run: |
30-
python -m pip install --upgrade pip setuptools wheel
31-
python -m pip install tox tox-gh-actions
32-
- name: safety
33-
run:
34-
tox -e safety
23+
- uses: actions/checkout@v4
24+
25+
- name: Set up Python ${{ matrix.python-version }}
26+
uses: actions/setup-python@v4
27+
with:
28+
python-version: ${{ matrix.python-version }}
29+
30+
- name: Install dependencies
31+
run: |
32+
python -m pip install --upgrade pip setuptools wheel
33+
python -m pip install tox tox-gh-actions
34+
35+
- name: safety
36+
run: tox -e safety

0 commit comments

Comments
 (0)