mirror of
https://github.com/docker/cli.git
synced 2026-01-13 18:22:35 +03:00
cli: define const for magic value
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
@@ -337,8 +337,10 @@ func operationSubCommands(cmd *cobra.Command) []*cobra.Command {
|
||||
return cmds
|
||||
}
|
||||
|
||||
const defaultTermWidth = 80
|
||||
|
||||
func wrappedFlagUsages(cmd *cobra.Command) string {
|
||||
width := 80
|
||||
width := defaultTermWidth
|
||||
if ws, err := term.GetWinsize(0); err == nil {
|
||||
width = int(ws.Width)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user