Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#571 Use pre-commit dog food and update release process for pre-commit autoupdate. #572

Merged
merged 16 commits into from
May 21, 2024
Merged
23 changes: 23 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,28 @@ jobs:
${{ matrix.task.run }}
if: ${{ matrix.task.run-if }}

pre-commit:
name: pre-commit
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
adiroiban marked this conversation as resolved.
Show resolved Hide resolved
with:
fetch-depth: 0

- name: Set up python
uses: actions/setup-python@v5
with:
python-version: 3.12

- name: Install dependencies
run: python -m pip pre-commit
hynek marked this conversation as resolved.
Show resolved Hide resolved

- name: Check
run: |
${{ matrix.task.run }}
if: ${{ matrix.task.run-if }}


pypi-publish:
name: Check tag and publish
Expand Down Expand Up @@ -292,6 +314,7 @@ jobs:
- test-windows
- coverage
- check
- pre-commit
steps:
- name: Require all successes
uses: re-actors/alls-green@3a2de129f0713010a71314c74e33c0e3ef90e696
Expand Down
5 changes: 5 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,8 @@ repos:
- id: debug-statements
- id: check-toml
- id: check-yaml

- repo: https://github.com/twisted/towncrier
rev: 23.11.0
hooks:
- id: towncrier-check
4 changes: 2 additions & 2 deletions docs/pre-commit.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Usage with the default configuration

repos:
- repo: https://github.com/twisted/towncrier
rev: 22.13.0 # run 'pre-commit autoupdate' to update
rev: 23.11.0 # run 'pre-commit autoupdate' to update
hooks:
- id: towncrier-check

Expand All @@ -30,7 +30,7 @@ News fragments are stored in ``changelog.d/`` in the root of the repository and

repos:
- repo: https://github.com/twisted/towncrier
rev: 22.13.0 # run 'pre-commit autoupdate' to update
rev: 23.11.0 # run 'pre-commit autoupdate' to update
hooks:
- id: towncrier-update
files: $changelog\.d/
Expand Down