Pre-Commit Update #16
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: Pre-Commit Update | |
on: | |
schedule: | |
- cron: "0 12 * * 0" # run once a week on Sunday | |
# Allow to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
jobs: | |
pre-commit-update: | |
strategy: | |
matrix: | |
python-version: | |
- 3.11 | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- uses: actions/checkout@v4 | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install pre-commit | |
- name: Check for pre-commit dependency updates | |
# This fails, if there is a new version available, | |
# Update to the new version number in | |
# .pre-commit-config.yaml and config/default/pre-commit-config.yaml.j2. | |
run: | | |
pre-commit autoupdate | |
git diff --exit-code |