what-framework-cli 0.8.2 → 0.8.4
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 +2 -2
- package/src/cli.js +3 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "what-framework-cli",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.4",
|
|
4
4
|
"description": "What Framework CLI - Dev server, build, and deployment tools",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"author": "ZVN DEV (https://zvndev.com)",
|
|
23
23
|
"license": "MIT",
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"what-framework": "^0.8.
|
|
25
|
+
"what-framework": "^0.8.4"
|
|
26
26
|
},
|
|
27
27
|
"repository": {
|
|
28
28
|
"type": "git",
|
package/src/cli.js
CHANGED
|
@@ -151,6 +151,7 @@ class SimpleWebSocket {
|
|
|
151
151
|
|
|
152
152
|
const __dirname = fileURLToPath(new URL('.', import.meta.url));
|
|
153
153
|
const cwd = process.cwd();
|
|
154
|
+
const packageVersion = JSON.parse(readFileSync(new URL('../package.json', import.meta.url), 'utf8')).version;
|
|
154
155
|
|
|
155
156
|
const args = process.argv.slice(2);
|
|
156
157
|
const command = args[0];
|
|
@@ -537,7 +538,7 @@ function init() {
|
|
|
537
538
|
generate: 'what generate',
|
|
538
539
|
},
|
|
539
540
|
dependencies: {
|
|
540
|
-
'what-framework':
|
|
541
|
+
'what-framework': `^${packageVersion}`,
|
|
541
542
|
},
|
|
542
543
|
}, null, 2));
|
|
543
544
|
|
|
@@ -557,7 +558,7 @@ function getFlag(name, defaultValue) {
|
|
|
557
558
|
}
|
|
558
559
|
|
|
559
560
|
// Async config loader — uses dynamic import() instead of unsafe new Function()
|
|
560
|
-
|
|
561
|
+
var _configCache = null;
|
|
561
562
|
async function loadConfigAsync() {
|
|
562
563
|
if (_configCache) return _configCache;
|
|
563
564
|
const configPath = join(cwd, 'what.config.js');
|