We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0bcbceb commit 4faedfeCopy full SHA for 4faedfe
.pre-commit-config.yaml
@@ -12,6 +12,11 @@ repos:
12
13
- repo: local
14
hooks:
15
+ - id: debug-check
16
+ name: Check for debug statements
17
+ entry: tests/check-debug.sh
18
+ language: script
19
+ types: [python]
20
- id: lint-python
21
name: Lint Python
22
entry: make lint-python
tests/check-debug.sh
@@ -0,0 +1,10 @@
1
+#!/usr/bin/env bash
2
+# check for devtools debug commands in a python file
3
+set -e
4
+
5
+echo "checking: $1"
6
7
+if grep -Rn "^ *debug(" "$1"; then
8
+ echo "ERROR: debug commands found in $1"
9
+ exit 1
10
+fi
0 commit comments