Skip to content

Commit

Permalink
Use more specific names for coverage variables to avoid clashes
Browse files Browse the repository at this point in the history
  • Loading branch information
peterebden committed Sep 9, 2024
1 parent 004a8b3 commit 7fef7aa
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
4 changes: 4 additions & 0 deletions tools/please_go/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
Version 1.15.1
--------------
* Use more specific names for coverage variables to avoid clashes

Version 1.15.0
--------------
* Add support for Go 1.23 coverage generation (#294)
Expand Down
2 changes: 1 addition & 1 deletion tools/please_go/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.15.0
1.15.1
4 changes: 2 additions & 2 deletions tools/please_go/cover/cover.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,9 @@ func WriteCoverage(goTool, coverTool, covercfg, output, pkg string, srcs []strin
}
var cmd *exec.Cmd
if coverTool != "" {
cmd = exec.Command(coverTool, append([]string{"-mode=set", "-var=goCover", "-pkgcfg", pkgConfigFile, "-outfilelist", output}, srcs...)...)
cmd = exec.Command(coverTool, append([]string{"-mode=set", "-var=_plz_goCover", "-pkgcfg", pkgConfigFile, "-outfilelist", output}, srcs...)...)
} else {
cmd = exec.Command(goTool, append([]string{"tool", "cover", "-mode=set", "-var=goCover", "-pkgcfg", pkgConfigFile, "-outfilelist", output}, srcs...)...)
cmd = exec.Command(goTool, append([]string{"tool", "cover", "-mode=set", "-var=_plz_goCover", "-pkgcfg", pkgConfigFile, "-outfilelist", output}, srcs...)...)
}
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stderr
Expand Down

0 comments on commit 7fef7aa

Please sign in to comment.