-
Notifications
You must be signed in to change notification settings - Fork 1
/
Takefile
55 lines (53 loc) · 1.12 KB
/
Takefile
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
module.exports = take => {
take.options.shell.printStdout = true;
take.options.shell.printStderr = true;
const out = 'dist';
return {
'': { deps: ['clean', 'build'] },
build: {
desc: 'Builds Take',
async execute() {
await take.exec('tsc');
},
},
clean: {
desc: 'Cleans up build output',
async execute() {
await take.exec('rm', '-rf', out);
},
},
test: {
desc: 'Tests Take',
async execute() {
await take.shell(
'ts-node',
[
'-P', 'tsconfig.json',
'./test/test.ts',
],
);
},
},
lint: {
async execute() {
await take.exec('tslint', '--project', '.');
},
},
fix: {
async execute() {
await take.exec('tslint --project . --fix');
},
},
publish: {
desc: 'Publishes format-tree to npm',
deps: [
':',
],
async execute() {
await take.exec('yarn', 'publish');
await take.exec('git', 'push', 'origin', '--tags');
await take.exec('git', 'push');
},
},
};
};