@evjs/cli 0.3.6 → 0.3.8
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/dist/cli-program.d.ts +5 -0
- package/dist/cli-program.js +9 -3
- package/dist/inspect.js +0 -1
- package/package.json +3 -3
package/dist/cli-program.d.ts
CHANGED
|
@@ -13,6 +13,11 @@ type DevFrameworkCommand = (config: Config<DefaultBundlerConfig> | undefined, op
|
|
|
13
13
|
cwd: string;
|
|
14
14
|
flags: CliFlags;
|
|
15
15
|
loadConfig: ConfigLoader;
|
|
16
|
+
/**
|
|
17
|
+
* `false` when the user passed `--no-shortcuts`. `undefined` otherwise, so
|
|
18
|
+
* the user's `ev.config.ts` → `dev.cliShortcuts` is authoritative.
|
|
19
|
+
*/
|
|
20
|
+
cliShortcuts?: false;
|
|
16
21
|
}) => Promise<void>;
|
|
17
22
|
export interface CliProgramDependencies {
|
|
18
23
|
version: string;
|
package/dist/cli-program.js
CHANGED
|
@@ -27,16 +27,22 @@ export async function runCliProgram(argv, dependencies) {
|
|
|
27
27
|
program
|
|
28
28
|
.command("dev")
|
|
29
29
|
.description("Start development server")
|
|
30
|
+
.option("--no-shortcuts", "Disable interactive CLI keyboard shortcuts")
|
|
30
31
|
.allowUnknownOption(true)
|
|
31
|
-
.action(async (
|
|
32
|
+
.action(async (options, command) => {
|
|
32
33
|
await runCommand("Failed to start dev server", async () => {
|
|
33
34
|
const cwd = dependencies.cwd();
|
|
34
35
|
const flags = parseCliFlags(command.args);
|
|
35
|
-
|
|
36
|
+
// Only inject cliShortcuts when the user passed --no-shortcuts; leave it
|
|
37
|
+
// absent otherwise so the user's ev.config.ts → dev.cliShortcuts wins.
|
|
38
|
+
const devOptions = {
|
|
36
39
|
cwd,
|
|
37
40
|
flags,
|
|
38
41
|
loadConfig: dependencies.loadConfig,
|
|
39
|
-
}
|
|
42
|
+
};
|
|
43
|
+
if (options.shortcuts === false)
|
|
44
|
+
devOptions.cliShortcuts = false;
|
|
45
|
+
await dependencies.dev(undefined, devOptions);
|
|
40
46
|
});
|
|
41
47
|
});
|
|
42
48
|
program
|
package/dist/inspect.js
CHANGED
|
@@ -88,7 +88,6 @@ export function formatInspectText(result) {
|
|
|
88
88
|
if (result.bundler) {
|
|
89
89
|
lines.push(` bundler: ${result.bundler.name}`);
|
|
90
90
|
lines.push(` bundler.build: ${formatCapabilities(result.bundler.capabilities.build)}`);
|
|
91
|
-
lines.push(` bundler.dev: ${formatCapabilities(result.bundler.capabilities.dev)}`);
|
|
92
91
|
for (const gap of result.bundler.gaps) {
|
|
93
92
|
lines.push(` bundler.gap: ${gap.capability} (${gap.reason})`);
|
|
94
93
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@evjs/cli",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.8",
|
|
4
4
|
"description": "Command-line wrapper for the evjs framework",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -28,8 +28,8 @@
|
|
|
28
28
|
"check-types": "tsc --noEmit"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@evjs/bundler-utoopack": "0.3.
|
|
32
|
-
"@evjs/ev": "0.3.
|
|
31
|
+
"@evjs/bundler-utoopack": "0.3.8",
|
|
32
|
+
"@evjs/ev": "0.3.8",
|
|
33
33
|
"@logtape/logtape": "^2.0.4",
|
|
34
34
|
"commander": "^12.1.0"
|
|
35
35
|
},
|