neex 0.6.96 → 0.6.98
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.
|
@@ -59,18 +59,11 @@ function addDevCommands(program) {
|
|
|
59
59
|
nodeArgs: options.nodeArgs ? options.nodeArgs.split(',').map((arg) => arg.trim()) : []
|
|
60
60
|
});
|
|
61
61
|
// --- Signal Handlers for Dev ---
|
|
62
|
-
let isShuttingDown = false;
|
|
63
62
|
const cleanupAndExit = () => {
|
|
64
|
-
if (isShuttingDown)
|
|
65
|
-
return;
|
|
66
|
-
isShuttingDown = true;
|
|
67
63
|
if (devManager) {
|
|
68
|
-
|
|
64
|
+
logger_manager_js_1.loggerManager.printLine(`\n${chalk_1.default.yellow('⏹')} Received SIGINT, shutting down...`, 'info');
|
|
69
65
|
devManager.stop().then(() => process.exit(0));
|
|
70
66
|
}
|
|
71
|
-
else {
|
|
72
|
-
process.exit(0);
|
|
73
|
-
}
|
|
74
67
|
};
|
|
75
68
|
const sigintHandler = () => cleanupAndExit();
|
|
76
69
|
const sigtermHandler = () => cleanupAndExit();
|
package/dist/src/dev-manager.js
CHANGED
|
@@ -47,7 +47,6 @@ class DevManager {
|
|
|
47
47
|
this.startTime = null;
|
|
48
48
|
this.moduleCache = new Map();
|
|
49
49
|
this.currentTempFile = null;
|
|
50
|
-
this.isShuttingDown = false;
|
|
51
50
|
this.options = options;
|
|
52
51
|
this.tempDir = path_1.default.join(process.cwd(), '.neex-temp');
|
|
53
52
|
this.debouncedRestart = (0, lodash_1.debounce)(this.restart.bind(this), Math.max(options.delay, 100));
|
|
@@ -427,11 +426,8 @@ class DevManager {
|
|
|
427
426
|
}
|
|
428
427
|
}
|
|
429
428
|
async stop() {
|
|
430
|
-
if (this.isShuttingDown)
|
|
431
|
-
return;
|
|
432
|
-
this.isShuttingDown = true;
|
|
433
429
|
if (!this.options.quiet) {
|
|
434
|
-
logger_manager_js_1.loggerManager.printLine(
|
|
430
|
+
logger_manager_js_1.loggerManager.printLine(`${chalk_1.default.yellow('⏹')} Stopping dev server...`, 'info');
|
|
435
431
|
}
|
|
436
432
|
if (this.watcher) {
|
|
437
433
|
await this.watcher.close();
|