neex 0.6.15 → 0.6.16
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.
|
@@ -50,20 +50,16 @@ async function getBestCommand(filePath) {
|
|
|
50
50
|
if (!(await fileExists(absolutePath))) {
|
|
51
51
|
throw new Error(`File not found: ${filePath}`);
|
|
52
52
|
}
|
|
53
|
-
console.log(chalk_1.default.blue(`${figures_1.default.info} neex dev: Analyzing file type for ${chalk_1.default.cyan(filePath)}`));
|
|
54
53
|
switch (ext) {
|
|
55
54
|
case '.ts':
|
|
56
55
|
case '.mts':
|
|
57
56
|
case '.cts':
|
|
58
|
-
console.log(chalk_1.default.green(`${figures_1.default.tick} neex dev: Detected TypeScript file, using ts-node for execution`));
|
|
59
57
|
return `npx ts-node ${filePath}`;
|
|
60
58
|
case '.js':
|
|
61
59
|
case '.mjs':
|
|
62
60
|
case '.cjs':
|
|
63
|
-
console.log(chalk_1.default.green(`${figures_1.default.tick} neex dev: Detected JavaScript file, using node for execution`));
|
|
64
61
|
return `node ${filePath}`;
|
|
65
62
|
default:
|
|
66
|
-
console.log(chalk_1.default.yellow(`${figures_1.default.warning} neex dev: Unknown file extension ${ext}, attempting to run with node`));
|
|
67
63
|
return `node ${filePath}`;
|
|
68
64
|
}
|
|
69
65
|
}
|
|
@@ -89,8 +85,6 @@ function addDevCommands(program) {
|
|
|
89
85
|
.option('--signal <signal>', 'Signal to send to processes on restart', 'SIGTERM')
|
|
90
86
|
.action(async (file, options) => {
|
|
91
87
|
try {
|
|
92
|
-
console.log(chalk_1.default.blue(`${figures_1.default.info} neex dev: Starting enhanced development server...`));
|
|
93
|
-
console.log(chalk_1.default.blue(`${figures_1.default.info} neex dev: Target file: ${chalk_1.default.cyan(file)}`));
|
|
94
88
|
// Validate file parameter
|
|
95
89
|
if (!file || file.trim() === '') {
|
|
96
90
|
console.error(chalk_1.default.red(`${figures_1.default.cross} neex dev: Error - No file specified!`));
|
|
@@ -123,19 +117,25 @@ function addDevCommands(program) {
|
|
|
123
117
|
'Thumbs.db'
|
|
124
118
|
];
|
|
125
119
|
const extensions = options.ext || ['js', 'mjs', 'json', 'ts', 'tsx', 'jsx', 'vue', 'svelte'];
|
|
126
|
-
//
|
|
127
|
-
console.log(chalk_1.default.blue(`${figures_1.default.info} neex dev: Configuration:`));
|
|
128
|
-
console.log(chalk_1.default.blue(` ${figures_1.default.arrowRight} Command: ${chalk_1.default.cyan(commandToExecute)}`));
|
|
129
|
-
console.log(chalk_1.default.blue(` ${figures_1.default.arrowRight} Watch paths: ${chalk_1.default.cyan(watchPaths.join(', '))}`));
|
|
130
|
-
console.log(chalk_1.default.blue(` ${figures_1.default.arrowRight} Extensions: ${chalk_1.default.cyan(extensions.join(', '))}`));
|
|
131
|
-
console.log(chalk_1.default.blue(` ${figures_1.default.arrowRight} Ignore patterns: ${chalk_1.default.cyan(ignorePatterns.length)} patterns`));
|
|
132
|
-
console.log(chalk_1.default.blue(` ${figures_1.default.arrowRight} Restart delay: ${chalk_1.default.cyan(options.delay || 1000)}ms`));
|
|
133
|
-
console.log(chalk_1.default.blue(` ${figures_1.default.arrowRight} Clear console: ${chalk_1.default.cyan(options.clear ? 'Yes' : 'No')}`));
|
|
134
|
-
console.log(chalk_1.default.blue(` ${figures_1.default.arrowRight} Signal: ${chalk_1.default.cyan(options.signal)}`));
|
|
120
|
+
// Show verbose configuration only if verbose mode is enabled
|
|
135
121
|
if (options.verbose) {
|
|
136
|
-
console.log(chalk_1.default.blue(`${figures_1.default.info} neex dev:
|
|
122
|
+
console.log(chalk_1.default.blue(`${figures_1.default.info} neex dev: Starting enhanced development server...`));
|
|
123
|
+
console.log(chalk_1.default.blue(`${figures_1.default.info} neex dev: Target file: ${chalk_1.default.cyan(file)}`));
|
|
124
|
+
console.log(chalk_1.default.blue(`${figures_1.default.info} neex dev: Analyzing file type for ${chalk_1.default.cyan(file)}`));
|
|
125
|
+
console.log(chalk_1.default.green(`${figures_1.default.tick} neex dev: Detected ${path.extname(file)} file, using appropriate execution method`));
|
|
126
|
+
console.log(chalk_1.default.blue(`${figures_1.default.info} neex dev: Configuration:`));
|
|
127
|
+
console.log(chalk_1.default.blue(` ${figures_1.default.arrowRight} Command: ${chalk_1.default.cyan(commandToExecute)}`));
|
|
128
|
+
console.log(chalk_1.default.blue(` ${figures_1.default.arrowRight} Watch paths: ${chalk_1.default.cyan(watchPaths.join(', '))}`));
|
|
129
|
+
console.log(chalk_1.default.blue(` ${figures_1.default.arrowRight} Extensions: ${chalk_1.default.cyan(extensions.join(', '))}`));
|
|
130
|
+
console.log(chalk_1.default.blue(` ${figures_1.default.arrowRight} Ignore patterns: ${chalk_1.default.cyan(ignorePatterns.length)} patterns`));
|
|
131
|
+
console.log(chalk_1.default.blue(` ${figures_1.default.arrowRight} Restart delay: ${chalk_1.default.cyan(options.delay || 1000)}ms`));
|
|
132
|
+
console.log(chalk_1.default.blue(` ${figures_1.default.arrowRight} Clear console: ${chalk_1.default.cyan(options.clear ? 'Yes' : 'No')}`));
|
|
133
|
+
console.log(chalk_1.default.blue(` ${figures_1.default.arrowRight} Signal: ${chalk_1.default.cyan(options.signal)}`));
|
|
134
|
+
console.log(chalk_1.default.green(`${figures_1.default.tick} neex dev: Starting file watcher and process manager...`));
|
|
135
|
+
console.log(chalk_1.default.green(`${figures_1.default.tick} neex dev: Launching ${chalk_1.default.cyan(path.basename(file))} with auto-restart capability...`));
|
|
136
|
+
console.log(chalk_1.default.blue(`${figures_1.default.info} neex dev: Press Ctrl+C to stop the development server`));
|
|
137
|
+
console.log(chalk_1.default.gray(`${'='.repeat(60)}`));
|
|
137
138
|
}
|
|
138
|
-
console.log(chalk_1.default.green(`${figures_1.default.tick} neex dev: Starting file watcher and process manager...`));
|
|
139
139
|
// Create DevRunner instance
|
|
140
140
|
devRunner = new dev_runner_js_1.DevRunner({
|
|
141
141
|
runnerName: 'neex dev',
|
|
@@ -157,10 +157,8 @@ function addDevCommands(program) {
|
|
|
157
157
|
groupOutput: false,
|
|
158
158
|
isServerMode: false
|
|
159
159
|
});
|
|
160
|
-
//
|
|
161
|
-
console.log(chalk_1.default.
|
|
162
|
-
console.log(chalk_1.default.blue(`${figures_1.default.info} neex dev: Press Ctrl+C to stop the development server`));
|
|
163
|
-
console.log(chalk_1.default.gray(`${'='.repeat(60)}`));
|
|
160
|
+
// Simple startup message - only this line will be shown
|
|
161
|
+
console.log(chalk_1.default.blue(`${figures_1.default.info} [neex dev] Starting development server...`));
|
|
164
162
|
await devRunner.start([commandToExecute]);
|
|
165
163
|
}
|
|
166
164
|
catch (error) {
|