Commit cfe88fb8 authored by Dom Sekotill's avatar Dom Sekotill
Browse files

Add a hook to prevent use of `print()` in Python

parent e3b5b027
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -36,6 +36,13 @@ repos:
    entry: hooks/squash.py
    pass_filenames: false
    stages: [push]
  - id: python-no-print
    name: Check for print()
    description: Disallow use of the `print()` builtin
    language: pygrep
    entry: '\bprint('
    types: [python]
    stages: [commit]

- repo: https://github.com/pre-commit/pygrep-hooks
  rev: v1.5.1
@@ -65,7 +72,6 @@ repos:
    - flake8-commas
    - flake8-bugbear
    - flake8-docstrings
    - flake8-print
    - flake8-requirements
    - flake8-return
    - flake8-sfs
+8 −0
Original line number Diff line number Diff line
@@ -15,3 +15,11 @@
  entry: check-for-squash
  pass_filenames: false
  stages: [push]

- id: python-no-print
  name: Check for print()
  description: Disallow use of the `print()` builtin
  language: pygrep
  entry: '\bprint('
  types: [python]
  stages: [commit]