summary refs log tree commit diff
path: root/scripts-dev
diff options
context:
space:
mode:
authorAndrew Morgan <andrew@amorgan.xyz>2020-02-17 16:35:48 +0000
committerAndrew Morgan <andrew@amorgan.xyz>2020-02-17 16:35:48 +0000
commite88fb44997ae8807e019c244e4f0d138de61a1a3 (patch)
tree151944df45ae303a70e133e652357c567e664907 /scripts-dev
parentCorrect pep517 flag in readme (#5651) (diff)
parentAdd a linting script (#5627) (diff)
downloadsynapse-e88fb44997ae8807e019c244e4f0d138de61a1a3.tar.xz
Add a linting script (#5627)
Diffstat (limited to 'scripts-dev')
-rwxr-xr-xscripts-dev/lint.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/scripts-dev/lint.sh b/scripts-dev/lint.sh
new file mode 100755
index 0000000000..ebb4d69f86
--- /dev/null
+++ b/scripts-dev/lint.sh
@@ -0,0 +1,12 @@
+#!/bin/sh
+#
+# Runs linting scripts over the local Synapse checkout
+# isort - sorts import statements
+# flake8 - lints and finds mistakes
+# black - opinionated code formatter
+
+set -e
+
+isort -y -rc synapse tests scripts-dev scripts
+flake8 synapse tests
+python3 -m black synapse tests scripts-dev scripts