mirror of
https://github.com/subsurface/subsurface.git
synced 2025-01-31 22:03:23 +00:00
build-system: de-clutter output of get-version.sh
In certain situations git merge-base would report errors if the branch you are working in is older than the latest CICD builds. This simply hides those pointless errors. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
c8ef53c43f
commit
09f59211ed
1 changed files with 1 additions and 1 deletions
|
@ -48,7 +48,7 @@ if [ ! -f latest-subsurface-buildnumber ] ; then
|
|||
LAST_BUILD_BRANCHES=$(git branch -a --sort=-committerdate --list | grep remotes/origin/branch-for | cut -d/ -f3)
|
||||
for LAST_BUILD_BRANCH in $LAST_BUILD_BRANCHES "not-found" ; do
|
||||
LAST_BUILD_SHA=$(cut -d- -f 3 <<< "$LAST_BUILD_BRANCH")
|
||||
git -C "$SUBSURFACE_SOURCE" merge-base --is-ancestor "$LAST_BUILD_SHA" HEAD && break
|
||||
git -C "$SUBSURFACE_SOURCE" merge-base --is-ancestor "$LAST_BUILD_SHA" HEAD 2> /dev/null&& break
|
||||
done
|
||||
[ "not-found" = "$LAST_BUILD_BRANCH" ] && croak "can't find a build number for the current working tree"
|
||||
git checkout "$LAST_BUILD_BRANCH" &> /dev/null || croak "failed to check out $LAST_BUILD_BRANCH in nightly-builds"
|
||||
|
|
Loading…
Add table
Reference in a new issue