| 225 | }` |
| 226 | |
| 227 | export const renderIntroduction = (name: string, version: string, summary: string | undefined): string => { |
| 228 | const title = `${Ansi.annotate(name, Ansi.bold, Ansi.cyanBright)} ${Ansi.annotate(`v${version}`, Ansi.white)} ${ |
| 229 | Ansi.annotate("· Command wizard", Ansi.bold, Ansi.white) |
| 230 | }` |
| 231 | return [ |
| 232 | title, |
| 233 | ...(summary === undefined || summary.length === 0 ? [] : [summary]), |
| 234 | Ansi.annotate("Build a command interactively. Press Ctrl+C to cancel.", Ansi.blackBright), |
| 235 | "" |
| 236 | ].join("\n") |
| 237 | } |
| 238 | |
| 239 | export const renderCompletion = (commandLine: ReadonlyArray<string>): string => |
| 240 | renderCommandBlock("Command ready", commandLine, Ansi.cyanBright, Ansi.green) |