(options: BaseListOptions)
| 266 | } |
| 267 | |
| 268 | export async function listCommands(options: BaseListOptions): Promise<void> { |
| 269 | const format = parseFormat(options.format) |
| 270 | |
| 271 | await withHostAndSignalHandlers(options, { ephemeral: true }, async (host) => { |
| 272 | const commands = await requestCommands(host) |
| 273 | |
| 274 | if (format === "json") { |
| 275 | outputJson({ commands }) |
| 276 | return |
| 277 | } |
| 278 | |
| 279 | outputCommandsText(commands) |
| 280 | }) |
| 281 | } |
| 282 | |
| 283 | export async function listModes(options: BaseListOptions): Promise<void> { |
| 284 | const format = parseFormat(options.format) |
no test coverage detected