Goal: a runtime dependency-free completions generator for multiple shells configurable via document language.
Inspiration: jdx/usage. usage is a great tool and it is a runtime dependency.
Secondary goals
- Define generic parseable completion schema, based on existing usage's KDL spec
- Create a documentation and manpage generator
This project's intent is to also define a specification for the completion generation. Inspiring on usage's KDL spec, a detailed specification and scoped specifically to completion generation (ignoring help and other runtime features) is at docs/spec.md.
- KDL specification for commands, flags and arguments
- KDL parsing and AST implementation
- Completion generation for a particular shell, generic enough to expect future implementations for other shells
- Document usage for users
- Document requirements and guidelines and for more shells
make install # run `make uninstall` to uninstall it
cg --shell=zsh ./completions.kdl # Generate completions for `compgen` itself as a demoCompletions for compgen are generated by compgen itself at build-time, the official spec is at completions.kdl. It should by available after a successfull installation.
make check