@anycli/dev-cli
Version:
helpers for anycli CLIs
30 lines (29 loc) • 1.57 kB
TypeScript
import { Command } from '@anycli/command';
import * as Config from '@anycli/config';
export default class Readme extends Command {
static description: string;
static flags: {
multi: {
name: string;
char?: "a" | "b" | "i" | "p" | "q" | "s" | "u" | "g" | "c" | "d" | "e" | "f" | "h" | "j" | "k" | "l" | "m" | "n" | "o" | "r" | "t" | "v" | "x" | "y" | "z" | "A" | "B" | "C" | "D" | "E" | "F" | "G" | "H" | "I" | "J" | "K" | "L" | "M" | "N" | "O" | "P" | "Q" | "R" | "S" | "T" | "U" | "V" | "X" | "Y" | "Z" | undefined;
description?: string | undefined;
hidden?: boolean | undefined;
required?: boolean | undefined;
env?: string | undefined;
parse(input: boolean, context: any): boolean;
} & {
type: "boolean";
allowNo: boolean;
};
};
run(): Promise<void>;
replaceTag(readme: string, tag: string, body: string): string;
install(config: Config.IConfig): string;
usage(config: Config.IConfig): string;
multiCommands(config: Config.IConfig, commands: Config.Command[]): string;
createTopicFile(file: string, config: Config.IConfig, topic: Config.Topic, commands: Config.Command[]): void;
commands(config: Config.IConfig, commands: Config.Command[]): string;
renderCommand(config: Config.IConfig, c: Config.Command, commands: Config.Command[], level?: number): string;
commandCode(config: Config.IConfig, c: Config.Command): string | undefined;
commandUsage(command: Config.Command): string;
}