Skip to content

Commit

Permalink
TOOLS-397 add ldflags for gitspec to build.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
vkarpov15 committed Dec 18, 2014
1 parent 9026bbb commit ea45078
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,6 @@ export GOBIN=bin

for i in bsondump mongostat mongofiles mongoexport mongoimport mongorestore mongodump mongotop mongooplog; do
echo "Building ${i}..."
go install -tags "$tags" "$i/main/$i.go"
# Build the tool, using -ldflags to link in the current gitspec
go install -ldflags "-X github.com/mongodb/mongo-tools/common/options.Gitspec `git rev-parse HEAD`" -tags "$tags" "$i/main/$i.go"
done

0 comments on commit ea45078

Please sign in to comment.