mirror of
https://github.com/docker/cli.git
synced 2026-09-25 17:02:07 -04:00
Fix create command flags
Any command that expects extra flags after positional args needs to set flags.SetInterspersed(false). Signed-off-by: Vincent Demeester <vincent@sbr.pm> Upstream-commit: aa00520fc8bb4e04c37c2eb41f3bc3558deab533 Component: engine
This commit is contained in:
@@ -46,6 +46,8 @@ func NewCreateCommand(dockerCli *client.DockerCli) *cobra.Command {
|
||||
cmd.SetFlagErrorFunc(flagErrorFunc)
|
||||
|
||||
flags := cmd.Flags()
|
||||
flags.SetInterspersed(false)
|
||||
|
||||
flags.StringVar(&opts.name, "name", "", "Assign a name to the container")
|
||||
|
||||
// Add an explicit help that doesn't have a `-h` to prevent the conflict
|
||||
|
||||
Reference in New Issue
Block a user