feat: install tab completion for bash, zsh, and fish (#16)
`completions install` generates the script from the same clap definition the binary parses with, so it cannot drift from `--help`, and writes it where each shell already looks. fish scans its own completions directory unprompted; bash and zsh get one marked `source` line appended to their rc file, because nothing puts a per-user directory on their search path by default. `completions uninstall` takes back exactly those lines and leaves the rest of the file alone.
This commit is contained in:
@@ -64,6 +64,9 @@ fn run(mut cli: Cli, out: &Out) -> CliResult {
|
||||
Commands::Skills(ref command) => {
|
||||
return commands::skills::run(out, command);
|
||||
}
|
||||
Commands::Completions(ref command) => {
|
||||
return commands::completions::run(out, command);
|
||||
}
|
||||
Commands::Config(ConfigCommand::Path) => {
|
||||
return commands::settings::config_path(out, &store);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user