@lynx-js/rspeedy-canary 0.11.5 → 0.11.6-canary-20251002-8983d4ce
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/CHANGELOG.md +60 -54
- package/dist/0~src_config_validate_ts.js +1992 -1882
- package/dist/1~src_cli_build_ts.js +0 -4
- package/dist/1~src_cli_commands_ts.js +32 -7
- package/dist/1~src_cli_dev_ts.js +0 -4
- package/dist/1~src_cli_inspect_ts.js +0 -4
- package/dist/1~src_cli_preview_ts.js +0 -4
- package/dist/1~src_config_validate_ts.js +1992 -1882
- package/package.json +3 -3
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { pathToFileURL } from "node:url";
|
|
2
2
|
import { register } from "#register";
|
|
3
3
|
import * as __WEBPACK_EXTERNAL_MODULE_node_fs_5ea92f0c__ from "node:fs";
|
|
4
|
-
import * as __WEBPACK_EXTERNAL_MODULE_node_path_c5b9b54f__ from "node:path";
|
|
5
4
|
export const __webpack_id__ = "src_cli_build_ts";
|
|
6
5
|
export const __webpack_ids__ = [
|
|
7
6
|
"src_cli_build_ts"
|
|
@@ -423,8 +422,5 @@ export const __webpack_modules__ = {
|
|
|
423
422
|
},
|
|
424
423
|
"node:fs": function(module) {
|
|
425
424
|
module.exports = __WEBPACK_EXTERNAL_MODULE_node_fs_5ea92f0c__;
|
|
426
|
-
},
|
|
427
|
-
"node:path": function(module) {
|
|
428
|
-
module.exports = __WEBPACK_EXTERNAL_MODULE_node_path_c5b9b54f__;
|
|
429
425
|
}
|
|
430
426
|
};
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import * as __WEBPACK_EXTERNAL_MODULE_node_path_c5b9b54f__ from "node:path";
|
|
1
2
|
export const __webpack_id__ = "src_cli_commands_ts";
|
|
2
3
|
export const __webpack_ids__ = [
|
|
3
4
|
"src_cli_commands_ts"
|
|
@@ -8,21 +9,42 @@ export const __webpack_modules__ = {
|
|
|
8
9
|
__webpack_require__.d(__webpack_exports__, {
|
|
9
10
|
apply: ()=>apply
|
|
10
11
|
});
|
|
11
|
-
var
|
|
12
|
+
var node_path__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("node:path");
|
|
13
|
+
var _version_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__("./src/version.ts");
|
|
12
14
|
function applyCommonOptions(command) {
|
|
13
|
-
command.option('-c --config <config>', 'specify the configuration file, can be a relative or absolute path').option('--env-mode <mode>', 'specify the env mode to load the .env.[mode] file').option('--no-env', 'disable loading `.env` files"').option('-m --mode <mode>', 'specify the build mode, can be `development`, `production` or `none`');
|
|
15
|
+
command.option('-c --config <config>', 'specify the configuration file, can be a relative or absolute path').option('--env-mode <mode>', 'specify the env mode to load the .env.[mode] file').option('--no-env', 'disable loading `.env` files"').option('-m --mode <mode>', 'specify the build mode, can be `development`, `production` or `none`').option('-r --root <root>', 'set the project root directory (absolute path or relative to cwd)');
|
|
16
|
+
}
|
|
17
|
+
function resolveRoot(cwd, root) {
|
|
18
|
+
if (!root) return cwd;
|
|
19
|
+
return node_path__WEBPACK_IMPORTED_MODULE_0__["default"].isAbsolute(root) ? root : node_path__WEBPACK_IMPORTED_MODULE_0__["default"].resolve(cwd, root);
|
|
14
20
|
}
|
|
15
21
|
function apply(program) {
|
|
16
22
|
const cwd = process.cwd();
|
|
17
|
-
program.name('rspeedy').usage('<command> [options]').version(
|
|
23
|
+
program.name('rspeedy').usage('<command> [options]').version(_version_js__WEBPACK_IMPORTED_MODULE_1__.version).option('--unmanaged', 'Force to use the unmanaged version of Rspeedy, instead of the locally installed.').showHelpAfterError(true).showSuggestionAfterError(true).exitOverride();
|
|
18
24
|
const buildCommand = program.command('build');
|
|
19
|
-
buildCommand.description('Build the project in production mode').option('--environment <name...>', 'specify the name of environment to build').option('--watch', 'Enable watch mode to automatically rebuild on file changes').action((buildOptions)=>
|
|
25
|
+
buildCommand.description('Build the project in production mode').option('--environment <name...>', 'specify the name of environment to build').option('--watch', 'Enable watch mode to automatically rebuild on file changes').action(async (buildOptions)=>{
|
|
26
|
+
const actualRoot = resolveRoot(cwd, buildOptions.root);
|
|
27
|
+
const { build } = await __webpack_require__.e("src_cli_build_ts").then(__webpack_require__.bind(__webpack_require__, "./src/cli/build.ts"));
|
|
28
|
+
return await build.call(buildCommand, actualRoot, buildOptions);
|
|
29
|
+
});
|
|
20
30
|
const devCommand = program.command('dev');
|
|
21
|
-
devCommand.description('Run the dev server and watch for source file changes while serving.').option('--base <base>', 'specify the base path of the server').option('--environment <name...>', 'specify the name of environment to build').action((devOptions)=>
|
|
31
|
+
devCommand.description('Run the dev server and watch for source file changes while serving.').option('--base <base>', 'specify the base path of the server').option('--environment <name...>', 'specify the name of environment to build').action(async (devOptions)=>{
|
|
32
|
+
const actualRoot = resolveRoot(cwd, devOptions.root);
|
|
33
|
+
const { dev } = await __webpack_require__.e("src_cli_dev_ts").then(__webpack_require__.bind(__webpack_require__, "./src/cli/dev.ts"));
|
|
34
|
+
return await dev.call(devCommand, actualRoot, devOptions);
|
|
35
|
+
});
|
|
22
36
|
const inspectCommand = program.command('inspect');
|
|
23
|
-
inspectCommand.description('View the Rsbuild config and Rspack config of the project.').option('--output <output>', 'specify inspect content output path').option('--verbose', 'show full function definitions in output').action((inspectOptions)=>
|
|
37
|
+
inspectCommand.description('View the Rsbuild config and Rspack config of the project.').option('--output <output>', 'specify inspect content output path').option('--verbose', 'show full function definitions in output').action(async (inspectOptions)=>{
|
|
38
|
+
const actualRoot = resolveRoot(cwd, inspectOptions.root);
|
|
39
|
+
const { inspect } = await __webpack_require__.e("src_cli_inspect_ts").then(__webpack_require__.bind(__webpack_require__, "./src/cli/inspect.ts"));
|
|
40
|
+
return await inspect.call(inspectCommand, actualRoot, inspectOptions);
|
|
41
|
+
});
|
|
24
42
|
const previewCommand = program.command('preview');
|
|
25
|
-
previewCommand.description('Preview the production build outputs locally.').option('--base <base>', 'specify the base path of the server').action((previewOptions)=>
|
|
43
|
+
previewCommand.description('Preview the production build outputs locally.').option('--base <base>', 'specify the base path of the server').action(async (previewOptions)=>{
|
|
44
|
+
const actualRoot = resolveRoot(cwd, previewOptions.root);
|
|
45
|
+
const { preview } = await __webpack_require__.e("src_cli_preview_ts").then(__webpack_require__.bind(__webpack_require__, "./src/cli/preview.ts"));
|
|
46
|
+
return await preview.call(previewCommand, actualRoot, previewOptions);
|
|
47
|
+
});
|
|
26
48
|
const commonCommands = [
|
|
27
49
|
devCommand,
|
|
28
50
|
buildCommand,
|
|
@@ -45,5 +67,8 @@ export const __webpack_modules__ = {
|
|
|
45
67
|
};
|
|
46
68
|
const version = package_namespaceObject.rE;
|
|
47
69
|
const rspackVersion = core_.rspack.rspackVersion;
|
|
70
|
+
},
|
|
71
|
+
"node:path": function(module) {
|
|
72
|
+
module.exports = __WEBPACK_EXTERNAL_MODULE_node_path_c5b9b54f__;
|
|
48
73
|
}
|
|
49
74
|
};
|
package/dist/1~src_cli_dev_ts.js
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { pathToFileURL } from "node:url";
|
|
2
2
|
import { register } from "#register";
|
|
3
3
|
import * as __WEBPACK_EXTERNAL_MODULE_node_fs_5ea92f0c__ from "node:fs";
|
|
4
|
-
import * as __WEBPACK_EXTERNAL_MODULE_node_path_c5b9b54f__ from "node:path";
|
|
5
4
|
export const __webpack_id__ = "src_cli_dev_ts";
|
|
6
5
|
export const __webpack_ids__ = [
|
|
7
6
|
"src_cli_dev_ts"
|
|
@@ -407,8 +406,5 @@ export const __webpack_modules__ = {
|
|
|
407
406
|
},
|
|
408
407
|
"node:fs": function(module) {
|
|
409
408
|
module.exports = __WEBPACK_EXTERNAL_MODULE_node_fs_5ea92f0c__;
|
|
410
|
-
},
|
|
411
|
-
"node:path": function(module) {
|
|
412
|
-
module.exports = __WEBPACK_EXTERNAL_MODULE_node_path_c5b9b54f__;
|
|
413
409
|
}
|
|
414
410
|
};
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { pathToFileURL } from "node:url";
|
|
2
2
|
import { register } from "#register";
|
|
3
3
|
import * as __WEBPACK_EXTERNAL_MODULE_node_fs_5ea92f0c__ from "node:fs";
|
|
4
|
-
import * as __WEBPACK_EXTERNAL_MODULE_node_path_c5b9b54f__ from "node:path";
|
|
5
4
|
export const __webpack_id__ = "src_cli_inspect_ts";
|
|
6
5
|
export const __webpack_ids__ = [
|
|
7
6
|
"src_cli_inspect_ts"
|
|
@@ -353,8 +352,5 @@ export const __webpack_modules__ = {
|
|
|
353
352
|
},
|
|
354
353
|
"node:fs": function(module) {
|
|
355
354
|
module.exports = __WEBPACK_EXTERNAL_MODULE_node_fs_5ea92f0c__;
|
|
356
|
-
},
|
|
357
|
-
"node:path": function(module) {
|
|
358
|
-
module.exports = __WEBPACK_EXTERNAL_MODULE_node_path_c5b9b54f__;
|
|
359
355
|
}
|
|
360
356
|
};
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { pathToFileURL } from "node:url";
|
|
2
2
|
import { register } from "#register";
|
|
3
3
|
import * as __WEBPACK_EXTERNAL_MODULE_node_fs_5ea92f0c__ from "node:fs";
|
|
4
|
-
import * as __WEBPACK_EXTERNAL_MODULE_node_path_c5b9b54f__ from "node:path";
|
|
5
4
|
export const __webpack_id__ = "src_cli_preview_ts";
|
|
6
5
|
export const __webpack_ids__ = [
|
|
7
6
|
"src_cli_preview_ts"
|
|
@@ -355,8 +354,5 @@ export const __webpack_modules__ = {
|
|
|
355
354
|
},
|
|
356
355
|
"node:fs": function(module) {
|
|
357
356
|
module.exports = __WEBPACK_EXTERNAL_MODULE_node_fs_5ea92f0c__;
|
|
358
|
-
},
|
|
359
|
-
"node:path": function(module) {
|
|
360
|
-
module.exports = __WEBPACK_EXTERNAL_MODULE_node_path_c5b9b54f__;
|
|
361
357
|
}
|
|
362
358
|
};
|