aboutsummaryrefslogtreecommitdiff
path: root/hooks
diff options
context:
space:
mode:
authorMark Haines <mjark@negativecurvature.net>2017-09-18 15:51:26 +0100
committerGitHub <noreply@github.com>2017-09-18 15:51:26 +0100
commit238646ee3c8b684f1734c554178550b0fc07199f (patch)
tree7a9a540d85ad2915cff810d74754bd8d5383fb6e /hooks
parente28ee27605b1f4cc0f7eddc646f7273298418721 (diff)
Add contexts to device database (#233)
* Add contexts to device database * Remove spurious whitespace
Diffstat (limited to 'hooks')
-rwxr-xr-xhooks/pre-commit16
1 files changed, 10 insertions, 6 deletions
diff --git a/hooks/pre-commit b/hooks/pre-commit
index b10073ca..904d38dc 100755
--- a/hooks/pre-commit
+++ b/hooks/pre-commit
@@ -7,6 +7,16 @@ export GOGC=400
export GOPATH="$(pwd):$(pwd)/vendor"
export PATH="$PATH:$(pwd)/vendor/bin:$(pwd)/bin"
+echo "Checking that it builds"
+gb build
+
+# Check that all the packages can build.
+# When `go build` is given multiple packages it won't output anything, and just
+# checks that everything builds. This seems to do a better job of handling
+# missing imports than `gb build` does.
+echo "Double checking it builds..."
+go build github.com/matrix-org/dendrite/cmd/...
+
echo "Installing lint search engine..."
go install github.com/alecthomas/gometalinter/
gometalinter --config=linter.json ./... --install
@@ -20,11 +30,5 @@ misspell -error src *.md
echo "Testing..."
gb test
-# Check that all the packages can build.
-# When `go build` is given multiple packages it won't output anything, and just
-# checks that everything builds. This seems to do a better job of handling
-# missing imports than `gb build` does.
-echo "Double checking it builds..."
-go build github.com/matrix-org/dendrite/cmd/...
echo "Done!"