-
-
Notifications
You must be signed in to change notification settings - Fork 18
/
hela.config.foo.js
29 lines (25 loc) · 947 Bytes
/
hela.config.foo.js
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
import { hela } from '@hela/core';
export const cli = hela().option('--foo [bar]', 'some new global flag');
export const init = cli
.command('init', 'Initialize a project')
.alias('innit', 'inti')
.option('--foo [bar]', 'Some flag descr')
.action(() => {
console.log('init!!!');
});
export const ensInit = cli
.command('ens init', 'initialize some ens things')
.alias('intit', 'initit', 'inint')
.action(({ options }, { settings }) => {
console.log('ens initialized', options, settings);
});
export const ensCreate = cli
.command('ens create <collection> [...names]', 'Create collection')
.alias('create', 'creat', 'craet', 'craete', 'cr')
.action(async ({ collection, names, options }, { globalOptions }) => {
console.log('create!');
console.log('collection:', collection);
console.log('names:', names);
console.log('options:', options);
console.log('globalOptions:', globalOptions);
});