diff options
| author | Daniel Nephin <[email protected]> | 2016-10-18 13:28:23 -0700 |
|---|---|---|
| committer | Daniel Nephin <[email protected]> | 2016-10-18 13:28:23 -0700 |
| commit | 7597b2702729ebb651fc9bb2adac40bcc62db82d (patch) | |
| tree | 98a4b6bf55b492cb5a5a4c4697c401d527876fa1 /flag.go | |
| parent | 0e7ce96826adebbd2556517e0a993030ef3a0c51 (diff) | |
Don't print escaped strings for the default value of string flags with a default is set.
Signed-off-by: Daniel Nephin <[email protected]>
Diffstat (limited to 'flag.go')
| -rw-r--r-- | flag.go | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -534,7 +534,7 @@ func (f *FlagSet) FlagUsages() string { line += usage if !flag.defaultIsZeroValue() { if flag.Value.Type() == "string" { - line += fmt.Sprintf(" (default %q)", flag.DefValue) + line += fmt.Sprintf(" (default \"%s\")", flag.DefValue) } else { line += fmt.Sprintf(" (default %s)", flag.DefValue) } |
