integrations/commander/test/fixtures/argument-choices/command.ts
raw| 1 | import commander from "commander"; |
| 2 | import { addCompletionSpecCommand } from "../../../src"; |
| 3 | |
| 4 | const program = new commander.Command(); |
| 5 | |
| 6 | program.addArgument( |
| 7 | new commander.Argument("<drink-size>", "drink cup size").choices(["small", "medium", "large"]) |
| 8 | ); |
| 9 | |
| 10 | addCompletionSpecCommand(program); |
| 11 | program.parse(process.argv); |