add grouped dependency updates #267
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: cookiecutter-pypackage | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
concurrency: | |
# For a given workflow, if we push to the same branch, cancel all previous builds on that branch except on main. | |
group: "${{ github.workflow }}-${{ github.ref }}" | |
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} | |
jobs: | |
tests: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
include: | |
- tox-env: py38 | |
python-version: "3.8" | |
posargs: "-m 'not precommit'" | |
- tox-env: py39 | |
python-version: "3.9" | |
- tox-env: py310 | |
python-version: "3.10" | |
- tox-env: py311 | |
python-version: "3.11" | |
- tox-env: py312 | |
python-version: "3.12" | |
- tox-env: pypy39 | |
python-version: "pypy3.9" | |
- tox-env: pypy310 | |
python-version: "pypy3.10" | |
steps: | |
- name: Harden Runner | |
uses: step-security/harden-runner@5c7944e73c4c2a096b17a9cb74d65b6c2bbafbde # v2.9.1 | |
with: | |
disable-sudo: true | |
egress-policy: block | |
# PyPy packages requires access to Rust binaries | |
allowed-endpoints: > | |
api.github.com:443 | |
files.pythonhosted.org:443 | |
github.com:443 | |
index.crates.io:443 | |
pypi.org:443 | |
static.crates.io:443 | |
- name: Checkout Repository | |
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 | |
- name: Set up Python${{ matrix.python-version }} | |
uses: actions/setup-python@f677139bbe7f9c59b41e40162b753c062f5d49a3 # v5.2.0 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install tox | |
run: | | |
python -m pip install --require-hashes -r requirements.txt | |
- name: Run bake test suite | |
run: | |
python -m tox -e ${{ matrix.tox-env }} -- ${{ matrix.posargs }} | |
# - name: Archive package | |
# if: ${{ matrix.tox-env == 'py39' }} | |
# uses: actions/upload-artifact@v4 | |
# with: | |
# name: cookie-cutter | |
# path: src/dist |