Skip to content

Commit 2c4fea7

Browse files
committed
Merge commit 'e6db50df7eefbc7a0f116e5dff79b01d9cc22741' into vendor-check
2 parents 5e4b928 + e6db50d commit 2c4fea7

File tree

3 files changed

+16
-1
lines changed

3 files changed

+16
-1
lines changed

release-tools/build.make

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,16 @@ test-fmt:
117117
false; \
118118
fi
119119

120+
# This test only runs when dep >= 0.5 is installed, which is the case for the CI setup.
121+
.PHONY: test-vendor
122+
test: test-vendor
123+
test-vendor:
124+
@ echo; echo "### $@:"
125+
@ case "$$(dep version 2>/dev/null | grep 'version *:')" in \
126+
*v0.[56789]*) dep check && echo "vendor up-to-date" || false;; \
127+
*) echo "skipping check, dep >= 0.5 required";; \
128+
esac
129+
120130
.PHONY: test-subtree
121131
test: test-subtree
122132
test-subtree:

release-tools/travis.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,11 @@ services:
55
matrix:
66
include:
77
- go: 1.11.1
8+
before_script:
9+
- mkdir -p bin
10+
- wget https://github.com/golang/dep/releases/download/v0.5.1/dep-linux-amd64 -O bin/dep
11+
- chmod u+x bin/dep
12+
- export PATH=$PWD/bin:$PATH
813
script:
914
- make -k all test
1015
after_success:

release-tools/verify-subtree.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ if [ ! "$DIR" ]; then
3030
exit 1
3131
fi
3232

33-
REV=$(git log -n1 --format=format:%H --no-merges -- "$DIR")
33+
REV=$(git log -n1 --remove-empty --format=format:%H --no-merges -- "$DIR")
3434
if [ "$REV" ]; then
3535
echo "Directory '$DIR' contains non-upstream changes:"
3636
echo

0 commit comments

Comments
 (0)