cookiecutter-django/.github/workflows/dependabot-uv-lock.yml
Bruno Alla 931e300b63
Pin Python version to 3.12 (#5456)
* Pin Python version to 3.12

* Add back actions/setup-python to bare metal tests

* Revert "Add back actions/setup-python to bare metal tests"

This reverts commit cdee7e2da7.

* Update test_bare.sh to run commands via uv

* Skip uv lock on PRs from forks

* Revert "Update test_bare.sh to run commands via uv"

This reverts commit 56f839e2b4.

* Add back actions/setup-python to bare metal tests

* Only run uv lock workflow on dependabot PRs
2024-10-12 17:46:45 +01:00

36 lines
743 B
YAML

name: uv
on:
pull_request:
paths:
- "pyproject.toml"
permissions:
contents: write
pull-requests: write
jobs:
lock:
if: ${{ github.actor == 'dependabot[bot]' }}
runs-on: ubuntu-latest
env:
GH_PAT: ${{ secrets.GH_PAT }}
steps:
- name: Checkout with token
uses: actions/checkout@v4
if: ${{ env.GH_PAT != '' }}
with:
token: ${{ env.GH_PAT }}
- name: Checkout without token
uses: actions/checkout@v4
if: ${{ env.GH_PAT == '' }}
- uses: astral-sh/setup-uv@v3
with:
enable-cache: true
- run: uv lock
- uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: Regenerate uv.lock