Skip to content

v0.6.0

Choose a tag to compare

@github-actions github-actions released this 05 Nov 15:04
Immutable release. Only release title and notes can be modified.
0de3091

CONGA v0.6.0 adds implicit subcommands, completes trailing arguments with predictors, and makes -- end subcommand routing.

🚀 Highlights

  • Implicit subcommands: An implicit:"true" subcommand is selected by an operand that names no sibling, or by a flag only it declares, so tool ./script.ts runs as tool run ./script.ts (#98).
  • Trailing argument completion: DashArgs and RawArgs accept a predictor tag and complete after -- or once raw mode begins (#95).

⚠ Breaking Changes & Migration

  • -- ends subcommand routing (#95):
    • Operands after -- no longer name subcommands. They bind to DashArgs or positional arguments, or fail as unexpected arguments. Declare DashArgs on the command that should receive them.
  • Trailing argument grammar is checked at startup (#95):
    • Schema build fails with ErrSchema when a command declares both positional arguments and subcommands, combines RawArgs with command fields, puts optional or variadic positionals before RawArgs, or declares duplicate trailing collectors.
    • Move positionals to leaf commands, and use DashArgs to forward arguments after -- from a command with subcommands.
  • Flag-shaped tokens are no longer flag values (#95):
    • A flag that takes a value no longer consumes a following token that looks like a flag, or --. --name --verbose now fails with flag requires an argument: --name (exit 2). Pass such values attached: --name=--verbose.

✨ Features

  • cli: Add implicit:"true" subcommands, marked (default) in help (#98).
  • completion: Complete DashArgs and RawArgs with predictor tags, and offer no candidates after -- when the command has nowhere to bind them (#95).

🐛 Bug Fixes

  • cli: A declared --help or --version flag also disables the synthesized -h or -V short for that command chain (#97).

📚 Documentation

  • website: Document implicit subcommand routing (#103).

Full Changelog: v0.5.0...v0.6.0

Requirements: Go 1.27+ · Docs · pkg.go.dev