deno
8ecf22bf - fix(cli): reject invalid --check and --no-check values

Commit
54 days ago
fix(cli): reject invalid --check and --no-check values Previously, passing an unrecognized value to --check or --no-check (e.g. `deno run --check=foo script.ts`) was silently ignored: the value fell through to a debug-log branch and type-checking was left at its default, so users got no feedback that their flag had no effect. Restrict both flags with a clap value_parser to their only valid values (`all` for --check, `remote` for --no-check), matching what the help text already documents. Invalid values now produce a clear error listing the possible values, and the accepted values continue to work. Help output gains a consistent `[possible values: ...]` hint like other flags.
Author
Parents
Loading