Merge pull request #17252 from karalabe/travis-debsrc-fix

build: noop clean during travis debsrc assembly step
This commit is contained in:
Péter Szilágyi 2018-07-26 13:29:57 +03:00 committed by GitHub
commit 514022bde6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 0 deletions

View File

@ -1,5 +1,12 @@
#!/bin/sh #!/bin/sh
# Cleaning the Go cache only makes sense if we actually have Go installed... or
# if Go is actually callable. This does not hold true during deb packaging, so
# we need an explicit check to avoid build failures.
if ! command -v go > /dev/null; then
exit
fi
version_gt() { version_gt() {
test "$(printf '%s\n' "$@" | sort -V | head -n 1)" != "$1" test "$(printf '%s\n' "$@" | sort -V | head -n 1)" != "$1"
} }