diff options
author | Adam Turner <9087854+AA-Turner@users.noreply.github.com> | 2023-10-10 09:17:53 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-10-10 09:17:53 (GMT) |
commit | 08ec4a1dbf66383303de9ce5cb55b2b437ef92c0 (patch) | |
tree | 229d6f6fd4018a2b6ae04c64841b932978a0d9c1 /.pre-commit-config.yaml | |
parent | 982f1b7d6dc2f13b9607ce092e36e32972e3702c (diff) | |
download | cpython-08ec4a1dbf66383303de9ce5cb55b2b437ef92c0.zip cpython-08ec4a1dbf66383303de9ce5cb55b2b437ef92c0.tar.gz cpython-08ec4a1dbf66383303de9ce5cb55b2b437ef92c0.tar.bz2 |
GH-109408: Move the Python file whitespace check from patchcheck to pre-commit (#109891)
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Diffstat (limited to '.pre-commit-config.yaml')
-rw-r--r-- | .pre-commit-config.yaml | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ffca103..59fe1c3 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -23,6 +23,15 @@ repos: - id: trailing-whitespace types_or: [c, inc, python, rst] + - repo: local + hooks: + - id: python-file-whitespace + name: "Check Python file whitespace" + entry: 'python Tools/patchcheck/reindent.py --nobackup --newline LF' + language: 'system' + types: [python] + exclude: '^(Lib/test/tokenizedata/|Tools/c-analyzer/cpython/_parser).*$' + - repo: https://github.com/sphinx-contrib/sphinx-lint rev: v0.6.8 hooks: |