Guides
Shell completions
Generate completion scripts for bash, zsh, fish, and PowerShell from the same command tree you execute.
clily treats completion generation as part of the command definition, not a separate subsystem.
Enable completions
The simplest form is:
completion: trueThat enables the default completion command.
Customize the completion command
completion: {
command: 'completion',
aliases: ['completions'],
shell: 'zsh',
shells: ['zsh', 'bash', 'fish', 'pwsh'],
}Supported shells
bashzshfishpwsh
In the current implementation, bash, zsh, and fish are powered by omelette, while PowerShell uses a native generator.
Example invocation
node --experimental-strip-types src/index.ts completion fishDesign note
Completion generation uses the existing command tree, so subcommands and schema-derived options do not need to be re-described elsewhere.