diff options
| author | Nick Pope <nick@nickpope.me.uk> | 2022-03-03 15:33:55 +0000 |
|---|---|---|
| committer | Carlton Gibson <carlton@noumenal.es> | 2022-03-09 14:51:13 +0100 |
| commit | b1005c0e4029c23f4e718ce0a7afdfa926c095de (patch) | |
| tree | dbe3a3de35752f572d3a9df5df3d834c2987b860 | |
| parent | fa948980341b43e76140ac78dcff30bf0bd65369 (diff) | |
Refs #33476 -- Prevented formatting of .py-tpl files with black by pre-commit.
When using `pre-commit run --all-files`, files explicitly passed to
black are processed even if they don't match the `include` configuration
option. For some reason, (only) one of the `*.py-tpl` files is picked up
by pre-commit. We can avoid this by explicitly excluding certain
patterns of files for the black hook in the pre-commit configuration.
| -rw-r--r-- | .pre-commit-config.yaml | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 3f6dc9ab4c..d75ae077bd 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -3,6 +3,7 @@ repos: rev: 22.1.0 hooks: - id: black + exclude: \.py-tpl$ - repo: https://github.com/PyCQA/isort rev: 5.9.3 hooks: |
