Skip to content

Commit ba1056d

Browse files
authored
go_repository_tools: build with -buildvcs=false (#2324)
**What type of PR is this?** > Bug fix **What package or component does this PR mostly affect?** `go_repository_tools` **What does this PR do? Why is it needed?** Adds `-buildvcs=false` to the command line when building `gazelle` and other binaries for use within `go_repository`. Leaving VCS stamping enabled may cause problems if a VCS tool is misconfigured. We don't really need VCS stamping. **Which issues(s) does this PR fix?** Fixes #2323 **Other notes for review**
1 parent cd1408c commit ba1056d

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

internal/go_repository_tools.bzl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,7 @@ def _go_repository_tools_impl(ctx):
104104
"-ldflags",
105105
" ".join(ldflags),
106106
"-trimpath",
107+
"-buildvcs=false",
107108
"github.com/bazel-contrib/bazel-gazelle/v2/cmd/gazelle",
108109
"github.com/bazelbuild/bazel-gazelle/cmd/fetch_repo",
109110
"github.com/bazelbuild/bazel-gazelle/cmd/generate_repo_config",

0 commit comments

Comments
 (0)