coredns/.presubmit/context
Miek Gieben c9b5cedbe9 Presubmit (#1719)
* build: add presubmits

We didn't have a way to encode presubmit; with this hack we can just
run a bunch of script on the build; this allows us to automatically
capture things like using the wrong context and maybe other fluff.

This allows us to cut down on code reviews and just have the build fail.

* hook it up

* put presubmit in checks; so we do it for tests as well

* Add explicit exit 1 if things fails
2018-04-23 08:45:49 -07:00

8 lines
192 B
Bash
Executable file

#!/bin/bash
echo "** presubmit/$(basename $0)"
if grep -lr "golang.org/x/net/context" "$@"; then
echo "** presubmit/$(basename $0): please use std lib's 'context' instead"
exit 1
fi