Jargon
Jargon builds a command-line parser from a JSON Schema: the schema is the
single source of truth for a CLI's options, types, validation, help text, and
shell completion. Start from Jargon.cli (flat CLI) or Jargon.new
(subcommand mode), then parse/run the arguments.
Constants
Constructors
Class methods
Create a CLI from a schema. The schema source is given by a named argument:
json:, yaml:, or file: (extension-detected). A multi-document schema
is auto-detected and loaded as subcommands.
Create a CLI from a schema. The schema source is given by a named argument:
json:, yaml:, or file: (extension-detected). A multi-document schema
is auto-detected and loaded as subcommands.
Create a CLI from a schema. The schema source is given by a named argument:
json:, yaml:, or file: (extension-detected). A multi-document schema
is auto-detected and loaded as subcommands.
Control whether config parse warnings are emitted to STDERR
Flatten a schema by resolving all $ref pointers and removing $defs. Useful for AI tool definitions that don't support $ref.
DEPRECATED Use Jargon.cli(program_name, file: path) instead
DEPRECATED Use Jargon.cli(program_name, json: schema) instead