Merge pull request #1287 from wking/lint-command-check
.tool/lint: Use 'command -v' to detect LINTER presence
This commit is contained in:
commit
d2f07f7359
1 changed files with 2 additions and 2 deletions
|
@ -5,10 +5,10 @@ set -o nounset
|
|||
set -o pipefail
|
||||
|
||||
# Create the linter path for use later
|
||||
LINTER=${GOPATH}/bin/gometalinter
|
||||
LINTER="${LINTER:-${GOPATH}/bin/gometalinter}"
|
||||
|
||||
# Make sure gometalinter is installed
|
||||
if [ ! -f ${LINTER} ]; then
|
||||
if ! command -v ${LINTER} >/dev/null 2>/dev/null; then
|
||||
echo >&2 "gometalinter must be installed. Please run 'make install.tools' and try again"
|
||||
exit 1
|
||||
fi
|
||||
|
|
Loading…
Reference in a new issue