@rspack/cli 1.6.4 → 1.6.6
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/{0~361.js → 0~274.js} +13 -13
- package/dist/{1~361.mjs → 1~274.mjs} +12 -12
- package/dist/constants.d.ts +1 -0
- package/dist/index.js +20 -21
- package/dist/index.mjs +44 -45
- package/package.json +4 -4
|
@@ -1,40 +1,40 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
exports.ids = [
|
|
3
|
-
"
|
|
3
|
+
"274"
|
|
4
4
|
];
|
|
5
5
|
exports.modules = {
|
|
6
6
|
"./src/utils/profile.ts": function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
7
7
|
__webpack_require__.d(__webpack_exports__, {
|
|
8
8
|
applyProfile: ()=>applyProfile
|
|
9
9
|
});
|
|
10
|
-
var
|
|
11
|
-
var
|
|
12
|
-
var
|
|
13
|
-
var
|
|
14
|
-
var
|
|
10
|
+
var node_fs__rspack_import_0 = __webpack_require__("node:fs");
|
|
11
|
+
var node_fs__rspack_import_0_default = /*#__PURE__*/ __webpack_require__.n(node_fs__rspack_import_0);
|
|
12
|
+
var node_path__rspack_import_1 = __webpack_require__("node:path");
|
|
13
|
+
var node_path__rspack_import_1_default = /*#__PURE__*/ __webpack_require__.n(node_path__rspack_import_1);
|
|
14
|
+
var _rspackCore__rspack_import_2 = __webpack_require__("./src/utils/rspackCore.ts");
|
|
15
15
|
const DEFAULT_RUST_TRACE_LAYER = "perfetto";
|
|
16
16
|
async function applyProfile(filterValue, traceLayer = DEFAULT_RUST_TRACE_LAYER, traceOutput) {
|
|
17
17
|
const { asyncExitHook } = await import("exit-hook");
|
|
18
18
|
if ("logger" !== traceLayer && "perfetto" !== traceLayer) throw new Error(`unsupported trace layer: ${traceLayer}`);
|
|
19
19
|
const timestamp = Date.now();
|
|
20
|
-
const defaultOutputDir =
|
|
20
|
+
const defaultOutputDir = node_path__rspack_import_1_default().resolve(`.rspack-profile-${timestamp}-${process.pid}`);
|
|
21
21
|
if (traceOutput) {
|
|
22
|
-
if ("stdout" !== traceOutput && "stderr" !== traceOutput) traceOutput =
|
|
22
|
+
if ("stdout" !== traceOutput && "stderr" !== traceOutput) traceOutput = node_path__rspack_import_1_default().resolve(defaultOutputDir, traceOutput);
|
|
23
23
|
} else {
|
|
24
|
-
const defaultRustTracePerfettoOutput =
|
|
24
|
+
const defaultRustTracePerfettoOutput = node_path__rspack_import_1_default().resolve(defaultOutputDir, "rspack.pftrace");
|
|
25
25
|
const defaultRustTraceLoggerOutput = "stdout";
|
|
26
26
|
const defaultTraceOutput = "perfetto" === traceLayer ? defaultRustTracePerfettoOutput : defaultRustTraceLoggerOutput;
|
|
27
27
|
traceOutput = defaultTraceOutput;
|
|
28
28
|
}
|
|
29
29
|
await ensureFileDir(traceOutput);
|
|
30
|
-
await
|
|
31
|
-
asyncExitHook(
|
|
30
|
+
await _rspackCore__rspack_import_2.Z.experiments.globalTrace.register(filterValue, traceLayer, traceOutput);
|
|
31
|
+
asyncExitHook(_rspackCore__rspack_import_2.Z.experiments.globalTrace.cleanup, {
|
|
32
32
|
wait: 500
|
|
33
33
|
});
|
|
34
34
|
}
|
|
35
35
|
async function ensureFileDir(outputFilePath) {
|
|
36
|
-
const dir =
|
|
37
|
-
await
|
|
36
|
+
const dir = node_path__rspack_import_1_default().dirname(outputFilePath);
|
|
37
|
+
await node_fs__rspack_import_0_default().promises.mkdir(dir, {
|
|
38
38
|
recursive: true
|
|
39
39
|
});
|
|
40
40
|
}
|
|
@@ -1,38 +1,38 @@
|
|
|
1
|
-
export const __webpack_id__ = "
|
|
1
|
+
export const __webpack_id__ = "274";
|
|
2
2
|
export const __webpack_ids__ = [
|
|
3
|
-
"
|
|
3
|
+
"274"
|
|
4
4
|
];
|
|
5
5
|
export const __webpack_modules__ = {
|
|
6
6
|
"./src/utils/profile.ts": function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
7
7
|
__webpack_require__.d(__webpack_exports__, {
|
|
8
8
|
applyProfile: ()=>applyProfile
|
|
9
9
|
});
|
|
10
|
-
var
|
|
11
|
-
var
|
|
12
|
-
var
|
|
10
|
+
var node_fs__rspack_import_0 = __webpack_require__("node:fs");
|
|
11
|
+
var node_path__rspack_import_1 = __webpack_require__("node:path");
|
|
12
|
+
var _rspackCore__rspack_import_2 = __webpack_require__("./src/utils/rspackCore.ts");
|
|
13
13
|
const DEFAULT_RUST_TRACE_LAYER = "perfetto";
|
|
14
14
|
async function applyProfile(filterValue, traceLayer = DEFAULT_RUST_TRACE_LAYER, traceOutput) {
|
|
15
15
|
const { asyncExitHook } = await import("exit-hook");
|
|
16
16
|
if ("logger" !== traceLayer && "perfetto" !== traceLayer) throw new Error(`unsupported trace layer: ${traceLayer}`);
|
|
17
17
|
const timestamp = Date.now();
|
|
18
|
-
const defaultOutputDir =
|
|
18
|
+
const defaultOutputDir = node_path__rspack_import_1["default"].resolve(`.rspack-profile-${timestamp}-${process.pid}`);
|
|
19
19
|
if (traceOutput) {
|
|
20
|
-
if ("stdout" !== traceOutput && "stderr" !== traceOutput) traceOutput =
|
|
20
|
+
if ("stdout" !== traceOutput && "stderr" !== traceOutput) traceOutput = node_path__rspack_import_1["default"].resolve(defaultOutputDir, traceOutput);
|
|
21
21
|
} else {
|
|
22
|
-
const defaultRustTracePerfettoOutput =
|
|
22
|
+
const defaultRustTracePerfettoOutput = node_path__rspack_import_1["default"].resolve(defaultOutputDir, "rspack.pftrace");
|
|
23
23
|
const defaultRustTraceLoggerOutput = "stdout";
|
|
24
24
|
const defaultTraceOutput = "perfetto" === traceLayer ? defaultRustTracePerfettoOutput : defaultRustTraceLoggerOutput;
|
|
25
25
|
traceOutput = defaultTraceOutput;
|
|
26
26
|
}
|
|
27
27
|
await ensureFileDir(traceOutput);
|
|
28
|
-
await
|
|
29
|
-
asyncExitHook(
|
|
28
|
+
await _rspackCore__rspack_import_2.Z.experiments.globalTrace.register(filterValue, traceLayer, traceOutput);
|
|
29
|
+
asyncExitHook(_rspackCore__rspack_import_2.Z.experiments.globalTrace.cleanup, {
|
|
30
30
|
wait: 500
|
|
31
31
|
});
|
|
32
32
|
}
|
|
33
33
|
async function ensureFileDir(outputFilePath) {
|
|
34
|
-
const dir =
|
|
35
|
-
await
|
|
34
|
+
const dir = node_path__rspack_import_1["default"].dirname(outputFilePath);
|
|
35
|
+
await node_fs__rspack_import_0["default"].promises.mkdir(dir, {
|
|
36
36
|
recursive: true
|
|
37
37
|
});
|
|
38
38
|
}
|
package/dist/constants.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -914,20 +914,20 @@ ${section.body}` : section.body).join("\n\n"));
|
|
|
914
914
|
return internalPreviewConfig(item);
|
|
915
915
|
}
|
|
916
916
|
function normalizeHotOption(value) {
|
|
917
|
-
if ("boolean" == typeof value || "only" === value) return value;
|
|
918
917
|
if ("false" === value) return false;
|
|
919
|
-
return true;
|
|
918
|
+
if ("true" === value) return true;
|
|
919
|
+
return value;
|
|
920
920
|
}
|
|
921
921
|
class ServeCommand {
|
|
922
922
|
async apply(cli) {
|
|
923
923
|
const command = cli.program.command("serve", "run the rspack dev server.").alias("server").alias("s").alias("dev");
|
|
924
924
|
commonOptionsForBuildAndServe(commonOptions(command)).option("--hot [mode]", "enables hot module replacement").option("--port <port>", "allows to specify a port to use").option("--host <host>", "allows to specify a hostname to use");
|
|
925
|
-
command.action(async (
|
|
926
|
-
setDefaultNodeEnv(
|
|
927
|
-
normalizeCommonOptions(
|
|
928
|
-
|
|
925
|
+
command.action(async (cliOptions)=>{
|
|
926
|
+
setDefaultNodeEnv(cliOptions, "development");
|
|
927
|
+
normalizeCommonOptions(cliOptions, "serve");
|
|
928
|
+
cliOptions.hot = normalizeHotOption(cliOptions.hot);
|
|
929
929
|
const { RspackDevServer } = await import("@rspack/dev-server");
|
|
930
|
-
const compiler = await cli.createCompiler(
|
|
930
|
+
const compiler = await cli.createCompiler(cliOptions, "serve");
|
|
931
931
|
if (!compiler) return;
|
|
932
932
|
const compilers = cli.isMultipleCompiler(compiler) ? compiler.compilers : [
|
|
933
933
|
compiler
|
|
@@ -938,7 +938,7 @@ ${section.body}` : section.body).join("\n\n"));
|
|
|
938
938
|
const compilerForDevServer = possibleCompilers.length > 0 ? possibleCompilers[0] : compilers[0];
|
|
939
939
|
for (const compiler of compilers){
|
|
940
940
|
const devServer = compiler.options.devServer ??= {};
|
|
941
|
-
devServer.hot =
|
|
941
|
+
devServer.hot = cliOptions.hot ?? devServer.hot ?? true;
|
|
942
942
|
if (false !== devServer.client) {
|
|
943
943
|
if (true === devServer.client || null == devServer.client) devServer.client = {};
|
|
944
944
|
devServer.client = {
|
|
@@ -950,10 +950,10 @@ ${section.body}` : section.body).join("\n\n"));
|
|
|
950
950
|
};
|
|
951
951
|
}
|
|
952
952
|
}
|
|
953
|
-
const
|
|
954
|
-
const { setupMiddlewares } =
|
|
953
|
+
const devServerOptions = compilerForDevServer.options.devServer ??= {};
|
|
954
|
+
const { setupMiddlewares } = devServerOptions;
|
|
955
955
|
const lazyCompileMiddleware = rspackCore.Z.experiments.lazyCompilationMiddleware(compiler);
|
|
956
|
-
|
|
956
|
+
devServerOptions.setupMiddlewares = (middlewares, server)=>{
|
|
957
957
|
let finalMiddlewares = middlewares;
|
|
958
958
|
if (setupMiddlewares) finalMiddlewares = setupMiddlewares(finalMiddlewares, server);
|
|
959
959
|
return [
|
|
@@ -961,20 +961,19 @@ ${section.body}` : section.body).join("\n\n"));
|
|
|
961
961
|
lazyCompileMiddleware
|
|
962
962
|
];
|
|
963
963
|
};
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
if (false !==
|
|
968
|
-
if (true ===
|
|
969
|
-
|
|
964
|
+
devServerOptions.hot = cliOptions.hot ?? devServerOptions.hot ?? true;
|
|
965
|
+
devServerOptions.host = cliOptions.host || devServerOptions.host;
|
|
966
|
+
devServerOptions.port = cliOptions.port ?? devServerOptions.port;
|
|
967
|
+
if (false !== devServerOptions.client) {
|
|
968
|
+
if (true === devServerOptions.client || null == devServerOptions.client) devServerOptions.client = {};
|
|
969
|
+
devServerOptions.client = {
|
|
970
970
|
overlay: {
|
|
971
971
|
errors: true,
|
|
972
972
|
warnings: false
|
|
973
973
|
},
|
|
974
|
-
...
|
|
974
|
+
...devServerOptions.client
|
|
975
975
|
};
|
|
976
976
|
}
|
|
977
|
-
const devServerOptions = result;
|
|
978
977
|
if (devServerOptions.port) {
|
|
979
978
|
const portNumber = Number(devServerOptions.port);
|
|
980
979
|
if (!Number.isNaN(portNumber)) {
|
|
@@ -1188,7 +1187,7 @@ ${section.body}` : section.body).join("\n\n"));
|
|
|
1188
1187
|
this.colors = this.createColors();
|
|
1189
1188
|
this.program = program;
|
|
1190
1189
|
program.help();
|
|
1191
|
-
program.version("1.6.
|
|
1190
|
+
program.version("1.6.6");
|
|
1192
1191
|
}
|
|
1193
1192
|
async createCompiler(options, rspackCommand, callback) {
|
|
1194
1193
|
let { config, pathMap } = await this.loadConfig(options);
|
|
@@ -1262,7 +1261,7 @@ ${section.body}` : section.body).join("\n\n"));
|
|
|
1262
1261
|
}
|
|
1263
1262
|
if (options.profile) item.profile = true;
|
|
1264
1263
|
if (process.env.RSPACK_PROFILE) {
|
|
1265
|
-
const { applyProfile } = await __webpack_require__.e("
|
|
1264
|
+
const { applyProfile } = await __webpack_require__.e("274").then(__webpack_require__.bind(__webpack_require__, "./src/utils/profile.ts"));
|
|
1266
1265
|
await applyProfile(process.env.RSPACK_PROFILE, process.env.RSPACK_TRACE_LAYER, process.env.RSPACK_TRACE_OUTPUT);
|
|
1267
1266
|
}
|
|
1268
1267
|
if (options.watch) item.watch = options.watch;
|
package/dist/index.mjs
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import * as
|
|
3
|
-
import * as
|
|
4
|
-
import * as
|
|
5
|
-
import * as
|
|
6
|
-
import * as
|
|
7
|
-
import * as
|
|
8
|
-
import * as
|
|
1
|
+
import * as __rspack_external_module from "module";
|
|
2
|
+
import * as __rspack_external_node_fs_5ea92f0c from "node:fs";
|
|
3
|
+
import * as __rspack_external_node_path_c5b9b54f from "node:path";
|
|
4
|
+
import * as __rspack_external_path from "path";
|
|
5
|
+
import * as __rspack_external_node_util_1b29d436 from "node:util";
|
|
6
|
+
import * as __rspack_external_events from "events";
|
|
7
|
+
import * as __rspack_external_node_module_ab9f2194 from "node:module";
|
|
8
|
+
import * as __rspack_external_node_url_e96de089 from "node:url";
|
|
9
9
|
var __webpack_modules__ = {
|
|
10
10
|
"../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js": function(module) {
|
|
11
11
|
let p = process || {}, argv = p.argv || [], env = p.env || {};
|
|
@@ -137,20 +137,20 @@ var __webpack_modules__ = {
|
|
|
137
137
|
__webpack_require__.d(__webpack_exports__, {
|
|
138
138
|
Z: ()=>rspack
|
|
139
139
|
});
|
|
140
|
-
const rspackCore_require = (0,
|
|
140
|
+
const rspackCore_require = (0, __rspack_external_node_module_ab9f2194.createRequire)(import.meta.url);
|
|
141
141
|
const rspack = rspackCore_require("@rspack/core");
|
|
142
142
|
},
|
|
143
143
|
module: function(module) {
|
|
144
|
-
module.exports =
|
|
144
|
+
module.exports = __rspack_external_module;
|
|
145
145
|
},
|
|
146
146
|
"node:fs": function(module) {
|
|
147
|
-
module.exports =
|
|
147
|
+
module.exports = __rspack_external_node_fs_5ea92f0c;
|
|
148
148
|
},
|
|
149
149
|
"node:path": function(module) {
|
|
150
|
-
module.exports =
|
|
150
|
+
module.exports = __rspack_external_node_path_c5b9b54f;
|
|
151
151
|
},
|
|
152
152
|
path: function(module) {
|
|
153
|
-
module.exports =
|
|
153
|
+
module.exports = __rspack_external_path;
|
|
154
154
|
}
|
|
155
155
|
};
|
|
156
156
|
var __webpack_module_cache__ = {};
|
|
@@ -553,7 +553,7 @@ class GlobalCommand extends Command {
|
|
|
553
553
|
}
|
|
554
554
|
}
|
|
555
555
|
var __assign = Object.assign;
|
|
556
|
-
class CAC extends
|
|
556
|
+
class CAC extends __rspack_external_events.EventEmitter {
|
|
557
557
|
constructor(name = ""){
|
|
558
558
|
super();
|
|
559
559
|
this.name = name;
|
|
@@ -901,21 +901,29 @@ async function getPreviewConfig(item, options, dir) {
|
|
|
901
901
|
if (Array.isArray(item)) return Promise.all(item.map(internalPreviewConfig));
|
|
902
902
|
return internalPreviewConfig(item);
|
|
903
903
|
}
|
|
904
|
+
const DEFAULT_EXTENSIONS = [
|
|
905
|
+
".js",
|
|
906
|
+
".ts",
|
|
907
|
+
".mjs",
|
|
908
|
+
".mts",
|
|
909
|
+
".cjs",
|
|
910
|
+
".cts"
|
|
911
|
+
];
|
|
904
912
|
function normalizeHotOption(value) {
|
|
905
|
-
if ("boolean" == typeof value || "only" === value) return value;
|
|
906
913
|
if ("false" === value) return false;
|
|
907
|
-
return true;
|
|
914
|
+
if ("true" === value) return true;
|
|
915
|
+
return value;
|
|
908
916
|
}
|
|
909
917
|
class ServeCommand {
|
|
910
918
|
async apply(cli) {
|
|
911
919
|
const command = cli.program.command("serve", "run the rspack dev server.").alias("server").alias("s").alias("dev");
|
|
912
920
|
commonOptionsForBuildAndServe(commonOptions(command)).option("--hot [mode]", "enables hot module replacement").option("--port <port>", "allows to specify a port to use").option("--host <host>", "allows to specify a hostname to use");
|
|
913
|
-
command.action(async (
|
|
914
|
-
setDefaultNodeEnv(
|
|
915
|
-
normalizeCommonOptions(
|
|
916
|
-
|
|
921
|
+
command.action(async (cliOptions)=>{
|
|
922
|
+
setDefaultNodeEnv(cliOptions, "development");
|
|
923
|
+
normalizeCommonOptions(cliOptions, "serve");
|
|
924
|
+
cliOptions.hot = normalizeHotOption(cliOptions.hot);
|
|
917
925
|
const { RspackDevServer } = await import("@rspack/dev-server");
|
|
918
|
-
const compiler = await cli.createCompiler(
|
|
926
|
+
const compiler = await cli.createCompiler(cliOptions, "serve");
|
|
919
927
|
if (!compiler) return;
|
|
920
928
|
const compilers = cli.isMultipleCompiler(compiler) ? compiler.compilers : [
|
|
921
929
|
compiler
|
|
@@ -926,7 +934,7 @@ class ServeCommand {
|
|
|
926
934
|
const compilerForDevServer = possibleCompilers.length > 0 ? possibleCompilers[0] : compilers[0];
|
|
927
935
|
for (const compiler of compilers){
|
|
928
936
|
const devServer = compiler.options.devServer ??= {};
|
|
929
|
-
devServer.hot =
|
|
937
|
+
devServer.hot = cliOptions.hot ?? devServer.hot ?? true;
|
|
930
938
|
if (false !== devServer.client) {
|
|
931
939
|
if (true === devServer.client || null == devServer.client) devServer.client = {};
|
|
932
940
|
devServer.client = {
|
|
@@ -938,10 +946,10 @@ class ServeCommand {
|
|
|
938
946
|
};
|
|
939
947
|
}
|
|
940
948
|
}
|
|
941
|
-
const
|
|
942
|
-
const { setupMiddlewares } =
|
|
949
|
+
const devServerOptions = compilerForDevServer.options.devServer ??= {};
|
|
950
|
+
const { setupMiddlewares } = devServerOptions;
|
|
943
951
|
const lazyCompileMiddleware = rspackCore.Z.experiments.lazyCompilationMiddleware(compiler);
|
|
944
|
-
|
|
952
|
+
devServerOptions.setupMiddlewares = (middlewares, server)=>{
|
|
945
953
|
let finalMiddlewares = middlewares;
|
|
946
954
|
if (setupMiddlewares) finalMiddlewares = setupMiddlewares(finalMiddlewares, server);
|
|
947
955
|
return [
|
|
@@ -949,20 +957,19 @@ class ServeCommand {
|
|
|
949
957
|
lazyCompileMiddleware
|
|
950
958
|
];
|
|
951
959
|
};
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
if (false !==
|
|
956
|
-
if (true ===
|
|
957
|
-
|
|
960
|
+
devServerOptions.hot = cliOptions.hot ?? devServerOptions.hot ?? true;
|
|
961
|
+
devServerOptions.host = cliOptions.host || devServerOptions.host;
|
|
962
|
+
devServerOptions.port = cliOptions.port ?? devServerOptions.port;
|
|
963
|
+
if (false !== devServerOptions.client) {
|
|
964
|
+
if (true === devServerOptions.client || null == devServerOptions.client) devServerOptions.client = {};
|
|
965
|
+
devServerOptions.client = {
|
|
958
966
|
overlay: {
|
|
959
967
|
errors: true,
|
|
960
968
|
warnings: false
|
|
961
969
|
},
|
|
962
|
-
...
|
|
970
|
+
...devServerOptions.client
|
|
963
971
|
};
|
|
964
972
|
}
|
|
965
|
-
const devServerOptions = result;
|
|
966
973
|
if (devServerOptions.port) {
|
|
967
974
|
const portNumber = Number(devServerOptions.port);
|
|
968
975
|
if (!Number.isNaN(portNumber)) {
|
|
@@ -1007,7 +1014,7 @@ const isEsmFile = (filePath)=>{
|
|
|
1007
1014
|
};
|
|
1008
1015
|
const crossImport = async (path)=>{
|
|
1009
1016
|
if (isEsmFile(path)) {
|
|
1010
|
-
const url = (0,
|
|
1017
|
+
const url = (0, __rspack_external_node_url_e96de089.pathToFileURL)(path).href;
|
|
1011
1018
|
const { default: config } = await import(url);
|
|
1012
1019
|
return config;
|
|
1013
1020
|
}
|
|
@@ -1015,14 +1022,6 @@ const crossImport = async (path)=>{
|
|
|
1015
1022
|
if (result && "object" == typeof result && "default" in result) result = result.default || {};
|
|
1016
1023
|
return result;
|
|
1017
1024
|
};
|
|
1018
|
-
const DEFAULT_EXTENSIONS = [
|
|
1019
|
-
".js",
|
|
1020
|
-
".ts",
|
|
1021
|
-
".mjs",
|
|
1022
|
-
".mts",
|
|
1023
|
-
".cjs",
|
|
1024
|
-
".cts"
|
|
1025
|
-
];
|
|
1026
1025
|
const findConfig = (basePath)=>DEFAULT_EXTENSIONS.map((ext)=>basePath + ext).find(external_node_fs_["default"].existsSync);
|
|
1027
1026
|
const utils_findConfig = findConfig;
|
|
1028
1027
|
const TS_EXTENSION = [
|
|
@@ -1175,7 +1174,7 @@ class RspackCLI {
|
|
|
1175
1174
|
this.colors = this.createColors();
|
|
1176
1175
|
this.program = program;
|
|
1177
1176
|
program.help();
|
|
1178
|
-
program.version("1.6.
|
|
1177
|
+
program.version("1.6.6");
|
|
1179
1178
|
}
|
|
1180
1179
|
async createCompiler(options, rspackCommand, callback) {
|
|
1181
1180
|
let { config, pathMap } = await this.loadConfig(options);
|
|
@@ -1207,7 +1206,7 @@ class RspackCLI {
|
|
|
1207
1206
|
}
|
|
1208
1207
|
getLogger() {
|
|
1209
1208
|
return {
|
|
1210
|
-
error: (val)=>console.error(`[rspack-cli] ${this.colors.red(
|
|
1209
|
+
error: (val)=>console.error(`[rspack-cli] ${this.colors.red(__rspack_external_node_util_1b29d436["default"].format(val))}`),
|
|
1211
1210
|
warn: (val)=>console.warn(`[rspack-cli] ${this.colors.yellow(val)}`),
|
|
1212
1211
|
info: (val)=>console.info(`[rspack-cli] ${this.colors.cyan(val)}`),
|
|
1213
1212
|
success: (val)=>console.log(`[rspack-cli] ${this.colors.green(val)}`),
|
|
@@ -1249,7 +1248,7 @@ class RspackCLI {
|
|
|
1249
1248
|
}
|
|
1250
1249
|
if (options.profile) item.profile = true;
|
|
1251
1250
|
if (process.env.RSPACK_PROFILE) {
|
|
1252
|
-
const { applyProfile } = await __webpack_require__.e("
|
|
1251
|
+
const { applyProfile } = await __webpack_require__.e("274").then(__webpack_require__.bind(__webpack_require__, "./src/utils/profile.ts"));
|
|
1253
1252
|
await applyProfile(process.env.RSPACK_PROFILE, process.env.RSPACK_TRACE_LAYER, process.env.RSPACK_TRACE_OUTPUT);
|
|
1254
1253
|
}
|
|
1255
1254
|
if (options.watch) item.watch = options.watch;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rspack/cli",
|
|
3
|
-
"version": "1.6.
|
|
3
|
+
"version": "1.6.6",
|
|
4
4
|
"description": "CLI for rspack",
|
|
5
5
|
"homepage": "https://rspack.rs",
|
|
6
6
|
"bugs": "https://github.com/web-infra-dev/rspack/issues",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"webpack-bundle-analyzer": "4.10.2"
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
|
-
"@rslib/core": "0.
|
|
37
|
+
"@rslib/core": "0.18.2",
|
|
38
38
|
"@types/webpack-bundle-analyzer": "^4.7.0",
|
|
39
39
|
"cac": "^6.7.14",
|
|
40
40
|
"concat-stream": "^2.0.0",
|
|
@@ -44,8 +44,8 @@
|
|
|
44
44
|
"pirates": "^4.0.7",
|
|
45
45
|
"ts-node": "^10.9.2",
|
|
46
46
|
"typescript": "^5.9.3",
|
|
47
|
-
"@rspack/core": "1.6.
|
|
48
|
-
"@rspack/test-tools": "1.6.
|
|
47
|
+
"@rspack/core": "1.6.6",
|
|
48
|
+
"@rspack/test-tools": "1.6.6"
|
|
49
49
|
},
|
|
50
50
|
"peerDependencies": {
|
|
51
51
|
"@rspack/core": "^1.0.0-alpha || ^1.x"
|