@travetto/cli 8.0.0-alpha.5 → 8.0.0-alpha.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/util.ts +5 -1
package/package.json
CHANGED
package/src/util.ts
CHANGED
|
@@ -33,7 +33,11 @@ export class CliUtil {
|
|
|
33
33
|
ShutdownManager.disableInterrupt();
|
|
34
34
|
|
|
35
35
|
let child: ChildProcess | undefined;
|
|
36
|
-
void WatchUtil.watchCompilerEvents('file', () => ShutdownManager.shutdownChild(child!, { reason: 'restart', mode: 'exit' }))
|
|
36
|
+
void WatchUtil.watchCompilerEvents('file', () => ShutdownManager.shutdownChild(child!, { reason: 'restart', mode: 'exit' })).catch(err => {
|
|
37
|
+
console.error('Failed to watch for compiler events, shutting down', err);
|
|
38
|
+
ShutdownManager.shutdownChild(child!, { reason: 'error', mode: 'exit' });
|
|
39
|
+
});
|
|
40
|
+
|
|
37
41
|
process
|
|
38
42
|
.on('SIGINT', () => ShutdownManager.shutdownChild(child!, { mode: 'exit' }))
|
|
39
43
|
.on('message', msg => child?.send?.(msg!));
|