-
Notifications
You must be signed in to change notification settings - Fork 17.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cmd/go: fix the accuracy of Mercurial vcs.* stamped data
There were a few Mercurial command line uses that could cause the wrong data to be used: * The log command needs '-r.' to specify the currently checked out commit * HGPLAIN is needed to disable optional output on commands * '-S' is needed to for the 'status' command to recurse into any subrepos The most likely issue to be seen here was the use of '-l1' instead of '-r.', which prints the most recent commit instead of the current checkout. Since tagging in Mercurial creates a new commit, this basically means the data was wrong for every tagged build. This also adds an hgrc config file to the test, with config options to keep the time and author values fixed. It's what's used in the Mercurial test harness to keep the commit hashes stable, and allows the tests here to also match the time and the revision ID, to prevent regressing. Fixes #63532 Change-Id: I5b9971ce87c83431ec77e4a002bdc33fcf393856 GitHub-Last-Rev: 62c9db0 GitHub-Pull-Request: #63557 Reviewed-on: https://go-review.googlesource.com/c/go/+/535377 Reviewed-by: Bryan Mills <[email protected]> LUCI-TryBot-Result: Go LUCI <[email protected]> Reviewed-by: Sam Thanawalla <[email protected]> Auto-Submit: Sam Thanawalla <[email protected]> Reviewed-by: Michael Matloob <[email protected]>
- Loading branch information
1 parent
99bf122
commit 62452be
Showing
2 changed files
with
43 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters