Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .pre-commit-hooks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,9 @@

Background: In a big codebase, the exclude lists can be quite long and it's easy to make a typo or forget to remove an entry when it's no longer needed.
This hook helps you to maintain a clean and up to date exclude list.

Note: This hook deliberately only supports simple `|`-separated lists of file paths in `exclude` fields — complex regular expressions are not supported.
Keeping exclusions as plain `|`-separated paths also makes it easier for humans to maintain an overview of what is excluded.
entry: check-useless-exclude-paths-hooks
pass_filenames: false
always_run: true
Expand Down
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,9 @@ Check for non existing and duplicate paths in `.pre-commit-config.yaml`.
Background: In a big codebase, the exclude lists can be quite long and it's easy to make a typo or forget to remove an entry when it's no longer needed.
This hook helps you to maintain a clean and up to date exclude list.

Note: This hook deliberately only supports simple `|`-separated lists of file paths in `exclude` fields — complex regular expressions are not supported.
Keeping exclusions as plain `|`-separated paths also makes it easier for humans to maintain an overview of what is excluded.

### `print-pre-commit-metrics`

Count the number of excludes in `.pre-commit-config.yaml` and print them in json format.
Expand Down