File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -3,16 +3,22 @@ import path from 'path';
3
3
import child_process from 'child_process' ;
4
4
import fs from 'fs-extra' ;
5
5
import del from 'del' ;
6
+ import { platform } from 'os' ;
6
7
import { Input } from '../types' ;
7
8
8
9
export default async function build ( { root, output, report } : Input ) {
9
- report . info ( `Cleaning up previous build at ${ chalk . blue ( path . relative ( root , output ) ) } ` ) ;
10
+ report . info (
11
+ `Cleaning up previous build at ${ chalk . blue ( path . relative ( root , output ) ) } `
12
+ ) ;
10
13
11
14
await del ( [ output ] ) ;
12
15
13
16
report . info ( `Generating type definitions with ${ chalk . blue ( 'tsc' ) } ` ) ;
14
17
15
- const tsc = path . join ( root , 'node_modules' , '.bin' , 'tsc' ) ;
18
+ const tsc =
19
+ path . join ( root , 'node_modules' , '.bin' , 'tsc' ) +
20
+ ( platform ( ) === 'win32' ? '.cmd' : '' ) ;
21
+
16
22
const tsconfig = path . join ( root , 'tsconfig.json' ) ;
17
23
18
24
try {
You can’t perform that action at this time.
0 commit comments