Skip to content

Commit

Permalink
[release-18.0] Fix anonymous paths in cobra code-gen (#14185) (#14238)
Browse files Browse the repository at this point in the history
Co-authored-by: vitess-bot[bot] <108069721+vitess-bot[bot]@users.noreply.github.com>
  • Loading branch information
vitess-bot[bot] authored Oct 11, 2023
1 parent d62e890 commit c074978
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions go/cmd/internal/docgen/docgen.go
Original file line number Diff line number Diff line change
Expand Up @@ -193,8 +193,8 @@ func anonymizeHomedir(file string) (err error) {

// We're replacing the stuff inside the square brackets in the example sed
// below:
// 's:Paths to search for config files in. (default \[.*\])$:Paths to search for config files in. (default \[$WORKDIR\]):'
sed := exec.Command("sed", "-i", "", "-e", fmt.Sprintf("s:%s:$WORKDIR:i", wd), file)
// 's:Paths to search for config files in. (default \[.*\])$:Paths to search for config files in. (default \[<WORKDIR>\]):'
sed := exec.Command("sed", "-i", "", "-e", fmt.Sprintf("s:%s:<WORKDIR>:i", wd), file)
if out, err := sed.CombinedOutput(); err != nil {
return fmt.Errorf("%w: %s", err, out)
}
Expand Down

0 comments on commit c074978

Please sign in to comment.