(yargs: Argv)
| 34 | const describe = 'create a new device profile' |
| 35 | |
| 36 | const builder = (yargs: Argv): Argv<CommandArgs> => |
| 37 | inputAndOutputItemBuilder(apiOrganizationCommandBuilder(yargs)) |
| 38 | .example([ |
| 39 | ['$0 deviceprofiles:create', 'create a device profile from prompted input'], |
| 40 | ['$0 deviceprofiles:create --dry-run', 'build JSON for a device profile from prompted input'], |
| 41 | ['$0 deviceprofiles:create -i my-profile.yaml', 'create a device profile defined in "my-profile.yaml'], |
| 42 | ]) |
| 43 | .epilog(buildEpilog({ |
| 44 | command, |
| 45 | apiDocs: 'createDeviceProfile', |
| 46 | notes: 'Creates a new device profile. If a vid field is not present in the metadata' + |
| 47 | ' then a default device presentation will be created for this profile and the' + |
| 48 | ' vid set to reference it.', |
| 49 | })) |
| 50 | |
| 51 | const handler = async (argv: ArgumentsCamelCase<CommandArgs>): Promise<void> => { |
| 52 | const command = await apiOrganizationCommand(argv) |
nothing calls this directly
no test coverage detected