Skip to content

Commit

Permalink
Merge pull request #6626 from ipfs/fix/6622
Browse files Browse the repository at this point in the history
build: fix build when we don't have a full git tree
  • Loading branch information
Stebalien committed Sep 4, 2019
2 parents 5b44f48 + aba6c3d commit 1bcea7c
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions mk/git.mk
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
git-hash:=$(shell git describe --always --match=NeVeRmAtCh --dirty 2>/dev/null)

# First try to "describe" the state. This tells us if the state is dirty.
# If that fails (e.g., we're building a docker image and have an empty objects
# directory), assume the source isn't dirty and build anyways.
git-hash:=$(shell git describe --always --match=NeVeRmAtCh --dirty 2>/dev/null || git rev-parse --short HEAD 2>/dev/null)

0 comments on commit 1bcea7c

Please sign in to comment.