提交 cc56a711 编写于 作者: E E.J. Finneran 提交者: Mislav Marohnić

Allow version script to run through even if certain calls fail

When hub is installed via Homebrew, Homebrew does a shallow clone of the
hub repo and so the describe --tags call in this script fails and bash
halts the script there.

Allowing the script to turn through will allow the fallback block to run.

Closes #745 [ci skip]
上级 6195d797
......@@ -2,7 +2,7 @@
# Displays hub's release version
set -e
version="$(git describe --tags HEAD 2>/dev/null)"
version="$(git describe --tags HEAD 2>/dev/null || true)"
if [ -z "$version" ]; then
version="$(grep Version commands/version.go | head -1 | cut -d '"' -f2)"
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册