Pre-commit-hooks

Latest version: v5.0.0

Safety actively analyzes 714860 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 2 of 10

4.1.0

==================

Features
- `debug-statements`: add `pdbr` debugger.
- 614 PR by cansarigol.
- `detect-private-key`: add detection for additional key types.
- 658 PR by ljmf00.
- `check-executables-have-shebangs`: improve messaging on windows.
- 689 PR by pujitm.
- 686 issue by jmerdich.
- `check-added-large-files`: support `--enforce-all` with `git-lfs`.
- 674 PR by amartani.
- 560 issue by jeremy-coulon.

Fixes
- `check-case-conflict`: improve performance.
- 626 PR by guykisel.
- 625 issue by guykisel.
- `forbid-new-submodules`: fix false-negatives for `pre-push`.
- 619 PR by m-khvoinitsky.
- 609 issue by m-khvoinitsky.
- `check-merge-conflict`: fix execution in git worktrees.
- 662 PR by errsyn.
- 638 issue by daschuer.

Misc.
- Normalize case of hook names and descriptions.
- 671 PR by dennisroche.
- 673 PR by revolter.

4.0.1

==================

Fixes
- `check-shebang-scripts-are-executable` fix entry point.
- 602 issue by Person-93.
- 603 PR by scop.

4.0.0

==================

Features
- `check-json`: report duplicate keys.
- 558 PR by AdityaKhursale.
- 554 issue by adamchainz.
- `no-commit-to-branch`: add `main` to default blocked branches.
- 565 PR by ndevenish.
- `check-case-conflict`: check conflicts in directory names as well.
- 575 PR by slsyy.
- 70 issue by andyjack.
- `check-vcs-permalinks`: forbid other branch names.
- 582 PR by jack1142.
- 581 issue by jack1142.
- `check-shebang-scripts-are-executable`: new hook which ensures shebang'd
scripts are executable.
- 545 PR by scop.

Fixes
- `check-executables-have-shebangs`: Short circuit shebang lookup on windows.
- 544 PR by scop.
- `requirements-txt-fixer`: Fix comments which have indentation
- 549 PR by greshilov.
- 548 issue by greshilov.
- `pretty-format-json`: write to stdout using UTF-8 encoding.
- 571 PR by jack1142.
- 570 issue by jack1142.
- Use more inclusive language.
- 599 PR by asottile.

Breaking changes
- Remove deprecated hooks: `flake8`, `pyflakes`, `autopep8-wrapper`.
- 597 PR by asottile.

3.4.0

==================

Features
- `file-contents-sorter`: Add `--unique` argument
- 524 PR by danielhoherd.
- `check-vcs-permalinks`: Add `--additional-github-domain` option
- 530 PR by youngminz.
- New hook: `destroyed-symlinks` to detect unintentional symlink-breakages on
windows.
- 511 PR by m-khvoinitsky.

3.3.0

==================

Features
- `file-contents-sorter`: add `--ignore-case` option for case-insensitive
sorting
- 514 PR by Julian.
- `check-added-large-files`: add `--enforce-all` option to check non-added
files as well
- 519 PR by mshawcroft.
- 518 issue by mshawcroft.
- `fix-byte-order-marker`: new hook which fixes UTF-8 byte-order marker.
- 522 PR by jgowdy.

Deprecations
- `check-byte-order-marker` is now deprecated for `fix-byte-order-marker`

3.2.0

==================

Features
- `debug-statements`: add support for `pydevd_pycharm` debugger
- 502 PR by jgeerds.

Fixes
- `check-executables-have-shebangs`: fix git-quoted files on windows (spaces,
non-ascii, etc.)
- 509 PR by pawamoy.
- 508 issue by pawamoy.

Page 2 of 10

© 2025 Safety CLI Cybersecurity Inc. All Rights Reserved.