cmd := &serpent.Cmd{
Use: "create [name]",
Short: "DEPRECATED: Create a template from the current directory or as specified by flag",
Middleware: serpent.Chain(
serpent.RequireRangeArgs(0, 1),
r.InitClient(client),
),
where the serpent.RequireRangeArgs(0, 1) is arguably redundant with the Use. Also, we could provide an error message by just parsing Use.
E.g., in coder/coder we have code like:
where the
serpent.RequireRangeArgs(0, 1)
is arguably redundant with the Use. Also, we could provide an error message by just parsing Use.