struct

Kebab::Schema::Argument

Inherits Struct < Value < Object

A positional argument declared on a command.

Constructors

new(*, name : String, description : String, variadic : Bool = false, value_count : Int32 = 1, value_choices : Array(String) = [] of String)
Source

Instance methods

description

The description used in help output.

Source
name

The argument name (used as the placeholder in <name> in usage output).

Source
value_choices

The accepted values for an enum-typed argument, in help order. Empty when the values aren't a fixed set kebab knows (any non-enum, or a custom converter).

Source
value_count

How many positionals the argument consumes per unit: 1, or the tuple size for Tuple arguments. A variadic consumes the remainder in groups of this size.

Source
variadic?

true if the argument is variadic (declared as Array(T)).

Source