(yargs: Argv)
| 22 | const describe = 'list locations or get information for a specific location' |
| 23 | |
| 24 | const builder = (yargs: Argv): Argv<CommandArgs> => |
| 25 | outputItemOrListBuilder(apiCommandBuilder(yargs)) |
| 26 | .positional('id-or-index', { describe: 'the location id or number in list', type: 'string' }) |
| 27 | .example([ |
| 28 | ['$0 locations', 'list all locations'], |
| 29 | ['$0 locations 1', 'display details for the first location in the list retrieved by running "smartthings locations"'], |
| 30 | ['$0 locations 5dfd6626-ab1d-42da-bb76-90def3153998', 'display details for a location by id'], |
| 31 | ]) |
| 32 | .epilog(buildEpilog({ command, apiDocs: ['listLocations', 'getLocation'] })) |
| 33 | |
| 34 | const handler = async (argv: ArgumentsCamelCase<CommandArgs>): Promise<void> => { |
| 35 | const command = await apiCommand(argv) |
nothing calls this directly
no test coverage detected