/cli

Primary LanguageGoMIT LicenseMIT

CLI

A minimal package for building CLIs in Go, built around spf13/pflag with inspiration from existing CLI packages.

go.dev reference latest release build status code quality

TODO

  • Add validation for redeclared flag names (and shorthand) in subcommands (instead of pflag panic).
  • Print global flags in a separate section under usage.
  • Generate more flag types :D
  • Validate arguments based on Usage? E.g. command <in> <out> could validate that two positional arguments exist during parse?