Commit 77d4347b authored by Alex Brainman's avatar Alex Brainman

misc/dist: remove lingering ~ file

Fixes #5405.

R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/9856043
parent 037a1a9f
......@@ -216,6 +216,12 @@ func (b *Build) Do() error {
// Re-install std without -race, so that we're not left
// with a slower, race-enabled cmd/go, cmd/godoc, etc.
_, err = b.run(src, goCmd, "install", "-a", "std")
// Re-building go command leaves old versions of go.exe as go.exe~ on windows.
// See (*builder).copyFile in $GOROOT/src/cmd/go/build.go for details.
// Remove it manually.
if b.OS == "windows" {
os.Remove(goCmd + "~")
}
}
if err != nil {
return err
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment