Skip to content

Arg::require_equals

since 0.1.0

Requires that options use the --option=val syntax

name = "prog"
[args]
cfg = { long = "config", action = "set", require-equals = true }
Terminal window
prog --config=file.conf
Terminal window
claptrap_cfg='file.conf'
name = "prog"
[args]
cfg = { long = "config", action = "set", require-equals = true }
Terminal window
prog --config file.conf
Terminal window
error: equal sign is needed when assigning values to '--config=<cfg>'
Usage: prog [OPTIONS]
For more information, try '--help'.