@catladder/cli
Version:
Panter cli tool for cloud CI/CD and DevOps
24 lines • 943 B
TypeScript
import type { CommandDef } from "./core/types";
/**
* Generate completions for the current command line.
*
* @param allCommands - All registered command definitions
* @param words - The words typed so far (argv without the binary name)
* @param cursorWord - The word currently being completed (may be empty)
* @returns Array of completion strings
*/
export declare function getCompletions(allCommands: CommandDef[], words: string[], cursorWord: string): Promise<string[]>;
/**
* Generate the zsh completion script.
* The script discovers the local catladder binary at completion time,
* so it works without a global install.
*/
export declare function generateZshCompletionScript(): string;
/**
* Install completions by writing the script directly into .zshrc.
*/
export declare function installCompletions(): Promise<void>;
/**
* Remove completions from .zshrc.
*/
export declare function uninstallCompletions(): Promise<void>;