-
Notifications
You must be signed in to change notification settings - Fork 2
/
tp.yml
32 lines (25 loc) · 1.03 KB
/
tp.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
description: "The Template for TP CLI."
generate:
command:
description: "Add a new command"
structure:
src/commands/$PARAM_SINGULAR_NAME$/index.ts:
content: |-
import CustomCommand from '../../utils/oclif/custom-command';
export default class $PASCAL_SINGULAR_NAME$ extends CustomCommand {
static description = 'Describe what this command will do.'
static examples = [
'$ tp $PARAM_SINGULAR_NAME$',
]
static flags = {
// force: Flags.boolean({ description: 'An example of flag', aliases: ['f'], default: false }),
}
static args = {
// name: Args.string({ description: 'An example of argument', required: true }),
}
async run(): Promise<void> {
const { args, flags } = await this.parse($PASCAL_SINGULAR_NAME$);
this.log(JSON.stringify(args, null, 2));
this.log(JSON.stringify(flags, null, 2));
}
}