Skip to content
This repository was archived by the owner on Oct 17, 2021. It is now read-only.

Commit 7a3bd25

Browse files
committed
add comment to fmtDefValue
1 parent 5f1897e commit 7a3bd25

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

help.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@ func flagDashes(name string) string {
1717
return "-"
1818
}
1919

20+
// fmtDefValue adds quotes around default value strings that contain spaces so
21+
// the help representation matches what you would need to do when running a
22+
// command.
2023
func fmtDefValue(value interface{}) string {
2124
switch v := value.(type) {
2225
case string:

0 commit comments

Comments
 (0)