diff --git a/.cruft.json b/.cruft.json index a8fe943..4d1cef8 100644 --- a/.cruft.json +++ b/.cruft.json @@ -1,6 +1,6 @@ { "template": "/home/runner/work/cookiecutter-scverse/cookiecutter-scverse", - "commit": "77339226581ec535e1972984083ae70b702e7bec", + "commit": "2e75ba3563db51cf9022a1a0c9cc5d2f6c18edb1", "checkout": null, "context": { "cookiecutter": { @@ -36,7 +36,7 @@ "trim_blocks": true }, "_template": "/home/runner/work/cookiecutter-scverse/cookiecutter-scverse", - "_commit": "77339226581ec535e1972984083ae70b702e7bec" + "_commit": "2e75ba3563db51cf9022a1a0c9cc5d2f6c18edb1" } }, "directory": null diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index ab88fb4..986686d 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -19,7 +19,7 @@ jobs: # Check [[tool.hatch.envs.hatch-test.matrix]] in pyproject.toml and https://hatch.pypa.io/latest/environment/ for # more details. get-environments: - runs-on: ubuntu-latest + runs-on: ubuntu-slim outputs: envs: ${{ steps.get-envs.outputs.envs }} steps: @@ -70,6 +70,8 @@ jobs: python-version: ${{ matrix.env.python }} - name: create hatch environment run: uvx hatch env create ${{ matrix.env.name }} + - name: list all all installed package versions + run: uvx hatch run ${{ matrix.env.name }}:uv pip list - name: run tests using hatch env: MPLBACKEND: agg diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 2bf7d5a..ac8ee64 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -16,7 +16,7 @@ repos: hooks: - id: pyproject-fmt - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.14.11 + rev: v0.14.13 hooks: - id: ruff-check types_or: [python, pyi, jupyter] diff --git a/docs/template_usage.md b/docs/template_usage.md index 85081b4..c053542 100644 --- a/docs/template_usage.md +++ b/docs/template_usage.md @@ -144,9 +144,11 @@ There you can see the execution history, logs, and (re-)trigger workflows manual [Github Actions]: https://github.com/features/actions [twine]: https://github.com/pypa/twine -### Automating PyPI released using GitHub actions +(automating-the-pypi-release-using-github-actions)= +(automating-pypi-released-using-github-actions)= +(configuring-the-github-workflow)= -#### Configuring the Github workflow +### Automating the PyPI release using GitHub actions Tags adhering to `"*.*.*"` that are pushed to the `main` branch will trigger the release Github workflow that automatically builds and uploads the Python package to [PyPI][]. @@ -155,8 +157,9 @@ To set this up, login to [PyPI][], and proceed depending on whether you already - If yes, navigate to the project. In the left sidebar, choose "Publishing", then proceed to add the repository details. - If not, go to your [PyPI publishing settings][] and fill out the “Add a new pending publisher” form. +Enter everything *exactly* as it is displayed on GitHub (i.e. use the correct casing for your repository name). The "Workflow name" needs to bet set to `release.yaml`. -In most cases, you can leave the "Environment name" empty. +Set "Environment name" to “pypi” to match `environment: pypi` in `.github/workflows/release.yaml`. For more details, please refer to the official [PyPI guide for setting up trusted publishing][trusted publisher]. [pypi-trusted-publishing-guide]: https://docs.pypi.org/trusted-publishers/adding-a-publisher/