@modern-js/repo-generator 1.2.6 → 1.3.2
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/js/node/main.js +2470 -946
- package/package.json +15 -13
package/dist/js/node/main.js
CHANGED
@@ -9,7 +9,7 @@ module.exports = __webpack_require__(75339);
|
|
9
9
|
|
10
10
|
/***/ }),
|
11
11
|
|
12
|
-
/***/
|
12
|
+
/***/ 49547:
|
13
13
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
14
14
|
|
15
15
|
"use strict";
|
@@ -24,7 +24,7 @@ var _easyFormCli = __webpack_require__(62408);
|
|
24
24
|
|
25
25
|
var _inquirerTypes = __webpack_require__(78659);
|
26
26
|
|
27
|
-
var _constant = __webpack_require__(
|
27
|
+
var _constant = __webpack_require__(82409);
|
28
28
|
|
29
29
|
const registerListPrompt = inquirer => {
|
30
30
|
try {
|
@@ -108,7 +108,7 @@ exports.listNode = listNode;
|
|
108
108
|
|
109
109
|
/***/ }),
|
110
110
|
|
111
|
-
/***/
|
111
|
+
/***/ 82409:
|
112
112
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
113
113
|
|
114
114
|
"use strict";
|
@@ -133,7 +133,7 @@ exports.CLI_TYPE = CLI_TYPE;
|
|
133
133
|
|
134
134
|
/***/ }),
|
135
135
|
|
136
|
-
/***/
|
136
|
+
/***/ 96354:
|
137
137
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
138
138
|
|
139
139
|
"use strict";
|
@@ -143,7 +143,7 @@ Object.defineProperty(exports, "__esModule", ({
|
|
143
143
|
value: true
|
144
144
|
}));
|
145
145
|
|
146
|
-
var _ListNode = __webpack_require__(
|
146
|
+
var _ListNode = __webpack_require__(49547);
|
147
147
|
|
148
148
|
Object.keys(_ListNode).forEach(function (key) {
|
149
149
|
if (key === "default" || key === "__esModule") return;
|
@@ -158,7 +158,7 @@ Object.keys(_ListNode).forEach(function (key) {
|
|
158
158
|
|
159
159
|
/***/ }),
|
160
160
|
|
161
|
-
/***/
|
161
|
+
/***/ 80355:
|
162
162
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
163
163
|
|
164
164
|
"use strict";
|
@@ -183,7 +183,7 @@ Object.defineProperty(exports, "transformSchema", ({
|
|
183
183
|
|
184
184
|
var _merge2 = _interopRequireDefault(__webpack_require__(13904));
|
185
185
|
|
186
|
-
var _fsExtra = _interopRequireDefault(__webpack_require__(
|
186
|
+
var _fsExtra = _interopRequireDefault(__webpack_require__(83950));
|
187
187
|
|
188
188
|
var _semver = _interopRequireDefault(__webpack_require__(20962));
|
189
189
|
|
@@ -199,11 +199,11 @@ var _codesmithApiHandlebars = __webpack_require__(12291);
|
|
199
199
|
|
200
200
|
var _easyFormCli = __webpack_require__(62408);
|
201
201
|
|
202
|
-
var _transformSchema = __webpack_require__(
|
202
|
+
var _transformSchema = __webpack_require__(90115);
|
203
203
|
|
204
|
-
var handlers = _interopRequireWildcard(__webpack_require__(
|
204
|
+
var handlers = _interopRequireWildcard(__webpack_require__(96354));
|
205
205
|
|
206
|
-
var _locale = __webpack_require__(
|
206
|
+
var _locale = __webpack_require__(88506);
|
207
207
|
|
208
208
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
209
209
|
|
@@ -240,9 +240,9 @@ class AppAPI {
|
|
240
240
|
return false;
|
241
241
|
}
|
242
242
|
|
243
|
-
if (!(await (0, _codesmithApiNpm.canUseYarn)()) && !(await (0, _codesmithApiNpm.canUsePnpm)())) {
|
244
|
-
this.generatorCore.logger.debug("can't use yarn or pnpm");
|
245
|
-
this.generatorCore.logger.warn(_locale.i18n.t(_locale.localeKeys.environment.
|
243
|
+
if (!(await (0, _codesmithApiNpm.canUseYarn)()) && !(await (0, _codesmithApiNpm.canUsePnpm)()) && !(await (0, _codesmithApiNpm.canUseNpm)())) {
|
244
|
+
this.generatorCore.logger.debug("can't use yarn or pnpm or npm");
|
245
|
+
this.generatorCore.logger.warn(_locale.i18n.t(_locale.localeKeys.environment.yarn_pnpm_npm));
|
246
246
|
return false;
|
247
247
|
}
|
248
248
|
|
@@ -418,7 +418,7 @@ exports.AppAPI = AppAPI;
|
|
418
418
|
|
419
419
|
/***/ }),
|
420
420
|
|
421
|
-
/***/
|
421
|
+
/***/ 5664:
|
422
422
|
/***/ ((__unused_webpack_module, exports) => {
|
423
423
|
|
424
424
|
"use strict";
|
@@ -432,7 +432,7 @@ const EN_LOCALE = {
|
|
432
432
|
environment: {
|
433
433
|
node_version: 'please upgrade node to lts version',
|
434
434
|
nvm_install: 'please install nvm first',
|
435
|
-
|
435
|
+
yarn_pnpm_npm: 'please install yarn or pnpm or npm first'
|
436
436
|
},
|
437
437
|
install: {
|
438
438
|
failed: 'dependencies install failed, please execute `{command}` to install the dependencies ',
|
@@ -457,7 +457,7 @@ exports.EN_LOCALE = EN_LOCALE;
|
|
457
457
|
|
458
458
|
/***/ }),
|
459
459
|
|
460
|
-
/***/
|
460
|
+
/***/ 88506:
|
461
461
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
462
462
|
|
463
463
|
"use strict";
|
@@ -474,11 +474,11 @@ Object.defineProperty(exports, "I18n", ({
|
|
474
474
|
}));
|
475
475
|
exports.localeKeys = exports.i18n = void 0;
|
476
476
|
|
477
|
-
var _pluginI18n = __webpack_require__(
|
477
|
+
var _pluginI18n = __webpack_require__(54207);
|
478
478
|
|
479
|
-
var _zh = __webpack_require__(
|
479
|
+
var _zh = __webpack_require__(12214);
|
480
480
|
|
481
|
-
var _en = __webpack_require__(
|
481
|
+
var _en = __webpack_require__(5664);
|
482
482
|
|
483
483
|
const i18n = new _pluginI18n.I18n();
|
484
484
|
exports.i18n = i18n;
|
@@ -490,7 +490,7 @@ exports.localeKeys = localeKeys;
|
|
490
490
|
|
491
491
|
/***/ }),
|
492
492
|
|
493
|
-
/***/
|
493
|
+
/***/ 12214:
|
494
494
|
/***/ ((__unused_webpack_module, exports) => {
|
495
495
|
|
496
496
|
"use strict";
|
@@ -504,7 +504,7 @@ const ZH_LOCALE = {
|
|
504
504
|
environment: {
|
505
505
|
node_version: '请升级 Node 版本至 LIS',
|
506
506
|
nvm_install: '检测到环境中未安装 nvm,请先安装 nvm',
|
507
|
-
|
507
|
+
yarn_pnpm_npm: '检测到环境中未安装包管理工具,请先安装 yarn 或 pnpm 或 npm'
|
508
508
|
},
|
509
509
|
install: {
|
510
510
|
failed: '依赖自动安装失败,请手动执行 `{command}` 命令进行安装',
|
@@ -529,7 +529,7 @@ exports.ZH_LOCALE = ZH_LOCALE;
|
|
529
529
|
|
530
530
|
/***/ }),
|
531
531
|
|
532
|
-
/***/
|
532
|
+
/***/ 90115:
|
533
533
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
534
534
|
|
535
535
|
"use strict";
|
@@ -1267,7 +1267,7 @@ var _ora = _interopRequireDefault(__webpack_require__(60483));
|
|
1267
1267
|
|
1268
1268
|
var _chalk = _interopRequireDefault(__webpack_require__(9834));
|
1269
1269
|
|
1270
|
-
var _fsExtra = _interopRequireDefault(__webpack_require__(
|
1270
|
+
var _fsExtra = _interopRequireDefault(__webpack_require__(83950));
|
1271
1271
|
|
1272
1272
|
var _FsMaterial = __webpack_require__(77410);
|
1273
1273
|
|
@@ -1786,7 +1786,7 @@ exports.FsResource = exports.FS_RESOURCE = void 0;
|
|
1786
1786
|
|
1787
1787
|
var _path = _interopRequireDefault(__webpack_require__(71017));
|
1788
1788
|
|
1789
|
-
var _fsExtra = _interopRequireDefault(__webpack_require__(
|
1789
|
+
var _fsExtra = _interopRequireDefault(__webpack_require__(83950));
|
1790
1790
|
|
1791
1791
|
var _constants = __webpack_require__(97578);
|
1792
1792
|
|
@@ -1914,7 +1914,7 @@ exports.downloadPackage = downloadPackage;
|
|
1914
1914
|
|
1915
1915
|
var _os = _interopRequireDefault(__webpack_require__(22037));
|
1916
1916
|
|
1917
|
-
var _fsExtra = _interopRequireDefault(__webpack_require__(
|
1917
|
+
var _fsExtra = _interopRequireDefault(__webpack_require__(83950));
|
1918
1918
|
|
1919
1919
|
var _axios = _interopRequireDefault(__webpack_require__(45114));
|
1920
1920
|
|
@@ -2059,7 +2059,7 @@ Object.defineProperty(exports, "__esModule", ({
|
|
2059
2059
|
}));
|
2060
2060
|
exports.fsExists = fsExists;
|
2061
2061
|
|
2062
|
-
var _fsExtra = _interopRequireDefault(__webpack_require__(
|
2062
|
+
var _fsExtra = _interopRequireDefault(__webpack_require__(83950));
|
2063
2063
|
|
2064
2064
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
2065
2065
|
|
@@ -2092,7 +2092,7 @@ exports.getGeneratorDir = getGeneratorDir;
|
|
2092
2092
|
|
2093
2093
|
var _path = _interopRequireDefault(__webpack_require__(71017));
|
2094
2094
|
|
2095
|
-
var _fsExtra = _interopRequireDefault(__webpack_require__(
|
2095
|
+
var _fsExtra = _interopRequireDefault(__webpack_require__(83950));
|
2096
2096
|
|
2097
2097
|
var _fsExists = __webpack_require__(88129);
|
2098
2098
|
|
@@ -2404,7 +2404,7 @@ var _path = _interopRequireDefault(__webpack_require__(71017));
|
|
2404
2404
|
|
2405
2405
|
var _execa = _interopRequireDefault(__webpack_require__(16228));
|
2406
2406
|
|
2407
|
-
var _fsExtra = _interopRequireDefault(__webpack_require__(
|
2407
|
+
var _fsExtra = _interopRequireDefault(__webpack_require__(83950));
|
2408
2408
|
|
2409
2409
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
2410
2410
|
|
@@ -5604,22 +5604,7 @@ exports.pointer = pointer;
|
|
5604
5604
|
|
5605
5605
|
/***/ }),
|
5606
5606
|
|
5607
|
-
/***/
|
5608
|
-
/***/ ((module) => {
|
5609
|
-
|
5610
|
-
function webpackEmptyContext(req) {
|
5611
|
-
var e = new Error("Cannot find module '" + req + "'");
|
5612
|
-
e.code = 'MODULE_NOT_FOUND';
|
5613
|
-
throw e;
|
5614
|
-
}
|
5615
|
-
webpackEmptyContext.keys = () => ([]);
|
5616
|
-
webpackEmptyContext.resolve = webpackEmptyContext;
|
5617
|
-
webpackEmptyContext.id = 28119;
|
5618
|
-
module.exports = webpackEmptyContext;
|
5619
|
-
|
5620
|
-
/***/ }),
|
5621
|
-
|
5622
|
-
/***/ 80539:
|
5607
|
+
/***/ 54207:
|
5623
5608
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
5624
5609
|
|
5625
5610
|
"use strict";
|
@@ -5632,7 +5617,7 @@ exports.I18n = void 0;
|
|
5632
5617
|
|
5633
5618
|
var _get2 = _interopRequireDefault(__webpack_require__(71189));
|
5634
5619
|
|
5635
|
-
var _utils = __webpack_require__(
|
5620
|
+
var _utils = __webpack_require__(41083);
|
5636
5621
|
|
5637
5622
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
5638
5623
|
|
@@ -5701,7 +5686,7 @@ exports.I18n = I18n;
|
|
5701
5686
|
|
5702
5687
|
/***/ }),
|
5703
5688
|
|
5704
|
-
/***/
|
5689
|
+
/***/ 41083:
|
5705
5690
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
5706
5691
|
|
5707
5692
|
"use strict";
|
@@ -31952,186 +31937,2186 @@ RedirectableRequest.prototype._processResponse = function (response) {
|
|
31952
31937
|
var redirectUrlParts = url.parse(redirectUrl);
|
31953
31938
|
Object.assign(this._options, redirectUrlParts);
|
31954
31939
|
|
31955
|
-
// Drop the confidential headers when redirecting to another domain
|
31956
|
-
if (!(redirectUrlParts.host === currentHost || isSubdomainOf(redirectUrlParts.host, currentHost))) {
|
31957
|
-
removeMatchingHeaders(/^(?:authorization|cookie)$/i, this._options.headers);
|
31940
|
+
// Drop the confidential headers when redirecting to another domain
|
31941
|
+
if (!(redirectUrlParts.host === currentHost || isSubdomainOf(redirectUrlParts.host, currentHost))) {
|
31942
|
+
removeMatchingHeaders(/^(?:authorization|cookie)$/i, this._options.headers);
|
31943
|
+
}
|
31944
|
+
|
31945
|
+
// Evaluate the beforeRedirect callback
|
31946
|
+
if (typeof this._options.beforeRedirect === "function") {
|
31947
|
+
var responseDetails = { headers: response.headers };
|
31948
|
+
try {
|
31949
|
+
this._options.beforeRedirect.call(null, this._options, responseDetails);
|
31950
|
+
}
|
31951
|
+
catch (err) {
|
31952
|
+
this.emit("error", err);
|
31953
|
+
return;
|
31954
|
+
}
|
31955
|
+
this._sanitizeOptions(this._options);
|
31956
|
+
}
|
31957
|
+
|
31958
|
+
// Perform the redirected request
|
31959
|
+
try {
|
31960
|
+
this._performRequest();
|
31961
|
+
}
|
31962
|
+
catch (cause) {
|
31963
|
+
this.emit("error", new RedirectionError(cause));
|
31964
|
+
}
|
31965
|
+
}
|
31966
|
+
else {
|
31967
|
+
// The response is not a redirect; return it as-is
|
31968
|
+
response.responseUrl = this._currentUrl;
|
31969
|
+
response.redirects = this._redirects;
|
31970
|
+
this.emit("response", response);
|
31971
|
+
|
31972
|
+
// Clean up
|
31973
|
+
this._requestBodyBuffers = [];
|
31974
|
+
}
|
31975
|
+
};
|
31976
|
+
|
31977
|
+
// Wraps the key/value object of protocols with redirect functionality
|
31978
|
+
function wrap(protocols) {
|
31979
|
+
// Default settings
|
31980
|
+
var exports = {
|
31981
|
+
maxRedirects: 21,
|
31982
|
+
maxBodyLength: 10 * 1024 * 1024,
|
31983
|
+
};
|
31984
|
+
|
31985
|
+
// Wrap each protocol
|
31986
|
+
var nativeProtocols = {};
|
31987
|
+
Object.keys(protocols).forEach(function (scheme) {
|
31988
|
+
var protocol = scheme + ":";
|
31989
|
+
var nativeProtocol = nativeProtocols[protocol] = protocols[scheme];
|
31990
|
+
var wrappedProtocol = exports[scheme] = Object.create(nativeProtocol);
|
31991
|
+
|
31992
|
+
// Executes a request, following redirects
|
31993
|
+
function request(input, options, callback) {
|
31994
|
+
// Parse parameters
|
31995
|
+
if (typeof input === "string") {
|
31996
|
+
var urlStr = input;
|
31997
|
+
try {
|
31998
|
+
input = urlToOptions(new URL(urlStr));
|
31999
|
+
}
|
32000
|
+
catch (err) {
|
32001
|
+
/* istanbul ignore next */
|
32002
|
+
input = url.parse(urlStr);
|
32003
|
+
}
|
32004
|
+
}
|
32005
|
+
else if (URL && (input instanceof URL)) {
|
32006
|
+
input = urlToOptions(input);
|
32007
|
+
}
|
32008
|
+
else {
|
32009
|
+
callback = options;
|
32010
|
+
options = input;
|
32011
|
+
input = { protocol: protocol };
|
32012
|
+
}
|
32013
|
+
if (typeof options === "function") {
|
32014
|
+
callback = options;
|
32015
|
+
options = null;
|
32016
|
+
}
|
32017
|
+
|
32018
|
+
// Set defaults
|
32019
|
+
options = Object.assign({
|
32020
|
+
maxRedirects: exports.maxRedirects,
|
32021
|
+
maxBodyLength: exports.maxBodyLength,
|
32022
|
+
}, input, options);
|
32023
|
+
options.nativeProtocols = nativeProtocols;
|
32024
|
+
|
32025
|
+
assert.equal(options.protocol, protocol, "protocol mismatch");
|
32026
|
+
debug("options", options);
|
32027
|
+
return new RedirectableRequest(options, callback);
|
32028
|
+
}
|
32029
|
+
|
32030
|
+
// Executes a GET request, following redirects
|
32031
|
+
function get(input, options, callback) {
|
32032
|
+
var wrappedRequest = wrappedProtocol.request(input, options, callback);
|
32033
|
+
wrappedRequest.end();
|
32034
|
+
return wrappedRequest;
|
32035
|
+
}
|
32036
|
+
|
32037
|
+
// Expose the properties on the wrapped protocol
|
32038
|
+
Object.defineProperties(wrappedProtocol, {
|
32039
|
+
request: { value: request, configurable: true, enumerable: true, writable: true },
|
32040
|
+
get: { value: get, configurable: true, enumerable: true, writable: true },
|
32041
|
+
});
|
32042
|
+
});
|
32043
|
+
return exports;
|
32044
|
+
}
|
32045
|
+
|
32046
|
+
/* istanbul ignore next */
|
32047
|
+
function noop() { /* empty */ }
|
32048
|
+
|
32049
|
+
// from https://github.com/nodejs/node/blob/master/lib/internal/url.js
|
32050
|
+
function urlToOptions(urlObject) {
|
32051
|
+
var options = {
|
32052
|
+
protocol: urlObject.protocol,
|
32053
|
+
hostname: urlObject.hostname.startsWith("[") ?
|
32054
|
+
/* istanbul ignore next */
|
32055
|
+
urlObject.hostname.slice(1, -1) :
|
32056
|
+
urlObject.hostname,
|
32057
|
+
hash: urlObject.hash,
|
32058
|
+
search: urlObject.search,
|
32059
|
+
pathname: urlObject.pathname,
|
32060
|
+
path: urlObject.pathname + urlObject.search,
|
32061
|
+
href: urlObject.href,
|
32062
|
+
};
|
32063
|
+
if (urlObject.port !== "") {
|
32064
|
+
options.port = Number(urlObject.port);
|
32065
|
+
}
|
32066
|
+
return options;
|
32067
|
+
}
|
32068
|
+
|
32069
|
+
function removeMatchingHeaders(regex, headers) {
|
32070
|
+
var lastValue;
|
32071
|
+
for (var header in headers) {
|
32072
|
+
if (regex.test(header)) {
|
32073
|
+
lastValue = headers[header];
|
32074
|
+
delete headers[header];
|
32075
|
+
}
|
32076
|
+
}
|
32077
|
+
return (lastValue === null || typeof lastValue === "undefined") ?
|
32078
|
+
undefined : String(lastValue).trim();
|
32079
|
+
}
|
32080
|
+
|
32081
|
+
function createErrorType(code, defaultMessage) {
|
32082
|
+
function CustomError(cause) {
|
32083
|
+
Error.captureStackTrace(this, this.constructor);
|
32084
|
+
if (!cause) {
|
32085
|
+
this.message = defaultMessage;
|
32086
|
+
}
|
32087
|
+
else {
|
32088
|
+
this.message = defaultMessage + ": " + cause.message;
|
32089
|
+
this.cause = cause;
|
32090
|
+
}
|
32091
|
+
}
|
32092
|
+
CustomError.prototype = new Error();
|
32093
|
+
CustomError.prototype.constructor = CustomError;
|
32094
|
+
CustomError.prototype.name = "Error [" + code + "]";
|
32095
|
+
CustomError.prototype.code = code;
|
32096
|
+
return CustomError;
|
32097
|
+
}
|
32098
|
+
|
32099
|
+
function abortRequest(request) {
|
32100
|
+
for (var e = 0; e < events.length; e++) {
|
32101
|
+
request.removeListener(events[e], eventHandlers[events[e]]);
|
32102
|
+
}
|
32103
|
+
request.on("error", noop);
|
32104
|
+
request.abort();
|
32105
|
+
}
|
32106
|
+
|
32107
|
+
function isSubdomainOf(subdomain, domain) {
|
32108
|
+
const dot = subdomain.length - domain.length - 1;
|
32109
|
+
return dot > 0 && subdomain[dot] === "." && subdomain.endsWith(domain);
|
32110
|
+
}
|
32111
|
+
|
32112
|
+
// Exports
|
32113
|
+
module.exports = wrap({ http: http, https: https });
|
32114
|
+
module.exports.wrap = wrap;
|
32115
|
+
|
32116
|
+
|
32117
|
+
/***/ }),
|
32118
|
+
|
32119
|
+
/***/ 74714:
|
32120
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32121
|
+
|
32122
|
+
"use strict";
|
32123
|
+
|
32124
|
+
|
32125
|
+
const fs = __webpack_require__(62204)
|
32126
|
+
const path = __webpack_require__(71017)
|
32127
|
+
const mkdirsSync = (__webpack_require__(17433).mkdirsSync)
|
32128
|
+
const utimesMillisSync = (__webpack_require__(16333).utimesMillisSync)
|
32129
|
+
const stat = __webpack_require__(31197)
|
32130
|
+
|
32131
|
+
function copySync (src, dest, opts) {
|
32132
|
+
if (typeof opts === 'function') {
|
32133
|
+
opts = { filter: opts }
|
32134
|
+
}
|
32135
|
+
|
32136
|
+
opts = opts || {}
|
32137
|
+
opts.clobber = 'clobber' in opts ? !!opts.clobber : true // default to true for now
|
32138
|
+
opts.overwrite = 'overwrite' in opts ? !!opts.overwrite : opts.clobber // overwrite falls back to clobber
|
32139
|
+
|
32140
|
+
// Warn about using preserveTimestamps on 32-bit node
|
32141
|
+
if (opts.preserveTimestamps && process.arch === 'ia32') {
|
32142
|
+
console.warn(`fs-extra: Using the preserveTimestamps option in 32-bit node is not recommended;\n
|
32143
|
+
see https://github.com/jprichardson/node-fs-extra/issues/269`)
|
32144
|
+
}
|
32145
|
+
|
32146
|
+
const { srcStat, destStat } = stat.checkPathsSync(src, dest, 'copy', opts)
|
32147
|
+
stat.checkParentPathsSync(src, srcStat, dest, 'copy')
|
32148
|
+
return handleFilterAndCopy(destStat, src, dest, opts)
|
32149
|
+
}
|
32150
|
+
|
32151
|
+
function handleFilterAndCopy (destStat, src, dest, opts) {
|
32152
|
+
if (opts.filter && !opts.filter(src, dest)) return
|
32153
|
+
const destParent = path.dirname(dest)
|
32154
|
+
if (!fs.existsSync(destParent)) mkdirsSync(destParent)
|
32155
|
+
return getStats(destStat, src, dest, opts)
|
32156
|
+
}
|
32157
|
+
|
32158
|
+
function startCopy (destStat, src, dest, opts) {
|
32159
|
+
if (opts.filter && !opts.filter(src, dest)) return
|
32160
|
+
return getStats(destStat, src, dest, opts)
|
32161
|
+
}
|
32162
|
+
|
32163
|
+
function getStats (destStat, src, dest, opts) {
|
32164
|
+
const statSync = opts.dereference ? fs.statSync : fs.lstatSync
|
32165
|
+
const srcStat = statSync(src)
|
32166
|
+
|
32167
|
+
if (srcStat.isDirectory()) return onDir(srcStat, destStat, src, dest, opts)
|
32168
|
+
else if (srcStat.isFile() ||
|
32169
|
+
srcStat.isCharacterDevice() ||
|
32170
|
+
srcStat.isBlockDevice()) return onFile(srcStat, destStat, src, dest, opts)
|
32171
|
+
else if (srcStat.isSymbolicLink()) return onLink(destStat, src, dest, opts)
|
32172
|
+
else if (srcStat.isSocket()) throw new Error(`Cannot copy a socket file: ${src}`)
|
32173
|
+
else if (srcStat.isFIFO()) throw new Error(`Cannot copy a FIFO pipe: ${src}`)
|
32174
|
+
throw new Error(`Unknown file: ${src}`)
|
32175
|
+
}
|
32176
|
+
|
32177
|
+
function onFile (srcStat, destStat, src, dest, opts) {
|
32178
|
+
if (!destStat) return copyFile(srcStat, src, dest, opts)
|
32179
|
+
return mayCopyFile(srcStat, src, dest, opts)
|
32180
|
+
}
|
32181
|
+
|
32182
|
+
function mayCopyFile (srcStat, src, dest, opts) {
|
32183
|
+
if (opts.overwrite) {
|
32184
|
+
fs.unlinkSync(dest)
|
32185
|
+
return copyFile(srcStat, src, dest, opts)
|
32186
|
+
} else if (opts.errorOnExist) {
|
32187
|
+
throw new Error(`'${dest}' already exists`)
|
32188
|
+
}
|
32189
|
+
}
|
32190
|
+
|
32191
|
+
function copyFile (srcStat, src, dest, opts) {
|
32192
|
+
fs.copyFileSync(src, dest)
|
32193
|
+
if (opts.preserveTimestamps) handleTimestamps(srcStat.mode, src, dest)
|
32194
|
+
return setDestMode(dest, srcStat.mode)
|
32195
|
+
}
|
32196
|
+
|
32197
|
+
function handleTimestamps (srcMode, src, dest) {
|
32198
|
+
// Make sure the file is writable before setting the timestamp
|
32199
|
+
// otherwise open fails with EPERM when invoked with 'r+'
|
32200
|
+
// (through utimes call)
|
32201
|
+
if (fileIsNotWritable(srcMode)) makeFileWritable(dest, srcMode)
|
32202
|
+
return setDestTimestamps(src, dest)
|
32203
|
+
}
|
32204
|
+
|
32205
|
+
function fileIsNotWritable (srcMode) {
|
32206
|
+
return (srcMode & 0o200) === 0
|
32207
|
+
}
|
32208
|
+
|
32209
|
+
function makeFileWritable (dest, srcMode) {
|
32210
|
+
return setDestMode(dest, srcMode | 0o200)
|
32211
|
+
}
|
32212
|
+
|
32213
|
+
function setDestMode (dest, srcMode) {
|
32214
|
+
return fs.chmodSync(dest, srcMode)
|
32215
|
+
}
|
32216
|
+
|
32217
|
+
function setDestTimestamps (src, dest) {
|
32218
|
+
// The initial srcStat.atime cannot be trusted
|
32219
|
+
// because it is modified by the read(2) system call
|
32220
|
+
// (See https://nodejs.org/api/fs.html#fs_stat_time_values)
|
32221
|
+
const updatedSrcStat = fs.statSync(src)
|
32222
|
+
return utimesMillisSync(dest, updatedSrcStat.atime, updatedSrcStat.mtime)
|
32223
|
+
}
|
32224
|
+
|
32225
|
+
function onDir (srcStat, destStat, src, dest, opts) {
|
32226
|
+
if (!destStat) return mkDirAndCopy(srcStat.mode, src, dest, opts)
|
32227
|
+
return copyDir(src, dest, opts)
|
32228
|
+
}
|
32229
|
+
|
32230
|
+
function mkDirAndCopy (srcMode, src, dest, opts) {
|
32231
|
+
fs.mkdirSync(dest)
|
32232
|
+
copyDir(src, dest, opts)
|
32233
|
+
return setDestMode(dest, srcMode)
|
32234
|
+
}
|
32235
|
+
|
32236
|
+
function copyDir (src, dest, opts) {
|
32237
|
+
fs.readdirSync(src).forEach(item => copyDirItem(item, src, dest, opts))
|
32238
|
+
}
|
32239
|
+
|
32240
|
+
function copyDirItem (item, src, dest, opts) {
|
32241
|
+
const srcItem = path.join(src, item)
|
32242
|
+
const destItem = path.join(dest, item)
|
32243
|
+
const { destStat } = stat.checkPathsSync(srcItem, destItem, 'copy', opts)
|
32244
|
+
return startCopy(destStat, srcItem, destItem, opts)
|
32245
|
+
}
|
32246
|
+
|
32247
|
+
function onLink (destStat, src, dest, opts) {
|
32248
|
+
let resolvedSrc = fs.readlinkSync(src)
|
32249
|
+
if (opts.dereference) {
|
32250
|
+
resolvedSrc = path.resolve(process.cwd(), resolvedSrc)
|
32251
|
+
}
|
32252
|
+
|
32253
|
+
if (!destStat) {
|
32254
|
+
return fs.symlinkSync(resolvedSrc, dest)
|
32255
|
+
} else {
|
32256
|
+
let resolvedDest
|
32257
|
+
try {
|
32258
|
+
resolvedDest = fs.readlinkSync(dest)
|
32259
|
+
} catch (err) {
|
32260
|
+
// dest exists and is a regular file or directory,
|
32261
|
+
// Windows may throw UNKNOWN error. If dest already exists,
|
32262
|
+
// fs throws error anyway, so no need to guard against it here.
|
32263
|
+
if (err.code === 'EINVAL' || err.code === 'UNKNOWN') return fs.symlinkSync(resolvedSrc, dest)
|
32264
|
+
throw err
|
32265
|
+
}
|
32266
|
+
if (opts.dereference) {
|
32267
|
+
resolvedDest = path.resolve(process.cwd(), resolvedDest)
|
32268
|
+
}
|
32269
|
+
if (stat.isSrcSubdir(resolvedSrc, resolvedDest)) {
|
32270
|
+
throw new Error(`Cannot copy '${resolvedSrc}' to a subdirectory of itself, '${resolvedDest}'.`)
|
32271
|
+
}
|
32272
|
+
|
32273
|
+
// prevent copy if src is a subdir of dest since unlinking
|
32274
|
+
// dest in this case would result in removing src contents
|
32275
|
+
// and therefore a broken symlink would be created.
|
32276
|
+
if (fs.statSync(dest).isDirectory() && stat.isSrcSubdir(resolvedDest, resolvedSrc)) {
|
32277
|
+
throw new Error(`Cannot overwrite '${resolvedDest}' with '${resolvedSrc}'.`)
|
32278
|
+
}
|
32279
|
+
return copyLink(resolvedSrc, dest)
|
32280
|
+
}
|
32281
|
+
}
|
32282
|
+
|
32283
|
+
function copyLink (resolvedSrc, dest) {
|
32284
|
+
fs.unlinkSync(dest)
|
32285
|
+
return fs.symlinkSync(resolvedSrc, dest)
|
32286
|
+
}
|
32287
|
+
|
32288
|
+
module.exports = copySync
|
32289
|
+
|
32290
|
+
|
32291
|
+
/***/ }),
|
32292
|
+
|
32293
|
+
/***/ 55391:
|
32294
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32295
|
+
|
32296
|
+
"use strict";
|
32297
|
+
|
32298
|
+
|
32299
|
+
module.exports = {
|
32300
|
+
copySync: __webpack_require__(74714)
|
32301
|
+
}
|
32302
|
+
|
32303
|
+
|
32304
|
+
/***/ }),
|
32305
|
+
|
32306
|
+
/***/ 77544:
|
32307
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32308
|
+
|
32309
|
+
"use strict";
|
32310
|
+
|
32311
|
+
|
32312
|
+
const fs = __webpack_require__(62204)
|
32313
|
+
const path = __webpack_require__(71017)
|
32314
|
+
const mkdirs = (__webpack_require__(17433).mkdirs)
|
32315
|
+
const pathExists = (__webpack_require__(84906).pathExists)
|
32316
|
+
const utimesMillis = (__webpack_require__(16333).utimesMillis)
|
32317
|
+
const stat = __webpack_require__(31197)
|
32318
|
+
|
32319
|
+
function copy (src, dest, opts, cb) {
|
32320
|
+
if (typeof opts === 'function' && !cb) {
|
32321
|
+
cb = opts
|
32322
|
+
opts = {}
|
32323
|
+
} else if (typeof opts === 'function') {
|
32324
|
+
opts = { filter: opts }
|
32325
|
+
}
|
32326
|
+
|
32327
|
+
cb = cb || function () {}
|
32328
|
+
opts = opts || {}
|
32329
|
+
|
32330
|
+
opts.clobber = 'clobber' in opts ? !!opts.clobber : true // default to true for now
|
32331
|
+
opts.overwrite = 'overwrite' in opts ? !!opts.overwrite : opts.clobber // overwrite falls back to clobber
|
32332
|
+
|
32333
|
+
// Warn about using preserveTimestamps on 32-bit node
|
32334
|
+
if (opts.preserveTimestamps && process.arch === 'ia32') {
|
32335
|
+
console.warn(`fs-extra: Using the preserveTimestamps option in 32-bit node is not recommended;\n
|
32336
|
+
see https://github.com/jprichardson/node-fs-extra/issues/269`)
|
32337
|
+
}
|
32338
|
+
|
32339
|
+
stat.checkPaths(src, dest, 'copy', opts, (err, stats) => {
|
32340
|
+
if (err) return cb(err)
|
32341
|
+
const { srcStat, destStat } = stats
|
32342
|
+
stat.checkParentPaths(src, srcStat, dest, 'copy', err => {
|
32343
|
+
if (err) return cb(err)
|
32344
|
+
if (opts.filter) return handleFilter(checkParentDir, destStat, src, dest, opts, cb)
|
32345
|
+
return checkParentDir(destStat, src, dest, opts, cb)
|
32346
|
+
})
|
32347
|
+
})
|
32348
|
+
}
|
32349
|
+
|
32350
|
+
function checkParentDir (destStat, src, dest, opts, cb) {
|
32351
|
+
const destParent = path.dirname(dest)
|
32352
|
+
pathExists(destParent, (err, dirExists) => {
|
32353
|
+
if (err) return cb(err)
|
32354
|
+
if (dirExists) return getStats(destStat, src, dest, opts, cb)
|
32355
|
+
mkdirs(destParent, err => {
|
32356
|
+
if (err) return cb(err)
|
32357
|
+
return getStats(destStat, src, dest, opts, cb)
|
32358
|
+
})
|
32359
|
+
})
|
32360
|
+
}
|
32361
|
+
|
32362
|
+
function handleFilter (onInclude, destStat, src, dest, opts, cb) {
|
32363
|
+
Promise.resolve(opts.filter(src, dest)).then(include => {
|
32364
|
+
if (include) return onInclude(destStat, src, dest, opts, cb)
|
32365
|
+
return cb()
|
32366
|
+
}, error => cb(error))
|
32367
|
+
}
|
32368
|
+
|
32369
|
+
function startCopy (destStat, src, dest, opts, cb) {
|
32370
|
+
if (opts.filter) return handleFilter(getStats, destStat, src, dest, opts, cb)
|
32371
|
+
return getStats(destStat, src, dest, opts, cb)
|
32372
|
+
}
|
32373
|
+
|
32374
|
+
function getStats (destStat, src, dest, opts, cb) {
|
32375
|
+
const stat = opts.dereference ? fs.stat : fs.lstat
|
32376
|
+
stat(src, (err, srcStat) => {
|
32377
|
+
if (err) return cb(err)
|
32378
|
+
|
32379
|
+
if (srcStat.isDirectory()) return onDir(srcStat, destStat, src, dest, opts, cb)
|
32380
|
+
else if (srcStat.isFile() ||
|
32381
|
+
srcStat.isCharacterDevice() ||
|
32382
|
+
srcStat.isBlockDevice()) return onFile(srcStat, destStat, src, dest, opts, cb)
|
32383
|
+
else if (srcStat.isSymbolicLink()) return onLink(destStat, src, dest, opts, cb)
|
32384
|
+
else if (srcStat.isSocket()) return cb(new Error(`Cannot copy a socket file: ${src}`))
|
32385
|
+
else if (srcStat.isFIFO()) return cb(new Error(`Cannot copy a FIFO pipe: ${src}`))
|
32386
|
+
return cb(new Error(`Unknown file: ${src}`))
|
32387
|
+
})
|
32388
|
+
}
|
32389
|
+
|
32390
|
+
function onFile (srcStat, destStat, src, dest, opts, cb) {
|
32391
|
+
if (!destStat) return copyFile(srcStat, src, dest, opts, cb)
|
32392
|
+
return mayCopyFile(srcStat, src, dest, opts, cb)
|
32393
|
+
}
|
32394
|
+
|
32395
|
+
function mayCopyFile (srcStat, src, dest, opts, cb) {
|
32396
|
+
if (opts.overwrite) {
|
32397
|
+
fs.unlink(dest, err => {
|
32398
|
+
if (err) return cb(err)
|
32399
|
+
return copyFile(srcStat, src, dest, opts, cb)
|
32400
|
+
})
|
32401
|
+
} else if (opts.errorOnExist) {
|
32402
|
+
return cb(new Error(`'${dest}' already exists`))
|
32403
|
+
} else return cb()
|
32404
|
+
}
|
32405
|
+
|
32406
|
+
function copyFile (srcStat, src, dest, opts, cb) {
|
32407
|
+
fs.copyFile(src, dest, err => {
|
32408
|
+
if (err) return cb(err)
|
32409
|
+
if (opts.preserveTimestamps) return handleTimestampsAndMode(srcStat.mode, src, dest, cb)
|
32410
|
+
return setDestMode(dest, srcStat.mode, cb)
|
32411
|
+
})
|
32412
|
+
}
|
32413
|
+
|
32414
|
+
function handleTimestampsAndMode (srcMode, src, dest, cb) {
|
32415
|
+
// Make sure the file is writable before setting the timestamp
|
32416
|
+
// otherwise open fails with EPERM when invoked with 'r+'
|
32417
|
+
// (through utimes call)
|
32418
|
+
if (fileIsNotWritable(srcMode)) {
|
32419
|
+
return makeFileWritable(dest, srcMode, err => {
|
32420
|
+
if (err) return cb(err)
|
32421
|
+
return setDestTimestampsAndMode(srcMode, src, dest, cb)
|
32422
|
+
})
|
32423
|
+
}
|
32424
|
+
return setDestTimestampsAndMode(srcMode, src, dest, cb)
|
32425
|
+
}
|
32426
|
+
|
32427
|
+
function fileIsNotWritable (srcMode) {
|
32428
|
+
return (srcMode & 0o200) === 0
|
32429
|
+
}
|
32430
|
+
|
32431
|
+
function makeFileWritable (dest, srcMode, cb) {
|
32432
|
+
return setDestMode(dest, srcMode | 0o200, cb)
|
32433
|
+
}
|
32434
|
+
|
32435
|
+
function setDestTimestampsAndMode (srcMode, src, dest, cb) {
|
32436
|
+
setDestTimestamps(src, dest, err => {
|
32437
|
+
if (err) return cb(err)
|
32438
|
+
return setDestMode(dest, srcMode, cb)
|
32439
|
+
})
|
32440
|
+
}
|
32441
|
+
|
32442
|
+
function setDestMode (dest, srcMode, cb) {
|
32443
|
+
return fs.chmod(dest, srcMode, cb)
|
32444
|
+
}
|
32445
|
+
|
32446
|
+
function setDestTimestamps (src, dest, cb) {
|
32447
|
+
// The initial srcStat.atime cannot be trusted
|
32448
|
+
// because it is modified by the read(2) system call
|
32449
|
+
// (See https://nodejs.org/api/fs.html#fs_stat_time_values)
|
32450
|
+
fs.stat(src, (err, updatedSrcStat) => {
|
32451
|
+
if (err) return cb(err)
|
32452
|
+
return utimesMillis(dest, updatedSrcStat.atime, updatedSrcStat.mtime, cb)
|
32453
|
+
})
|
32454
|
+
}
|
32455
|
+
|
32456
|
+
function onDir (srcStat, destStat, src, dest, opts, cb) {
|
32457
|
+
if (!destStat) return mkDirAndCopy(srcStat.mode, src, dest, opts, cb)
|
32458
|
+
return copyDir(src, dest, opts, cb)
|
32459
|
+
}
|
32460
|
+
|
32461
|
+
function mkDirAndCopy (srcMode, src, dest, opts, cb) {
|
32462
|
+
fs.mkdir(dest, err => {
|
32463
|
+
if (err) return cb(err)
|
32464
|
+
copyDir(src, dest, opts, err => {
|
32465
|
+
if (err) return cb(err)
|
32466
|
+
return setDestMode(dest, srcMode, cb)
|
32467
|
+
})
|
32468
|
+
})
|
32469
|
+
}
|
32470
|
+
|
32471
|
+
function copyDir (src, dest, opts, cb) {
|
32472
|
+
fs.readdir(src, (err, items) => {
|
32473
|
+
if (err) return cb(err)
|
32474
|
+
return copyDirItems(items, src, dest, opts, cb)
|
32475
|
+
})
|
32476
|
+
}
|
32477
|
+
|
32478
|
+
function copyDirItems (items, src, dest, opts, cb) {
|
32479
|
+
const item = items.pop()
|
32480
|
+
if (!item) return cb()
|
32481
|
+
return copyDirItem(items, item, src, dest, opts, cb)
|
32482
|
+
}
|
32483
|
+
|
32484
|
+
function copyDirItem (items, item, src, dest, opts, cb) {
|
32485
|
+
const srcItem = path.join(src, item)
|
32486
|
+
const destItem = path.join(dest, item)
|
32487
|
+
stat.checkPaths(srcItem, destItem, 'copy', opts, (err, stats) => {
|
32488
|
+
if (err) return cb(err)
|
32489
|
+
const { destStat } = stats
|
32490
|
+
startCopy(destStat, srcItem, destItem, opts, err => {
|
32491
|
+
if (err) return cb(err)
|
32492
|
+
return copyDirItems(items, src, dest, opts, cb)
|
32493
|
+
})
|
32494
|
+
})
|
32495
|
+
}
|
32496
|
+
|
32497
|
+
function onLink (destStat, src, dest, opts, cb) {
|
32498
|
+
fs.readlink(src, (err, resolvedSrc) => {
|
32499
|
+
if (err) return cb(err)
|
32500
|
+
if (opts.dereference) {
|
32501
|
+
resolvedSrc = path.resolve(process.cwd(), resolvedSrc)
|
32502
|
+
}
|
32503
|
+
|
32504
|
+
if (!destStat) {
|
32505
|
+
return fs.symlink(resolvedSrc, dest, cb)
|
32506
|
+
} else {
|
32507
|
+
fs.readlink(dest, (err, resolvedDest) => {
|
32508
|
+
if (err) {
|
32509
|
+
// dest exists and is a regular file or directory,
|
32510
|
+
// Windows may throw UNKNOWN error. If dest already exists,
|
32511
|
+
// fs throws error anyway, so no need to guard against it here.
|
32512
|
+
if (err.code === 'EINVAL' || err.code === 'UNKNOWN') return fs.symlink(resolvedSrc, dest, cb)
|
32513
|
+
return cb(err)
|
32514
|
+
}
|
32515
|
+
if (opts.dereference) {
|
32516
|
+
resolvedDest = path.resolve(process.cwd(), resolvedDest)
|
32517
|
+
}
|
32518
|
+
if (stat.isSrcSubdir(resolvedSrc, resolvedDest)) {
|
32519
|
+
return cb(new Error(`Cannot copy '${resolvedSrc}' to a subdirectory of itself, '${resolvedDest}'.`))
|
32520
|
+
}
|
32521
|
+
|
32522
|
+
// do not copy if src is a subdir of dest since unlinking
|
32523
|
+
// dest in this case would result in removing src contents
|
32524
|
+
// and therefore a broken symlink would be created.
|
32525
|
+
if (destStat.isDirectory() && stat.isSrcSubdir(resolvedDest, resolvedSrc)) {
|
32526
|
+
return cb(new Error(`Cannot overwrite '${resolvedDest}' with '${resolvedSrc}'.`))
|
32527
|
+
}
|
32528
|
+
return copyLink(resolvedSrc, dest, cb)
|
32529
|
+
})
|
32530
|
+
}
|
32531
|
+
})
|
32532
|
+
}
|
32533
|
+
|
32534
|
+
function copyLink (resolvedSrc, dest, cb) {
|
32535
|
+
fs.unlink(dest, err => {
|
32536
|
+
if (err) return cb(err)
|
32537
|
+
return fs.symlink(resolvedSrc, dest, cb)
|
32538
|
+
})
|
32539
|
+
}
|
32540
|
+
|
32541
|
+
module.exports = copy
|
32542
|
+
|
32543
|
+
|
32544
|
+
/***/ }),
|
32545
|
+
|
32546
|
+
/***/ 97969:
|
32547
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32548
|
+
|
32549
|
+
"use strict";
|
32550
|
+
|
32551
|
+
|
32552
|
+
const u = (__webpack_require__(84357).fromCallback)
|
32553
|
+
module.exports = {
|
32554
|
+
copy: u(__webpack_require__(77544))
|
32555
|
+
}
|
32556
|
+
|
32557
|
+
|
32558
|
+
/***/ }),
|
32559
|
+
|
32560
|
+
/***/ 54656:
|
32561
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32562
|
+
|
32563
|
+
"use strict";
|
32564
|
+
|
32565
|
+
|
32566
|
+
const u = (__webpack_require__(84357).fromPromise)
|
32567
|
+
const fs = __webpack_require__(48085)
|
32568
|
+
const path = __webpack_require__(71017)
|
32569
|
+
const mkdir = __webpack_require__(17433)
|
32570
|
+
const remove = __webpack_require__(13490)
|
32571
|
+
|
32572
|
+
const emptyDir = u(async function emptyDir (dir) {
|
32573
|
+
let items
|
32574
|
+
try {
|
32575
|
+
items = await fs.readdir(dir)
|
32576
|
+
} catch {
|
32577
|
+
return mkdir.mkdirs(dir)
|
32578
|
+
}
|
32579
|
+
|
32580
|
+
return Promise.all(items.map(item => remove.remove(path.join(dir, item))))
|
32581
|
+
})
|
32582
|
+
|
32583
|
+
function emptyDirSync (dir) {
|
32584
|
+
let items
|
32585
|
+
try {
|
32586
|
+
items = fs.readdirSync(dir)
|
32587
|
+
} catch {
|
32588
|
+
return mkdir.mkdirsSync(dir)
|
32589
|
+
}
|
32590
|
+
|
32591
|
+
items.forEach(item => {
|
32592
|
+
item = path.join(dir, item)
|
32593
|
+
remove.removeSync(item)
|
32594
|
+
})
|
32595
|
+
}
|
32596
|
+
|
32597
|
+
module.exports = {
|
32598
|
+
emptyDirSync,
|
32599
|
+
emptydirSync: emptyDirSync,
|
32600
|
+
emptyDir,
|
32601
|
+
emptydir: emptyDir
|
32602
|
+
}
|
32603
|
+
|
32604
|
+
|
32605
|
+
/***/ }),
|
32606
|
+
|
32607
|
+
/***/ 3805:
|
32608
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32609
|
+
|
32610
|
+
"use strict";
|
32611
|
+
|
32612
|
+
|
32613
|
+
const u = (__webpack_require__(84357).fromCallback)
|
32614
|
+
const path = __webpack_require__(71017)
|
32615
|
+
const fs = __webpack_require__(62204)
|
32616
|
+
const mkdir = __webpack_require__(17433)
|
32617
|
+
|
32618
|
+
function createFile (file, callback) {
|
32619
|
+
function makeFile () {
|
32620
|
+
fs.writeFile(file, '', err => {
|
32621
|
+
if (err) return callback(err)
|
32622
|
+
callback()
|
32623
|
+
})
|
32624
|
+
}
|
32625
|
+
|
32626
|
+
fs.stat(file, (err, stats) => { // eslint-disable-line handle-callback-err
|
32627
|
+
if (!err && stats.isFile()) return callback()
|
32628
|
+
const dir = path.dirname(file)
|
32629
|
+
fs.stat(dir, (err, stats) => {
|
32630
|
+
if (err) {
|
32631
|
+
// if the directory doesn't exist, make it
|
32632
|
+
if (err.code === 'ENOENT') {
|
32633
|
+
return mkdir.mkdirs(dir, err => {
|
32634
|
+
if (err) return callback(err)
|
32635
|
+
makeFile()
|
32636
|
+
})
|
32637
|
+
}
|
32638
|
+
return callback(err)
|
32639
|
+
}
|
32640
|
+
|
32641
|
+
if (stats.isDirectory()) makeFile()
|
32642
|
+
else {
|
32643
|
+
// parent is not a directory
|
32644
|
+
// This is just to cause an internal ENOTDIR error to be thrown
|
32645
|
+
fs.readdir(dir, err => {
|
32646
|
+
if (err) return callback(err)
|
32647
|
+
})
|
32648
|
+
}
|
32649
|
+
})
|
32650
|
+
})
|
32651
|
+
}
|
32652
|
+
|
32653
|
+
function createFileSync (file) {
|
32654
|
+
let stats
|
32655
|
+
try {
|
32656
|
+
stats = fs.statSync(file)
|
32657
|
+
} catch {}
|
32658
|
+
if (stats && stats.isFile()) return
|
32659
|
+
|
32660
|
+
const dir = path.dirname(file)
|
32661
|
+
try {
|
32662
|
+
if (!fs.statSync(dir).isDirectory()) {
|
32663
|
+
// parent is not a directory
|
32664
|
+
// This is just to cause an internal ENOTDIR error to be thrown
|
32665
|
+
fs.readdirSync(dir)
|
32666
|
+
}
|
32667
|
+
} catch (err) {
|
32668
|
+
// If the stat call above failed because the directory doesn't exist, create it
|
32669
|
+
if (err && err.code === 'ENOENT') mkdir.mkdirsSync(dir)
|
32670
|
+
else throw err
|
32671
|
+
}
|
32672
|
+
|
32673
|
+
fs.writeFileSync(file, '')
|
32674
|
+
}
|
32675
|
+
|
32676
|
+
module.exports = {
|
32677
|
+
createFile: u(createFile),
|
32678
|
+
createFileSync
|
32679
|
+
}
|
32680
|
+
|
32681
|
+
|
32682
|
+
/***/ }),
|
32683
|
+
|
32684
|
+
/***/ 61435:
|
32685
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32686
|
+
|
32687
|
+
"use strict";
|
32688
|
+
|
32689
|
+
|
32690
|
+
const file = __webpack_require__(3805)
|
32691
|
+
const link = __webpack_require__(34711)
|
32692
|
+
const symlink = __webpack_require__(9480)
|
32693
|
+
|
32694
|
+
module.exports = {
|
32695
|
+
// file
|
32696
|
+
createFile: file.createFile,
|
32697
|
+
createFileSync: file.createFileSync,
|
32698
|
+
ensureFile: file.createFile,
|
32699
|
+
ensureFileSync: file.createFileSync,
|
32700
|
+
// link
|
32701
|
+
createLink: link.createLink,
|
32702
|
+
createLinkSync: link.createLinkSync,
|
32703
|
+
ensureLink: link.createLink,
|
32704
|
+
ensureLinkSync: link.createLinkSync,
|
32705
|
+
// symlink
|
32706
|
+
createSymlink: symlink.createSymlink,
|
32707
|
+
createSymlinkSync: symlink.createSymlinkSync,
|
32708
|
+
ensureSymlink: symlink.createSymlink,
|
32709
|
+
ensureSymlinkSync: symlink.createSymlinkSync
|
32710
|
+
}
|
32711
|
+
|
32712
|
+
|
32713
|
+
/***/ }),
|
32714
|
+
|
32715
|
+
/***/ 34711:
|
32716
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32717
|
+
|
32718
|
+
"use strict";
|
32719
|
+
|
32720
|
+
|
32721
|
+
const u = (__webpack_require__(84357).fromCallback)
|
32722
|
+
const path = __webpack_require__(71017)
|
32723
|
+
const fs = __webpack_require__(62204)
|
32724
|
+
const mkdir = __webpack_require__(17433)
|
32725
|
+
const pathExists = (__webpack_require__(84906).pathExists)
|
32726
|
+
const { areIdentical } = __webpack_require__(31197)
|
32727
|
+
|
32728
|
+
function createLink (srcpath, dstpath, callback) {
|
32729
|
+
function makeLink (srcpath, dstpath) {
|
32730
|
+
fs.link(srcpath, dstpath, err => {
|
32731
|
+
if (err) return callback(err)
|
32732
|
+
callback(null)
|
32733
|
+
})
|
32734
|
+
}
|
32735
|
+
|
32736
|
+
fs.lstat(dstpath, (_, dstStat) => {
|
32737
|
+
fs.lstat(srcpath, (err, srcStat) => {
|
32738
|
+
if (err) {
|
32739
|
+
err.message = err.message.replace('lstat', 'ensureLink')
|
32740
|
+
return callback(err)
|
32741
|
+
}
|
32742
|
+
if (dstStat && areIdentical(srcStat, dstStat)) return callback(null)
|
32743
|
+
|
32744
|
+
const dir = path.dirname(dstpath)
|
32745
|
+
pathExists(dir, (err, dirExists) => {
|
32746
|
+
if (err) return callback(err)
|
32747
|
+
if (dirExists) return makeLink(srcpath, dstpath)
|
32748
|
+
mkdir.mkdirs(dir, err => {
|
32749
|
+
if (err) return callback(err)
|
32750
|
+
makeLink(srcpath, dstpath)
|
32751
|
+
})
|
32752
|
+
})
|
32753
|
+
})
|
32754
|
+
})
|
32755
|
+
}
|
32756
|
+
|
32757
|
+
function createLinkSync (srcpath, dstpath) {
|
32758
|
+
let dstStat
|
32759
|
+
try {
|
32760
|
+
dstStat = fs.lstatSync(dstpath)
|
32761
|
+
} catch {}
|
32762
|
+
|
32763
|
+
try {
|
32764
|
+
const srcStat = fs.lstatSync(srcpath)
|
32765
|
+
if (dstStat && areIdentical(srcStat, dstStat)) return
|
32766
|
+
} catch (err) {
|
32767
|
+
err.message = err.message.replace('lstat', 'ensureLink')
|
32768
|
+
throw err
|
32769
|
+
}
|
32770
|
+
|
32771
|
+
const dir = path.dirname(dstpath)
|
32772
|
+
const dirExists = fs.existsSync(dir)
|
32773
|
+
if (dirExists) return fs.linkSync(srcpath, dstpath)
|
32774
|
+
mkdir.mkdirsSync(dir)
|
32775
|
+
|
32776
|
+
return fs.linkSync(srcpath, dstpath)
|
32777
|
+
}
|
32778
|
+
|
32779
|
+
module.exports = {
|
32780
|
+
createLink: u(createLink),
|
32781
|
+
createLinkSync
|
32782
|
+
}
|
32783
|
+
|
32784
|
+
|
32785
|
+
/***/ }),
|
32786
|
+
|
32787
|
+
/***/ 31528:
|
32788
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32789
|
+
|
32790
|
+
"use strict";
|
32791
|
+
|
32792
|
+
|
32793
|
+
const path = __webpack_require__(71017)
|
32794
|
+
const fs = __webpack_require__(62204)
|
32795
|
+
const pathExists = (__webpack_require__(84906).pathExists)
|
32796
|
+
|
32797
|
+
/**
|
32798
|
+
* Function that returns two types of paths, one relative to symlink, and one
|
32799
|
+
* relative to the current working directory. Checks if path is absolute or
|
32800
|
+
* relative. If the path is relative, this function checks if the path is
|
32801
|
+
* relative to symlink or relative to current working directory. This is an
|
32802
|
+
* initiative to find a smarter `srcpath` to supply when building symlinks.
|
32803
|
+
* This allows you to determine which path to use out of one of three possible
|
32804
|
+
* types of source paths. The first is an absolute path. This is detected by
|
32805
|
+
* `path.isAbsolute()`. When an absolute path is provided, it is checked to
|
32806
|
+
* see if it exists. If it does it's used, if not an error is returned
|
32807
|
+
* (callback)/ thrown (sync). The other two options for `srcpath` are a
|
32808
|
+
* relative url. By default Node's `fs.symlink` works by creating a symlink
|
32809
|
+
* using `dstpath` and expects the `srcpath` to be relative to the newly
|
32810
|
+
* created symlink. If you provide a `srcpath` that does not exist on the file
|
32811
|
+
* system it results in a broken symlink. To minimize this, the function
|
32812
|
+
* checks to see if the 'relative to symlink' source file exists, and if it
|
32813
|
+
* does it will use it. If it does not, it checks if there's a file that
|
32814
|
+
* exists that is relative to the current working directory, if does its used.
|
32815
|
+
* This preserves the expectations of the original fs.symlink spec and adds
|
32816
|
+
* the ability to pass in `relative to current working direcotry` paths.
|
32817
|
+
*/
|
32818
|
+
|
32819
|
+
function symlinkPaths (srcpath, dstpath, callback) {
|
32820
|
+
if (path.isAbsolute(srcpath)) {
|
32821
|
+
return fs.lstat(srcpath, (err) => {
|
32822
|
+
if (err) {
|
32823
|
+
err.message = err.message.replace('lstat', 'ensureSymlink')
|
32824
|
+
return callback(err)
|
32825
|
+
}
|
32826
|
+
return callback(null, {
|
32827
|
+
toCwd: srcpath,
|
32828
|
+
toDst: srcpath
|
32829
|
+
})
|
32830
|
+
})
|
32831
|
+
} else {
|
32832
|
+
const dstdir = path.dirname(dstpath)
|
32833
|
+
const relativeToDst = path.join(dstdir, srcpath)
|
32834
|
+
return pathExists(relativeToDst, (err, exists) => {
|
32835
|
+
if (err) return callback(err)
|
32836
|
+
if (exists) {
|
32837
|
+
return callback(null, {
|
32838
|
+
toCwd: relativeToDst,
|
32839
|
+
toDst: srcpath
|
32840
|
+
})
|
32841
|
+
} else {
|
32842
|
+
return fs.lstat(srcpath, (err) => {
|
32843
|
+
if (err) {
|
32844
|
+
err.message = err.message.replace('lstat', 'ensureSymlink')
|
32845
|
+
return callback(err)
|
32846
|
+
}
|
32847
|
+
return callback(null, {
|
32848
|
+
toCwd: srcpath,
|
32849
|
+
toDst: path.relative(dstdir, srcpath)
|
32850
|
+
})
|
32851
|
+
})
|
32852
|
+
}
|
32853
|
+
})
|
32854
|
+
}
|
32855
|
+
}
|
32856
|
+
|
32857
|
+
function symlinkPathsSync (srcpath, dstpath) {
|
32858
|
+
let exists
|
32859
|
+
if (path.isAbsolute(srcpath)) {
|
32860
|
+
exists = fs.existsSync(srcpath)
|
32861
|
+
if (!exists) throw new Error('absolute srcpath does not exist')
|
32862
|
+
return {
|
32863
|
+
toCwd: srcpath,
|
32864
|
+
toDst: srcpath
|
32865
|
+
}
|
32866
|
+
} else {
|
32867
|
+
const dstdir = path.dirname(dstpath)
|
32868
|
+
const relativeToDst = path.join(dstdir, srcpath)
|
32869
|
+
exists = fs.existsSync(relativeToDst)
|
32870
|
+
if (exists) {
|
32871
|
+
return {
|
32872
|
+
toCwd: relativeToDst,
|
32873
|
+
toDst: srcpath
|
32874
|
+
}
|
32875
|
+
} else {
|
32876
|
+
exists = fs.existsSync(srcpath)
|
32877
|
+
if (!exists) throw new Error('relative srcpath does not exist')
|
32878
|
+
return {
|
32879
|
+
toCwd: srcpath,
|
32880
|
+
toDst: path.relative(dstdir, srcpath)
|
32881
|
+
}
|
32882
|
+
}
|
32883
|
+
}
|
32884
|
+
}
|
32885
|
+
|
32886
|
+
module.exports = {
|
32887
|
+
symlinkPaths,
|
32888
|
+
symlinkPathsSync
|
32889
|
+
}
|
32890
|
+
|
32891
|
+
|
32892
|
+
/***/ }),
|
32893
|
+
|
32894
|
+
/***/ 68938:
|
32895
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32896
|
+
|
32897
|
+
"use strict";
|
32898
|
+
|
32899
|
+
|
32900
|
+
const fs = __webpack_require__(62204)
|
32901
|
+
|
32902
|
+
function symlinkType (srcpath, type, callback) {
|
32903
|
+
callback = (typeof type === 'function') ? type : callback
|
32904
|
+
type = (typeof type === 'function') ? false : type
|
32905
|
+
if (type) return callback(null, type)
|
32906
|
+
fs.lstat(srcpath, (err, stats) => {
|
32907
|
+
if (err) return callback(null, 'file')
|
32908
|
+
type = (stats && stats.isDirectory()) ? 'dir' : 'file'
|
32909
|
+
callback(null, type)
|
32910
|
+
})
|
32911
|
+
}
|
32912
|
+
|
32913
|
+
function symlinkTypeSync (srcpath, type) {
|
32914
|
+
let stats
|
32915
|
+
|
32916
|
+
if (type) return type
|
32917
|
+
try {
|
32918
|
+
stats = fs.lstatSync(srcpath)
|
32919
|
+
} catch {
|
32920
|
+
return 'file'
|
32921
|
+
}
|
32922
|
+
return (stats && stats.isDirectory()) ? 'dir' : 'file'
|
32923
|
+
}
|
32924
|
+
|
32925
|
+
module.exports = {
|
32926
|
+
symlinkType,
|
32927
|
+
symlinkTypeSync
|
32928
|
+
}
|
32929
|
+
|
32930
|
+
|
32931
|
+
/***/ }),
|
32932
|
+
|
32933
|
+
/***/ 9480:
|
32934
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32935
|
+
|
32936
|
+
"use strict";
|
32937
|
+
|
32938
|
+
|
32939
|
+
const u = (__webpack_require__(84357).fromCallback)
|
32940
|
+
const path = __webpack_require__(71017)
|
32941
|
+
const fs = __webpack_require__(48085)
|
32942
|
+
const _mkdirs = __webpack_require__(17433)
|
32943
|
+
const mkdirs = _mkdirs.mkdirs
|
32944
|
+
const mkdirsSync = _mkdirs.mkdirsSync
|
32945
|
+
|
32946
|
+
const _symlinkPaths = __webpack_require__(31528)
|
32947
|
+
const symlinkPaths = _symlinkPaths.symlinkPaths
|
32948
|
+
const symlinkPathsSync = _symlinkPaths.symlinkPathsSync
|
32949
|
+
|
32950
|
+
const _symlinkType = __webpack_require__(68938)
|
32951
|
+
const symlinkType = _symlinkType.symlinkType
|
32952
|
+
const symlinkTypeSync = _symlinkType.symlinkTypeSync
|
32953
|
+
|
32954
|
+
const pathExists = (__webpack_require__(84906).pathExists)
|
32955
|
+
|
32956
|
+
const { areIdentical } = __webpack_require__(31197)
|
32957
|
+
|
32958
|
+
function createSymlink (srcpath, dstpath, type, callback) {
|
32959
|
+
callback = (typeof type === 'function') ? type : callback
|
32960
|
+
type = (typeof type === 'function') ? false : type
|
32961
|
+
|
32962
|
+
fs.lstat(dstpath, (err, stats) => {
|
32963
|
+
if (!err && stats.isSymbolicLink()) {
|
32964
|
+
Promise.all([
|
32965
|
+
fs.stat(srcpath),
|
32966
|
+
fs.stat(dstpath)
|
32967
|
+
]).then(([srcStat, dstStat]) => {
|
32968
|
+
if (areIdentical(srcStat, dstStat)) return callback(null)
|
32969
|
+
_createSymlink(srcpath, dstpath, type, callback)
|
32970
|
+
})
|
32971
|
+
} else _createSymlink(srcpath, dstpath, type, callback)
|
32972
|
+
})
|
32973
|
+
}
|
32974
|
+
|
32975
|
+
function _createSymlink (srcpath, dstpath, type, callback) {
|
32976
|
+
symlinkPaths(srcpath, dstpath, (err, relative) => {
|
32977
|
+
if (err) return callback(err)
|
32978
|
+
srcpath = relative.toDst
|
32979
|
+
symlinkType(relative.toCwd, type, (err, type) => {
|
32980
|
+
if (err) return callback(err)
|
32981
|
+
const dir = path.dirname(dstpath)
|
32982
|
+
pathExists(dir, (err, dirExists) => {
|
32983
|
+
if (err) return callback(err)
|
32984
|
+
if (dirExists) return fs.symlink(srcpath, dstpath, type, callback)
|
32985
|
+
mkdirs(dir, err => {
|
32986
|
+
if (err) return callback(err)
|
32987
|
+
fs.symlink(srcpath, dstpath, type, callback)
|
32988
|
+
})
|
32989
|
+
})
|
32990
|
+
})
|
32991
|
+
})
|
32992
|
+
}
|
32993
|
+
|
32994
|
+
function createSymlinkSync (srcpath, dstpath, type) {
|
32995
|
+
let stats
|
32996
|
+
try {
|
32997
|
+
stats = fs.lstatSync(dstpath)
|
32998
|
+
} catch {}
|
32999
|
+
if (stats && stats.isSymbolicLink()) {
|
33000
|
+
const srcStat = fs.statSync(srcpath)
|
33001
|
+
const dstStat = fs.statSync(dstpath)
|
33002
|
+
if (areIdentical(srcStat, dstStat)) return
|
33003
|
+
}
|
33004
|
+
|
33005
|
+
const relative = symlinkPathsSync(srcpath, dstpath)
|
33006
|
+
srcpath = relative.toDst
|
33007
|
+
type = symlinkTypeSync(relative.toCwd, type)
|
33008
|
+
const dir = path.dirname(dstpath)
|
33009
|
+
const exists = fs.existsSync(dir)
|
33010
|
+
if (exists) return fs.symlinkSync(srcpath, dstpath, type)
|
33011
|
+
mkdirsSync(dir)
|
33012
|
+
return fs.symlinkSync(srcpath, dstpath, type)
|
33013
|
+
}
|
33014
|
+
|
33015
|
+
module.exports = {
|
33016
|
+
createSymlink: u(createSymlink),
|
33017
|
+
createSymlinkSync
|
33018
|
+
}
|
33019
|
+
|
33020
|
+
|
33021
|
+
/***/ }),
|
33022
|
+
|
33023
|
+
/***/ 48085:
|
33024
|
+
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
33025
|
+
|
33026
|
+
"use strict";
|
33027
|
+
|
33028
|
+
// This is adapted from https://github.com/normalize/mz
|
33029
|
+
// Copyright (c) 2014-2016 Jonathan Ong me@jongleberry.com and Contributors
|
33030
|
+
const u = (__webpack_require__(84357).fromCallback)
|
33031
|
+
const fs = __webpack_require__(62204)
|
33032
|
+
|
33033
|
+
const api = [
|
33034
|
+
'access',
|
33035
|
+
'appendFile',
|
33036
|
+
'chmod',
|
33037
|
+
'chown',
|
33038
|
+
'close',
|
33039
|
+
'copyFile',
|
33040
|
+
'fchmod',
|
33041
|
+
'fchown',
|
33042
|
+
'fdatasync',
|
33043
|
+
'fstat',
|
33044
|
+
'fsync',
|
33045
|
+
'ftruncate',
|
33046
|
+
'futimes',
|
33047
|
+
'lchmod',
|
33048
|
+
'lchown',
|
33049
|
+
'link',
|
33050
|
+
'lstat',
|
33051
|
+
'mkdir',
|
33052
|
+
'mkdtemp',
|
33053
|
+
'open',
|
33054
|
+
'opendir',
|
33055
|
+
'readdir',
|
33056
|
+
'readFile',
|
33057
|
+
'readlink',
|
33058
|
+
'realpath',
|
33059
|
+
'rename',
|
33060
|
+
'rm',
|
33061
|
+
'rmdir',
|
33062
|
+
'stat',
|
33063
|
+
'symlink',
|
33064
|
+
'truncate',
|
33065
|
+
'unlink',
|
33066
|
+
'utimes',
|
33067
|
+
'writeFile'
|
33068
|
+
].filter(key => {
|
33069
|
+
// Some commands are not available on some systems. Ex:
|
33070
|
+
// fs.opendir was added in Node.js v12.12.0
|
33071
|
+
// fs.rm was added in Node.js v14.14.0
|
33072
|
+
// fs.lchown is not available on at least some Linux
|
33073
|
+
return typeof fs[key] === 'function'
|
33074
|
+
})
|
33075
|
+
|
33076
|
+
// Export cloned fs:
|
33077
|
+
Object.assign(exports, fs)
|
33078
|
+
|
33079
|
+
// Universalify async methods:
|
33080
|
+
api.forEach(method => {
|
33081
|
+
exports[method] = u(fs[method])
|
33082
|
+
})
|
33083
|
+
exports.realpath.native = u(fs.realpath.native)
|
33084
|
+
|
33085
|
+
// We differ from mz/fs in that we still ship the old, broken, fs.exists()
|
33086
|
+
// since we are a drop-in replacement for the native module
|
33087
|
+
exports.exists = function (filename, callback) {
|
33088
|
+
if (typeof callback === 'function') {
|
33089
|
+
return fs.exists(filename, callback)
|
33090
|
+
}
|
33091
|
+
return new Promise(resolve => {
|
33092
|
+
return fs.exists(filename, resolve)
|
33093
|
+
})
|
33094
|
+
}
|
33095
|
+
|
33096
|
+
// fs.read(), fs.write(), & fs.writev() need special treatment due to multiple callback args
|
33097
|
+
|
33098
|
+
exports.read = function (fd, buffer, offset, length, position, callback) {
|
33099
|
+
if (typeof callback === 'function') {
|
33100
|
+
return fs.read(fd, buffer, offset, length, position, callback)
|
33101
|
+
}
|
33102
|
+
return new Promise((resolve, reject) => {
|
33103
|
+
fs.read(fd, buffer, offset, length, position, (err, bytesRead, buffer) => {
|
33104
|
+
if (err) return reject(err)
|
33105
|
+
resolve({ bytesRead, buffer })
|
33106
|
+
})
|
33107
|
+
})
|
33108
|
+
}
|
33109
|
+
|
33110
|
+
// Function signature can be
|
33111
|
+
// fs.write(fd, buffer[, offset[, length[, position]]], callback)
|
33112
|
+
// OR
|
33113
|
+
// fs.write(fd, string[, position[, encoding]], callback)
|
33114
|
+
// We need to handle both cases, so we use ...args
|
33115
|
+
exports.write = function (fd, buffer, ...args) {
|
33116
|
+
if (typeof args[args.length - 1] === 'function') {
|
33117
|
+
return fs.write(fd, buffer, ...args)
|
33118
|
+
}
|
33119
|
+
|
33120
|
+
return new Promise((resolve, reject) => {
|
33121
|
+
fs.write(fd, buffer, ...args, (err, bytesWritten, buffer) => {
|
33122
|
+
if (err) return reject(err)
|
33123
|
+
resolve({ bytesWritten, buffer })
|
33124
|
+
})
|
33125
|
+
})
|
33126
|
+
}
|
33127
|
+
|
33128
|
+
// fs.writev only available in Node v12.9.0+
|
33129
|
+
if (typeof fs.writev === 'function') {
|
33130
|
+
// Function signature is
|
33131
|
+
// s.writev(fd, buffers[, position], callback)
|
33132
|
+
// We need to handle the optional arg, so we use ...args
|
33133
|
+
exports.writev = function (fd, buffers, ...args) {
|
33134
|
+
if (typeof args[args.length - 1] === 'function') {
|
33135
|
+
return fs.writev(fd, buffers, ...args)
|
33136
|
+
}
|
33137
|
+
|
33138
|
+
return new Promise((resolve, reject) => {
|
33139
|
+
fs.writev(fd, buffers, ...args, (err, bytesWritten, buffers) => {
|
33140
|
+
if (err) return reject(err)
|
33141
|
+
resolve({ bytesWritten, buffers })
|
33142
|
+
})
|
33143
|
+
})
|
33144
|
+
}
|
33145
|
+
}
|
33146
|
+
|
33147
|
+
|
33148
|
+
/***/ }),
|
33149
|
+
|
33150
|
+
/***/ 96576:
|
33151
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33152
|
+
|
33153
|
+
"use strict";
|
33154
|
+
|
33155
|
+
|
33156
|
+
module.exports = {
|
33157
|
+
// Export promiseified graceful-fs:
|
33158
|
+
...__webpack_require__(48085),
|
33159
|
+
// Export extra methods:
|
33160
|
+
...__webpack_require__(55391),
|
33161
|
+
...__webpack_require__(97969),
|
33162
|
+
...__webpack_require__(54656),
|
33163
|
+
...__webpack_require__(61435),
|
33164
|
+
...__webpack_require__(58050),
|
33165
|
+
...__webpack_require__(17433),
|
33166
|
+
...__webpack_require__(84170),
|
33167
|
+
...__webpack_require__(28439),
|
33168
|
+
...__webpack_require__(54379),
|
33169
|
+
...__webpack_require__(84906),
|
33170
|
+
...__webpack_require__(13490)
|
33171
|
+
}
|
33172
|
+
|
33173
|
+
|
33174
|
+
/***/ }),
|
33175
|
+
|
33176
|
+
/***/ 58050:
|
33177
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33178
|
+
|
33179
|
+
"use strict";
|
33180
|
+
|
33181
|
+
|
33182
|
+
const u = (__webpack_require__(84357).fromPromise)
|
33183
|
+
const jsonFile = __webpack_require__(73545)
|
33184
|
+
|
33185
|
+
jsonFile.outputJson = u(__webpack_require__(84981))
|
33186
|
+
jsonFile.outputJsonSync = __webpack_require__(47032)
|
33187
|
+
// aliases
|
33188
|
+
jsonFile.outputJSON = jsonFile.outputJson
|
33189
|
+
jsonFile.outputJSONSync = jsonFile.outputJsonSync
|
33190
|
+
jsonFile.writeJSON = jsonFile.writeJson
|
33191
|
+
jsonFile.writeJSONSync = jsonFile.writeJsonSync
|
33192
|
+
jsonFile.readJSON = jsonFile.readJson
|
33193
|
+
jsonFile.readJSONSync = jsonFile.readJsonSync
|
33194
|
+
|
33195
|
+
module.exports = jsonFile
|
33196
|
+
|
33197
|
+
|
33198
|
+
/***/ }),
|
33199
|
+
|
33200
|
+
/***/ 73545:
|
33201
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33202
|
+
|
33203
|
+
"use strict";
|
33204
|
+
|
33205
|
+
|
33206
|
+
const jsonFile = __webpack_require__(84719)
|
33207
|
+
|
33208
|
+
module.exports = {
|
33209
|
+
// jsonfile exports
|
33210
|
+
readJson: jsonFile.readFile,
|
33211
|
+
readJsonSync: jsonFile.readFileSync,
|
33212
|
+
writeJson: jsonFile.writeFile,
|
33213
|
+
writeJsonSync: jsonFile.writeFileSync
|
33214
|
+
}
|
33215
|
+
|
33216
|
+
|
33217
|
+
/***/ }),
|
33218
|
+
|
33219
|
+
/***/ 47032:
|
33220
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33221
|
+
|
33222
|
+
"use strict";
|
33223
|
+
|
33224
|
+
|
33225
|
+
const { stringify } = __webpack_require__(27546)
|
33226
|
+
const { outputFileSync } = __webpack_require__(54379)
|
33227
|
+
|
33228
|
+
function outputJsonSync (file, data, options) {
|
33229
|
+
const str = stringify(data, options)
|
33230
|
+
|
33231
|
+
outputFileSync(file, str, options)
|
33232
|
+
}
|
33233
|
+
|
33234
|
+
module.exports = outputJsonSync
|
33235
|
+
|
33236
|
+
|
33237
|
+
/***/ }),
|
33238
|
+
|
33239
|
+
/***/ 84981:
|
33240
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33241
|
+
|
33242
|
+
"use strict";
|
33243
|
+
|
33244
|
+
|
33245
|
+
const { stringify } = __webpack_require__(27546)
|
33246
|
+
const { outputFile } = __webpack_require__(54379)
|
33247
|
+
|
33248
|
+
async function outputJson (file, data, options = {}) {
|
33249
|
+
const str = stringify(data, options)
|
33250
|
+
|
33251
|
+
await outputFile(file, str, options)
|
33252
|
+
}
|
33253
|
+
|
33254
|
+
module.exports = outputJson
|
33255
|
+
|
33256
|
+
|
33257
|
+
/***/ }),
|
33258
|
+
|
33259
|
+
/***/ 17433:
|
33260
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33261
|
+
|
33262
|
+
"use strict";
|
33263
|
+
|
33264
|
+
const u = (__webpack_require__(84357).fromPromise)
|
33265
|
+
const { makeDir: _makeDir, makeDirSync } = __webpack_require__(75594)
|
33266
|
+
const makeDir = u(_makeDir)
|
33267
|
+
|
33268
|
+
module.exports = {
|
33269
|
+
mkdirs: makeDir,
|
33270
|
+
mkdirsSync: makeDirSync,
|
33271
|
+
// alias
|
33272
|
+
mkdirp: makeDir,
|
33273
|
+
mkdirpSync: makeDirSync,
|
33274
|
+
ensureDir: makeDir,
|
33275
|
+
ensureDirSync: makeDirSync
|
33276
|
+
}
|
33277
|
+
|
33278
|
+
|
33279
|
+
/***/ }),
|
33280
|
+
|
33281
|
+
/***/ 75594:
|
33282
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33283
|
+
|
33284
|
+
"use strict";
|
33285
|
+
|
33286
|
+
const fs = __webpack_require__(48085)
|
33287
|
+
const { checkPath } = __webpack_require__(60937)
|
33288
|
+
|
33289
|
+
const getMode = options => {
|
33290
|
+
const defaults = { mode: 0o777 }
|
33291
|
+
if (typeof options === 'number') return options
|
33292
|
+
return ({ ...defaults, ...options }).mode
|
33293
|
+
}
|
33294
|
+
|
33295
|
+
module.exports.makeDir = async (dir, options) => {
|
33296
|
+
checkPath(dir)
|
33297
|
+
|
33298
|
+
return fs.mkdir(dir, {
|
33299
|
+
mode: getMode(options),
|
33300
|
+
recursive: true
|
33301
|
+
})
|
33302
|
+
}
|
33303
|
+
|
33304
|
+
module.exports.makeDirSync = (dir, options) => {
|
33305
|
+
checkPath(dir)
|
33306
|
+
|
33307
|
+
return fs.mkdirSync(dir, {
|
33308
|
+
mode: getMode(options),
|
33309
|
+
recursive: true
|
33310
|
+
})
|
33311
|
+
}
|
33312
|
+
|
33313
|
+
|
33314
|
+
/***/ }),
|
33315
|
+
|
33316
|
+
/***/ 60937:
|
33317
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33318
|
+
|
33319
|
+
"use strict";
|
33320
|
+
// Adapted from https://github.com/sindresorhus/make-dir
|
33321
|
+
// Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com)
|
33322
|
+
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
33323
|
+
// The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
33324
|
+
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
33325
|
+
|
33326
|
+
const path = __webpack_require__(71017)
|
33327
|
+
|
33328
|
+
// https://github.com/nodejs/node/issues/8987
|
33329
|
+
// https://github.com/libuv/libuv/pull/1088
|
33330
|
+
module.exports.checkPath = function checkPath (pth) {
|
33331
|
+
if (process.platform === 'win32') {
|
33332
|
+
const pathHasInvalidWinCharacters = /[<>:"|?*]/.test(pth.replace(path.parse(pth).root, ''))
|
33333
|
+
|
33334
|
+
if (pathHasInvalidWinCharacters) {
|
33335
|
+
const error = new Error(`Path contains invalid characters: ${pth}`)
|
33336
|
+
error.code = 'EINVAL'
|
33337
|
+
throw error
|
33338
|
+
}
|
33339
|
+
}
|
33340
|
+
}
|
33341
|
+
|
33342
|
+
|
33343
|
+
/***/ }),
|
33344
|
+
|
33345
|
+
/***/ 84170:
|
33346
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33347
|
+
|
33348
|
+
"use strict";
|
33349
|
+
|
33350
|
+
|
33351
|
+
module.exports = {
|
33352
|
+
moveSync: __webpack_require__(84065)
|
33353
|
+
}
|
33354
|
+
|
33355
|
+
|
33356
|
+
/***/ }),
|
33357
|
+
|
33358
|
+
/***/ 84065:
|
33359
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33360
|
+
|
33361
|
+
"use strict";
|
33362
|
+
|
33363
|
+
|
33364
|
+
const fs = __webpack_require__(62204)
|
33365
|
+
const path = __webpack_require__(71017)
|
33366
|
+
const copySync = (__webpack_require__(55391).copySync)
|
33367
|
+
const removeSync = (__webpack_require__(13490).removeSync)
|
33368
|
+
const mkdirpSync = (__webpack_require__(17433).mkdirpSync)
|
33369
|
+
const stat = __webpack_require__(31197)
|
33370
|
+
|
33371
|
+
function moveSync (src, dest, opts) {
|
33372
|
+
opts = opts || {}
|
33373
|
+
const overwrite = opts.overwrite || opts.clobber || false
|
33374
|
+
|
33375
|
+
const { srcStat, isChangingCase = false } = stat.checkPathsSync(src, dest, 'move', opts)
|
33376
|
+
stat.checkParentPathsSync(src, srcStat, dest, 'move')
|
33377
|
+
if (!isParentRoot(dest)) mkdirpSync(path.dirname(dest))
|
33378
|
+
return doRename(src, dest, overwrite, isChangingCase)
|
33379
|
+
}
|
33380
|
+
|
33381
|
+
function isParentRoot (dest) {
|
33382
|
+
const parent = path.dirname(dest)
|
33383
|
+
const parsedPath = path.parse(parent)
|
33384
|
+
return parsedPath.root === parent
|
33385
|
+
}
|
33386
|
+
|
33387
|
+
function doRename (src, dest, overwrite, isChangingCase) {
|
33388
|
+
if (isChangingCase) return rename(src, dest, overwrite)
|
33389
|
+
if (overwrite) {
|
33390
|
+
removeSync(dest)
|
33391
|
+
return rename(src, dest, overwrite)
|
33392
|
+
}
|
33393
|
+
if (fs.existsSync(dest)) throw new Error('dest already exists.')
|
33394
|
+
return rename(src, dest, overwrite)
|
33395
|
+
}
|
33396
|
+
|
33397
|
+
function rename (src, dest, overwrite) {
|
33398
|
+
try {
|
33399
|
+
fs.renameSync(src, dest)
|
33400
|
+
} catch (err) {
|
33401
|
+
if (err.code !== 'EXDEV') throw err
|
33402
|
+
return moveAcrossDevice(src, dest, overwrite)
|
33403
|
+
}
|
33404
|
+
}
|
33405
|
+
|
33406
|
+
function moveAcrossDevice (src, dest, overwrite) {
|
33407
|
+
const opts = {
|
33408
|
+
overwrite,
|
33409
|
+
errorOnExist: true
|
33410
|
+
}
|
33411
|
+
copySync(src, dest, opts)
|
33412
|
+
return removeSync(src)
|
33413
|
+
}
|
33414
|
+
|
33415
|
+
module.exports = moveSync
|
33416
|
+
|
33417
|
+
|
33418
|
+
/***/ }),
|
33419
|
+
|
33420
|
+
/***/ 28439:
|
33421
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33422
|
+
|
33423
|
+
"use strict";
|
33424
|
+
|
33425
|
+
|
33426
|
+
const u = (__webpack_require__(84357).fromCallback)
|
33427
|
+
module.exports = {
|
33428
|
+
move: u(__webpack_require__(69071))
|
33429
|
+
}
|
33430
|
+
|
33431
|
+
|
33432
|
+
/***/ }),
|
33433
|
+
|
33434
|
+
/***/ 69071:
|
33435
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33436
|
+
|
33437
|
+
"use strict";
|
33438
|
+
|
33439
|
+
|
33440
|
+
const fs = __webpack_require__(62204)
|
33441
|
+
const path = __webpack_require__(71017)
|
33442
|
+
const copy = (__webpack_require__(97969).copy)
|
33443
|
+
const remove = (__webpack_require__(13490).remove)
|
33444
|
+
const mkdirp = (__webpack_require__(17433).mkdirp)
|
33445
|
+
const pathExists = (__webpack_require__(84906).pathExists)
|
33446
|
+
const stat = __webpack_require__(31197)
|
33447
|
+
|
33448
|
+
function move (src, dest, opts, cb) {
|
33449
|
+
if (typeof opts === 'function') {
|
33450
|
+
cb = opts
|
33451
|
+
opts = {}
|
33452
|
+
}
|
33453
|
+
|
33454
|
+
const overwrite = opts.overwrite || opts.clobber || false
|
33455
|
+
|
33456
|
+
stat.checkPaths(src, dest, 'move', opts, (err, stats) => {
|
33457
|
+
if (err) return cb(err)
|
33458
|
+
const { srcStat, isChangingCase = false } = stats
|
33459
|
+
stat.checkParentPaths(src, srcStat, dest, 'move', err => {
|
33460
|
+
if (err) return cb(err)
|
33461
|
+
if (isParentRoot(dest)) return doRename(src, dest, overwrite, isChangingCase, cb)
|
33462
|
+
mkdirp(path.dirname(dest), err => {
|
33463
|
+
if (err) return cb(err)
|
33464
|
+
return doRename(src, dest, overwrite, isChangingCase, cb)
|
33465
|
+
})
|
33466
|
+
})
|
33467
|
+
})
|
33468
|
+
}
|
33469
|
+
|
33470
|
+
function isParentRoot (dest) {
|
33471
|
+
const parent = path.dirname(dest)
|
33472
|
+
const parsedPath = path.parse(parent)
|
33473
|
+
return parsedPath.root === parent
|
33474
|
+
}
|
33475
|
+
|
33476
|
+
function doRename (src, dest, overwrite, isChangingCase, cb) {
|
33477
|
+
if (isChangingCase) return rename(src, dest, overwrite, cb)
|
33478
|
+
if (overwrite) {
|
33479
|
+
return remove(dest, err => {
|
33480
|
+
if (err) return cb(err)
|
33481
|
+
return rename(src, dest, overwrite, cb)
|
33482
|
+
})
|
33483
|
+
}
|
33484
|
+
pathExists(dest, (err, destExists) => {
|
33485
|
+
if (err) return cb(err)
|
33486
|
+
if (destExists) return cb(new Error('dest already exists.'))
|
33487
|
+
return rename(src, dest, overwrite, cb)
|
33488
|
+
})
|
33489
|
+
}
|
33490
|
+
|
33491
|
+
function rename (src, dest, overwrite, cb) {
|
33492
|
+
fs.rename(src, dest, err => {
|
33493
|
+
if (!err) return cb()
|
33494
|
+
if (err.code !== 'EXDEV') return cb(err)
|
33495
|
+
return moveAcrossDevice(src, dest, overwrite, cb)
|
33496
|
+
})
|
33497
|
+
}
|
33498
|
+
|
33499
|
+
function moveAcrossDevice (src, dest, overwrite, cb) {
|
33500
|
+
const opts = {
|
33501
|
+
overwrite,
|
33502
|
+
errorOnExist: true
|
33503
|
+
}
|
33504
|
+
copy(src, dest, opts, err => {
|
33505
|
+
if (err) return cb(err)
|
33506
|
+
return remove(src, cb)
|
33507
|
+
})
|
33508
|
+
}
|
33509
|
+
|
33510
|
+
module.exports = move
|
33511
|
+
|
33512
|
+
|
33513
|
+
/***/ }),
|
33514
|
+
|
33515
|
+
/***/ 54379:
|
33516
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33517
|
+
|
33518
|
+
"use strict";
|
33519
|
+
|
33520
|
+
|
33521
|
+
const u = (__webpack_require__(84357).fromCallback)
|
33522
|
+
const fs = __webpack_require__(62204)
|
33523
|
+
const path = __webpack_require__(71017)
|
33524
|
+
const mkdir = __webpack_require__(17433)
|
33525
|
+
const pathExists = (__webpack_require__(84906).pathExists)
|
33526
|
+
|
33527
|
+
function outputFile (file, data, encoding, callback) {
|
33528
|
+
if (typeof encoding === 'function') {
|
33529
|
+
callback = encoding
|
33530
|
+
encoding = 'utf8'
|
33531
|
+
}
|
33532
|
+
|
33533
|
+
const dir = path.dirname(file)
|
33534
|
+
pathExists(dir, (err, itDoes) => {
|
33535
|
+
if (err) return callback(err)
|
33536
|
+
if (itDoes) return fs.writeFile(file, data, encoding, callback)
|
33537
|
+
|
33538
|
+
mkdir.mkdirs(dir, err => {
|
33539
|
+
if (err) return callback(err)
|
33540
|
+
|
33541
|
+
fs.writeFile(file, data, encoding, callback)
|
33542
|
+
})
|
33543
|
+
})
|
33544
|
+
}
|
33545
|
+
|
33546
|
+
function outputFileSync (file, ...args) {
|
33547
|
+
const dir = path.dirname(file)
|
33548
|
+
if (fs.existsSync(dir)) {
|
33549
|
+
return fs.writeFileSync(file, ...args)
|
33550
|
+
}
|
33551
|
+
mkdir.mkdirsSync(dir)
|
33552
|
+
fs.writeFileSync(file, ...args)
|
33553
|
+
}
|
33554
|
+
|
33555
|
+
module.exports = {
|
33556
|
+
outputFile: u(outputFile),
|
33557
|
+
outputFileSync
|
33558
|
+
}
|
33559
|
+
|
33560
|
+
|
33561
|
+
/***/ }),
|
33562
|
+
|
33563
|
+
/***/ 84906:
|
33564
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33565
|
+
|
33566
|
+
"use strict";
|
33567
|
+
|
33568
|
+
const u = (__webpack_require__(84357).fromPromise)
|
33569
|
+
const fs = __webpack_require__(48085)
|
33570
|
+
|
33571
|
+
function pathExists (path) {
|
33572
|
+
return fs.access(path).then(() => true).catch(() => false)
|
33573
|
+
}
|
33574
|
+
|
33575
|
+
module.exports = {
|
33576
|
+
pathExists: u(pathExists),
|
33577
|
+
pathExistsSync: fs.existsSync
|
33578
|
+
}
|
33579
|
+
|
33580
|
+
|
33581
|
+
/***/ }),
|
33582
|
+
|
33583
|
+
/***/ 13490:
|
33584
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33585
|
+
|
33586
|
+
"use strict";
|
33587
|
+
|
33588
|
+
|
33589
|
+
const fs = __webpack_require__(62204)
|
33590
|
+
const u = (__webpack_require__(84357).fromCallback)
|
33591
|
+
const rimraf = __webpack_require__(94392)
|
33592
|
+
|
33593
|
+
function remove (path, callback) {
|
33594
|
+
// Node 14.14.0+
|
33595
|
+
if (fs.rm) return fs.rm(path, { recursive: true, force: true }, callback)
|
33596
|
+
rimraf(path, callback)
|
33597
|
+
}
|
33598
|
+
|
33599
|
+
function removeSync (path) {
|
33600
|
+
// Node 14.14.0+
|
33601
|
+
if (fs.rmSync) return fs.rmSync(path, { recursive: true, force: true })
|
33602
|
+
rimraf.sync(path)
|
33603
|
+
}
|
33604
|
+
|
33605
|
+
module.exports = {
|
33606
|
+
remove: u(remove),
|
33607
|
+
removeSync
|
33608
|
+
}
|
33609
|
+
|
33610
|
+
|
33611
|
+
/***/ }),
|
33612
|
+
|
33613
|
+
/***/ 94392:
|
33614
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33615
|
+
|
33616
|
+
"use strict";
|
33617
|
+
|
33618
|
+
|
33619
|
+
const fs = __webpack_require__(62204)
|
33620
|
+
const path = __webpack_require__(71017)
|
33621
|
+
const assert = __webpack_require__(39491)
|
33622
|
+
|
33623
|
+
const isWindows = (process.platform === 'win32')
|
33624
|
+
|
33625
|
+
function defaults (options) {
|
33626
|
+
const methods = [
|
33627
|
+
'unlink',
|
33628
|
+
'chmod',
|
33629
|
+
'stat',
|
33630
|
+
'lstat',
|
33631
|
+
'rmdir',
|
33632
|
+
'readdir'
|
33633
|
+
]
|
33634
|
+
methods.forEach(m => {
|
33635
|
+
options[m] = options[m] || fs[m]
|
33636
|
+
m = m + 'Sync'
|
33637
|
+
options[m] = options[m] || fs[m]
|
33638
|
+
})
|
33639
|
+
|
33640
|
+
options.maxBusyTries = options.maxBusyTries || 3
|
33641
|
+
}
|
33642
|
+
|
33643
|
+
function rimraf (p, options, cb) {
|
33644
|
+
let busyTries = 0
|
33645
|
+
|
33646
|
+
if (typeof options === 'function') {
|
33647
|
+
cb = options
|
33648
|
+
options = {}
|
33649
|
+
}
|
33650
|
+
|
33651
|
+
assert(p, 'rimraf: missing path')
|
33652
|
+
assert.strictEqual(typeof p, 'string', 'rimraf: path should be a string')
|
33653
|
+
assert.strictEqual(typeof cb, 'function', 'rimraf: callback function required')
|
33654
|
+
assert(options, 'rimraf: invalid options argument provided')
|
33655
|
+
assert.strictEqual(typeof options, 'object', 'rimraf: options should be object')
|
33656
|
+
|
33657
|
+
defaults(options)
|
33658
|
+
|
33659
|
+
rimraf_(p, options, function CB (er) {
|
33660
|
+
if (er) {
|
33661
|
+
if ((er.code === 'EBUSY' || er.code === 'ENOTEMPTY' || er.code === 'EPERM') &&
|
33662
|
+
busyTries < options.maxBusyTries) {
|
33663
|
+
busyTries++
|
33664
|
+
const time = busyTries * 100
|
33665
|
+
// try again, with the same exact callback as this one.
|
33666
|
+
return setTimeout(() => rimraf_(p, options, CB), time)
|
33667
|
+
}
|
33668
|
+
|
33669
|
+
// already gone
|
33670
|
+
if (er.code === 'ENOENT') er = null
|
33671
|
+
}
|
33672
|
+
|
33673
|
+
cb(er)
|
33674
|
+
})
|
33675
|
+
}
|
33676
|
+
|
33677
|
+
// Two possible strategies.
|
33678
|
+
// 1. Assume it's a file. unlink it, then do the dir stuff on EPERM or EISDIR
|
33679
|
+
// 2. Assume it's a directory. readdir, then do the file stuff on ENOTDIR
|
33680
|
+
//
|
33681
|
+
// Both result in an extra syscall when you guess wrong. However, there
|
33682
|
+
// are likely far more normal files in the world than directories. This
|
33683
|
+
// is based on the assumption that a the average number of files per
|
33684
|
+
// directory is >= 1.
|
33685
|
+
//
|
33686
|
+
// If anyone ever complains about this, then I guess the strategy could
|
33687
|
+
// be made configurable somehow. But until then, YAGNI.
|
33688
|
+
function rimraf_ (p, options, cb) {
|
33689
|
+
assert(p)
|
33690
|
+
assert(options)
|
33691
|
+
assert(typeof cb === 'function')
|
33692
|
+
|
33693
|
+
// sunos lets the root user unlink directories, which is... weird.
|
33694
|
+
// so we have to lstat here and make sure it's not a dir.
|
33695
|
+
options.lstat(p, (er, st) => {
|
33696
|
+
if (er && er.code === 'ENOENT') {
|
33697
|
+
return cb(null)
|
33698
|
+
}
|
33699
|
+
|
33700
|
+
// Windows can EPERM on stat. Life is suffering.
|
33701
|
+
if (er && er.code === 'EPERM' && isWindows) {
|
33702
|
+
return fixWinEPERM(p, options, er, cb)
|
33703
|
+
}
|
33704
|
+
|
33705
|
+
if (st && st.isDirectory()) {
|
33706
|
+
return rmdir(p, options, er, cb)
|
33707
|
+
}
|
33708
|
+
|
33709
|
+
options.unlink(p, er => {
|
33710
|
+
if (er) {
|
33711
|
+
if (er.code === 'ENOENT') {
|
33712
|
+
return cb(null)
|
33713
|
+
}
|
33714
|
+
if (er.code === 'EPERM') {
|
33715
|
+
return (isWindows)
|
33716
|
+
? fixWinEPERM(p, options, er, cb)
|
33717
|
+
: rmdir(p, options, er, cb)
|
33718
|
+
}
|
33719
|
+
if (er.code === 'EISDIR') {
|
33720
|
+
return rmdir(p, options, er, cb)
|
33721
|
+
}
|
33722
|
+
}
|
33723
|
+
return cb(er)
|
33724
|
+
})
|
33725
|
+
})
|
33726
|
+
}
|
33727
|
+
|
33728
|
+
function fixWinEPERM (p, options, er, cb) {
|
33729
|
+
assert(p)
|
33730
|
+
assert(options)
|
33731
|
+
assert(typeof cb === 'function')
|
33732
|
+
|
33733
|
+
options.chmod(p, 0o666, er2 => {
|
33734
|
+
if (er2) {
|
33735
|
+
cb(er2.code === 'ENOENT' ? null : er)
|
33736
|
+
} else {
|
33737
|
+
options.stat(p, (er3, stats) => {
|
33738
|
+
if (er3) {
|
33739
|
+
cb(er3.code === 'ENOENT' ? null : er)
|
33740
|
+
} else if (stats.isDirectory()) {
|
33741
|
+
rmdir(p, options, er, cb)
|
33742
|
+
} else {
|
33743
|
+
options.unlink(p, cb)
|
33744
|
+
}
|
33745
|
+
})
|
33746
|
+
}
|
33747
|
+
})
|
33748
|
+
}
|
33749
|
+
|
33750
|
+
function fixWinEPERMSync (p, options, er) {
|
33751
|
+
let stats
|
33752
|
+
|
33753
|
+
assert(p)
|
33754
|
+
assert(options)
|
33755
|
+
|
33756
|
+
try {
|
33757
|
+
options.chmodSync(p, 0o666)
|
33758
|
+
} catch (er2) {
|
33759
|
+
if (er2.code === 'ENOENT') {
|
33760
|
+
return
|
33761
|
+
} else {
|
33762
|
+
throw er
|
33763
|
+
}
|
33764
|
+
}
|
33765
|
+
|
33766
|
+
try {
|
33767
|
+
stats = options.statSync(p)
|
33768
|
+
} catch (er3) {
|
33769
|
+
if (er3.code === 'ENOENT') {
|
33770
|
+
return
|
33771
|
+
} else {
|
33772
|
+
throw er
|
33773
|
+
}
|
33774
|
+
}
|
33775
|
+
|
33776
|
+
if (stats.isDirectory()) {
|
33777
|
+
rmdirSync(p, options, er)
|
33778
|
+
} else {
|
33779
|
+
options.unlinkSync(p)
|
33780
|
+
}
|
33781
|
+
}
|
33782
|
+
|
33783
|
+
function rmdir (p, options, originalEr, cb) {
|
33784
|
+
assert(p)
|
33785
|
+
assert(options)
|
33786
|
+
assert(typeof cb === 'function')
|
33787
|
+
|
33788
|
+
// try to rmdir first, and only readdir on ENOTEMPTY or EEXIST (SunOS)
|
33789
|
+
// if we guessed wrong, and it's not a directory, then
|
33790
|
+
// raise the original error.
|
33791
|
+
options.rmdir(p, er => {
|
33792
|
+
if (er && (er.code === 'ENOTEMPTY' || er.code === 'EEXIST' || er.code === 'EPERM')) {
|
33793
|
+
rmkids(p, options, cb)
|
33794
|
+
} else if (er && er.code === 'ENOTDIR') {
|
33795
|
+
cb(originalEr)
|
33796
|
+
} else {
|
33797
|
+
cb(er)
|
33798
|
+
}
|
33799
|
+
})
|
33800
|
+
}
|
33801
|
+
|
33802
|
+
function rmkids (p, options, cb) {
|
33803
|
+
assert(p)
|
33804
|
+
assert(options)
|
33805
|
+
assert(typeof cb === 'function')
|
33806
|
+
|
33807
|
+
options.readdir(p, (er, files) => {
|
33808
|
+
if (er) return cb(er)
|
33809
|
+
|
33810
|
+
let n = files.length
|
33811
|
+
let errState
|
33812
|
+
|
33813
|
+
if (n === 0) return options.rmdir(p, cb)
|
33814
|
+
|
33815
|
+
files.forEach(f => {
|
33816
|
+
rimraf(path.join(p, f), options, er => {
|
33817
|
+
if (errState) {
|
33818
|
+
return
|
33819
|
+
}
|
33820
|
+
if (er) return cb(errState = er)
|
33821
|
+
if (--n === 0) {
|
33822
|
+
options.rmdir(p, cb)
|
33823
|
+
}
|
33824
|
+
})
|
33825
|
+
})
|
33826
|
+
})
|
33827
|
+
}
|
33828
|
+
|
33829
|
+
// this looks simpler, and is strictly *faster*, but will
|
33830
|
+
// tie up the JavaScript thread and fail on excessively
|
33831
|
+
// deep directory trees.
|
33832
|
+
function rimrafSync (p, options) {
|
33833
|
+
let st
|
33834
|
+
|
33835
|
+
options = options || {}
|
33836
|
+
defaults(options)
|
33837
|
+
|
33838
|
+
assert(p, 'rimraf: missing path')
|
33839
|
+
assert.strictEqual(typeof p, 'string', 'rimraf: path should be a string')
|
33840
|
+
assert(options, 'rimraf: missing options')
|
33841
|
+
assert.strictEqual(typeof options, 'object', 'rimraf: options should be object')
|
33842
|
+
|
33843
|
+
try {
|
33844
|
+
st = options.lstatSync(p)
|
33845
|
+
} catch (er) {
|
33846
|
+
if (er.code === 'ENOENT') {
|
33847
|
+
return
|
31958
33848
|
}
|
31959
33849
|
|
31960
|
-
//
|
31961
|
-
if (
|
31962
|
-
|
31963
|
-
try {
|
31964
|
-
this._options.beforeRedirect.call(null, this._options, responseDetails);
|
31965
|
-
}
|
31966
|
-
catch (err) {
|
31967
|
-
this.emit("error", err);
|
31968
|
-
return;
|
31969
|
-
}
|
31970
|
-
this._sanitizeOptions(this._options);
|
33850
|
+
// Windows can EPERM on stat. Life is suffering.
|
33851
|
+
if (er.code === 'EPERM' && isWindows) {
|
33852
|
+
fixWinEPERMSync(p, options, er)
|
31971
33853
|
}
|
33854
|
+
}
|
31972
33855
|
|
31973
|
-
|
31974
|
-
|
31975
|
-
|
33856
|
+
try {
|
33857
|
+
// sunos lets the root user unlink directories, which is... weird.
|
33858
|
+
if (st && st.isDirectory()) {
|
33859
|
+
rmdirSync(p, options, null)
|
33860
|
+
} else {
|
33861
|
+
options.unlinkSync(p)
|
31976
33862
|
}
|
31977
|
-
|
31978
|
-
|
33863
|
+
} catch (er) {
|
33864
|
+
if (er.code === 'ENOENT') {
|
33865
|
+
return
|
33866
|
+
} else if (er.code === 'EPERM') {
|
33867
|
+
return isWindows ? fixWinEPERMSync(p, options, er) : rmdirSync(p, options, er)
|
33868
|
+
} else if (er.code !== 'EISDIR') {
|
33869
|
+
throw er
|
31979
33870
|
}
|
33871
|
+
rmdirSync(p, options, er)
|
31980
33872
|
}
|
31981
|
-
|
31982
|
-
// The response is not a redirect; return it as-is
|
31983
|
-
response.responseUrl = this._currentUrl;
|
31984
|
-
response.redirects = this._redirects;
|
31985
|
-
this.emit("response", response);
|
33873
|
+
}
|
31986
33874
|
|
31987
|
-
|
31988
|
-
|
33875
|
+
function rmdirSync (p, options, originalEr) {
|
33876
|
+
assert(p)
|
33877
|
+
assert(options)
|
33878
|
+
|
33879
|
+
try {
|
33880
|
+
options.rmdirSync(p)
|
33881
|
+
} catch (er) {
|
33882
|
+
if (er.code === 'ENOTDIR') {
|
33883
|
+
throw originalEr
|
33884
|
+
} else if (er.code === 'ENOTEMPTY' || er.code === 'EEXIST' || er.code === 'EPERM') {
|
33885
|
+
rmkidsSync(p, options)
|
33886
|
+
} else if (er.code !== 'ENOENT') {
|
33887
|
+
throw er
|
33888
|
+
}
|
31989
33889
|
}
|
31990
|
-
}
|
33890
|
+
}
|
31991
33891
|
|
31992
|
-
|
31993
|
-
|
31994
|
-
|
31995
|
-
|
31996
|
-
maxRedirects: 21,
|
31997
|
-
maxBodyLength: 10 * 1024 * 1024,
|
31998
|
-
};
|
33892
|
+
function rmkidsSync (p, options) {
|
33893
|
+
assert(p)
|
33894
|
+
assert(options)
|
33895
|
+
options.readdirSync(p).forEach(f => rimrafSync(path.join(p, f), options))
|
31999
33896
|
|
32000
|
-
|
32001
|
-
|
32002
|
-
|
32003
|
-
|
32004
|
-
|
32005
|
-
|
33897
|
+
if (isWindows) {
|
33898
|
+
// We only end up here once we got ENOTEMPTY at least once, and
|
33899
|
+
// at this point, we are guaranteed to have removed all the kids.
|
33900
|
+
// So, we know that it won't be ENOENT or ENOTDIR or anything else.
|
33901
|
+
// try really hard to delete stuff on windows, because it has a
|
33902
|
+
// PROFOUNDLY annoying habit of not closing handles promptly when
|
33903
|
+
// files are deleted, resulting in spurious ENOTEMPTY errors.
|
33904
|
+
const startTime = Date.now()
|
33905
|
+
do {
|
33906
|
+
try {
|
33907
|
+
const ret = options.rmdirSync(p, options)
|
33908
|
+
return ret
|
33909
|
+
} catch {}
|
33910
|
+
} while (Date.now() - startTime < 500) // give up after 500ms
|
33911
|
+
} else {
|
33912
|
+
const ret = options.rmdirSync(p, options)
|
33913
|
+
return ret
|
33914
|
+
}
|
33915
|
+
}
|
32006
33916
|
|
32007
|
-
|
32008
|
-
|
32009
|
-
|
32010
|
-
|
32011
|
-
|
32012
|
-
|
32013
|
-
|
32014
|
-
|
32015
|
-
|
32016
|
-
|
32017
|
-
|
33917
|
+
module.exports = rimraf
|
33918
|
+
rimraf.sync = rimrafSync
|
33919
|
+
|
33920
|
+
|
33921
|
+
/***/ }),
|
33922
|
+
|
33923
|
+
/***/ 31197:
|
33924
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33925
|
+
|
33926
|
+
"use strict";
|
33927
|
+
|
33928
|
+
|
33929
|
+
const fs = __webpack_require__(48085)
|
33930
|
+
const path = __webpack_require__(71017)
|
33931
|
+
const util = __webpack_require__(73837)
|
33932
|
+
|
33933
|
+
function getStats (src, dest, opts) {
|
33934
|
+
const statFunc = opts.dereference
|
33935
|
+
? (file) => fs.stat(file, { bigint: true })
|
33936
|
+
: (file) => fs.lstat(file, { bigint: true })
|
33937
|
+
return Promise.all([
|
33938
|
+
statFunc(src),
|
33939
|
+
statFunc(dest).catch(err => {
|
33940
|
+
if (err.code === 'ENOENT') return null
|
33941
|
+
throw err
|
33942
|
+
})
|
33943
|
+
]).then(([srcStat, destStat]) => ({ srcStat, destStat }))
|
33944
|
+
}
|
33945
|
+
|
33946
|
+
function getStatsSync (src, dest, opts) {
|
33947
|
+
let destStat
|
33948
|
+
const statFunc = opts.dereference
|
33949
|
+
? (file) => fs.statSync(file, { bigint: true })
|
33950
|
+
: (file) => fs.lstatSync(file, { bigint: true })
|
33951
|
+
const srcStat = statFunc(src)
|
33952
|
+
try {
|
33953
|
+
destStat = statFunc(dest)
|
33954
|
+
} catch (err) {
|
33955
|
+
if (err.code === 'ENOENT') return { srcStat, destStat: null }
|
33956
|
+
throw err
|
33957
|
+
}
|
33958
|
+
return { srcStat, destStat }
|
33959
|
+
}
|
33960
|
+
|
33961
|
+
function checkPaths (src, dest, funcName, opts, cb) {
|
33962
|
+
util.callbackify(getStats)(src, dest, opts, (err, stats) => {
|
33963
|
+
if (err) return cb(err)
|
33964
|
+
const { srcStat, destStat } = stats
|
33965
|
+
|
33966
|
+
if (destStat) {
|
33967
|
+
if (areIdentical(srcStat, destStat)) {
|
33968
|
+
const srcBaseName = path.basename(src)
|
33969
|
+
const destBaseName = path.basename(dest)
|
33970
|
+
if (funcName === 'move' &&
|
33971
|
+
srcBaseName !== destBaseName &&
|
33972
|
+
srcBaseName.toLowerCase() === destBaseName.toLowerCase()) {
|
33973
|
+
return cb(null, { srcStat, destStat, isChangingCase: true })
|
32018
33974
|
}
|
33975
|
+
return cb(new Error('Source and destination must not be the same.'))
|
32019
33976
|
}
|
32020
|
-
|
32021
|
-
|
32022
|
-
}
|
32023
|
-
else {
|
32024
|
-
callback = options;
|
32025
|
-
options = input;
|
32026
|
-
input = { protocol: protocol };
|
33977
|
+
if (srcStat.isDirectory() && !destStat.isDirectory()) {
|
33978
|
+
return cb(new Error(`Cannot overwrite non-directory '${dest}' with directory '${src}'.`))
|
32027
33979
|
}
|
32028
|
-
if (
|
32029
|
-
|
32030
|
-
options = null;
|
33980
|
+
if (!srcStat.isDirectory() && destStat.isDirectory()) {
|
33981
|
+
return cb(new Error(`Cannot overwrite directory '${dest}' with non-directory '${src}'.`))
|
32031
33982
|
}
|
32032
|
-
|
32033
|
-
// Set defaults
|
32034
|
-
options = Object.assign({
|
32035
|
-
maxRedirects: exports.maxRedirects,
|
32036
|
-
maxBodyLength: exports.maxBodyLength,
|
32037
|
-
}, input, options);
|
32038
|
-
options.nativeProtocols = nativeProtocols;
|
32039
|
-
|
32040
|
-
assert.equal(options.protocol, protocol, "protocol mismatch");
|
32041
|
-
debug("options", options);
|
32042
|
-
return new RedirectableRequest(options, callback);
|
32043
33983
|
}
|
32044
33984
|
|
32045
|
-
|
32046
|
-
|
32047
|
-
var wrappedRequest = wrappedProtocol.request(input, options, callback);
|
32048
|
-
wrappedRequest.end();
|
32049
|
-
return wrappedRequest;
|
33985
|
+
if (srcStat.isDirectory() && isSrcSubdir(src, dest)) {
|
33986
|
+
return cb(new Error(errMsg(src, dest, funcName)))
|
32050
33987
|
}
|
32051
|
-
|
32052
|
-
|
32053
|
-
Object.defineProperties(wrappedProtocol, {
|
32054
|
-
request: { value: request, configurable: true, enumerable: true, writable: true },
|
32055
|
-
get: { value: get, configurable: true, enumerable: true, writable: true },
|
32056
|
-
});
|
32057
|
-
});
|
32058
|
-
return exports;
|
33988
|
+
return cb(null, { srcStat, destStat })
|
33989
|
+
})
|
32059
33990
|
}
|
32060
33991
|
|
32061
|
-
|
32062
|
-
|
33992
|
+
function checkPathsSync (src, dest, funcName, opts) {
|
33993
|
+
const { srcStat, destStat } = getStatsSync(src, dest, opts)
|
32063
33994
|
|
32064
|
-
|
32065
|
-
|
32066
|
-
|
32067
|
-
|
32068
|
-
|
32069
|
-
|
32070
|
-
|
32071
|
-
|
32072
|
-
|
32073
|
-
|
32074
|
-
|
32075
|
-
|
32076
|
-
|
32077
|
-
|
32078
|
-
|
32079
|
-
|
33995
|
+
if (destStat) {
|
33996
|
+
if (areIdentical(srcStat, destStat)) {
|
33997
|
+
const srcBaseName = path.basename(src)
|
33998
|
+
const destBaseName = path.basename(dest)
|
33999
|
+
if (funcName === 'move' &&
|
34000
|
+
srcBaseName !== destBaseName &&
|
34001
|
+
srcBaseName.toLowerCase() === destBaseName.toLowerCase()) {
|
34002
|
+
return { srcStat, destStat, isChangingCase: true }
|
34003
|
+
}
|
34004
|
+
throw new Error('Source and destination must not be the same.')
|
34005
|
+
}
|
34006
|
+
if (srcStat.isDirectory() && !destStat.isDirectory()) {
|
34007
|
+
throw new Error(`Cannot overwrite non-directory '${dest}' with directory '${src}'.`)
|
34008
|
+
}
|
34009
|
+
if (!srcStat.isDirectory() && destStat.isDirectory()) {
|
34010
|
+
throw new Error(`Cannot overwrite directory '${dest}' with non-directory '${src}'.`)
|
34011
|
+
}
|
32080
34012
|
}
|
32081
|
-
return options;
|
32082
|
-
}
|
32083
34013
|
|
32084
|
-
|
32085
|
-
|
32086
|
-
for (var header in headers) {
|
32087
|
-
if (regex.test(header)) {
|
32088
|
-
lastValue = headers[header];
|
32089
|
-
delete headers[header];
|
32090
|
-
}
|
34014
|
+
if (srcStat.isDirectory() && isSrcSubdir(src, dest)) {
|
34015
|
+
throw new Error(errMsg(src, dest, funcName))
|
32091
34016
|
}
|
32092
|
-
return
|
32093
|
-
undefined : String(lastValue).trim();
|
34017
|
+
return { srcStat, destStat }
|
32094
34018
|
}
|
32095
34019
|
|
32096
|
-
|
32097
|
-
|
32098
|
-
|
32099
|
-
|
32100
|
-
|
34020
|
+
// recursively check if dest parent is a subdirectory of src.
|
34021
|
+
// It works for all file types including symlinks since it
|
34022
|
+
// checks the src and dest inodes. It starts from the deepest
|
34023
|
+
// parent and stops once it reaches the src parent or the root path.
|
34024
|
+
function checkParentPaths (src, srcStat, dest, funcName, cb) {
|
34025
|
+
const srcParent = path.resolve(path.dirname(src))
|
34026
|
+
const destParent = path.resolve(path.dirname(dest))
|
34027
|
+
if (destParent === srcParent || destParent === path.parse(destParent).root) return cb()
|
34028
|
+
fs.stat(destParent, { bigint: true }, (err, destStat) => {
|
34029
|
+
if (err) {
|
34030
|
+
if (err.code === 'ENOENT') return cb()
|
34031
|
+
return cb(err)
|
32101
34032
|
}
|
32102
|
-
|
32103
|
-
|
32104
|
-
this.cause = cause;
|
34033
|
+
if (areIdentical(srcStat, destStat)) {
|
34034
|
+
return cb(new Error(errMsg(src, dest, funcName)))
|
32105
34035
|
}
|
32106
|
-
|
32107
|
-
|
32108
|
-
CustomError.prototype.constructor = CustomError;
|
32109
|
-
CustomError.prototype.name = "Error [" + code + "]";
|
32110
|
-
CustomError.prototype.code = code;
|
32111
|
-
return CustomError;
|
34036
|
+
return checkParentPaths(src, srcStat, destParent, funcName, cb)
|
34037
|
+
})
|
32112
34038
|
}
|
32113
34039
|
|
32114
|
-
function
|
32115
|
-
|
32116
|
-
|
34040
|
+
function checkParentPathsSync (src, srcStat, dest, funcName) {
|
34041
|
+
const srcParent = path.resolve(path.dirname(src))
|
34042
|
+
const destParent = path.resolve(path.dirname(dest))
|
34043
|
+
if (destParent === srcParent || destParent === path.parse(destParent).root) return
|
34044
|
+
let destStat
|
34045
|
+
try {
|
34046
|
+
destStat = fs.statSync(destParent, { bigint: true })
|
34047
|
+
} catch (err) {
|
34048
|
+
if (err.code === 'ENOENT') return
|
34049
|
+
throw err
|
32117
34050
|
}
|
32118
|
-
|
32119
|
-
|
34051
|
+
if (areIdentical(srcStat, destStat)) {
|
34052
|
+
throw new Error(errMsg(src, dest, funcName))
|
34053
|
+
}
|
34054
|
+
return checkParentPathsSync(src, srcStat, destParent, funcName)
|
32120
34055
|
}
|
32121
34056
|
|
32122
|
-
function
|
32123
|
-
|
32124
|
-
return dot > 0 && subdomain[dot] === "." && subdomain.endsWith(domain);
|
34057
|
+
function areIdentical (srcStat, destStat) {
|
34058
|
+
return destStat.ino && destStat.dev && destStat.ino === srcStat.ino && destStat.dev === srcStat.dev
|
32125
34059
|
}
|
32126
34060
|
|
32127
|
-
//
|
32128
|
-
|
32129
|
-
|
34061
|
+
// return true if dest is a subdir of src, otherwise false.
|
34062
|
+
// It only checks the path strings.
|
34063
|
+
function isSrcSubdir (src, dest) {
|
34064
|
+
const srcArr = path.resolve(src).split(path.sep).filter(i => i)
|
34065
|
+
const destArr = path.resolve(dest).split(path.sep).filter(i => i)
|
34066
|
+
return srcArr.reduce((acc, cur, i) => acc && destArr[i] === cur, true)
|
34067
|
+
}
|
34068
|
+
|
34069
|
+
function errMsg (src, dest, funcName) {
|
34070
|
+
return `Cannot ${funcName} '${src}' to a subdirectory of itself, '${dest}'.`
|
34071
|
+
}
|
34072
|
+
|
34073
|
+
module.exports = {
|
34074
|
+
checkPaths,
|
34075
|
+
checkPathsSync,
|
34076
|
+
checkParentPaths,
|
34077
|
+
checkParentPathsSync,
|
34078
|
+
isSrcSubdir,
|
34079
|
+
areIdentical
|
34080
|
+
}
|
32130
34081
|
|
32131
34082
|
|
32132
34083
|
/***/ }),
|
32133
34084
|
|
32134
|
-
/***/
|
34085
|
+
/***/ 16333:
|
34086
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
34087
|
+
|
34088
|
+
"use strict";
|
34089
|
+
|
34090
|
+
|
34091
|
+
const fs = __webpack_require__(62204)
|
34092
|
+
|
34093
|
+
function utimesMillis (path, atime, mtime, callback) {
|
34094
|
+
// if (!HAS_MILLIS_RES) return fs.utimes(path, atime, mtime, callback)
|
34095
|
+
fs.open(path, 'r+', (err, fd) => {
|
34096
|
+
if (err) return callback(err)
|
34097
|
+
fs.futimes(fd, atime, mtime, futimesErr => {
|
34098
|
+
fs.close(fd, closeErr => {
|
34099
|
+
if (callback) callback(futimesErr || closeErr)
|
34100
|
+
})
|
34101
|
+
})
|
34102
|
+
})
|
34103
|
+
}
|
34104
|
+
|
34105
|
+
function utimesMillisSync (path, atime, mtime) {
|
34106
|
+
const fd = fs.openSync(path, 'r+')
|
34107
|
+
fs.futimesSync(fd, atime, mtime)
|
34108
|
+
return fs.closeSync(fd)
|
34109
|
+
}
|
34110
|
+
|
34111
|
+
module.exports = {
|
34112
|
+
utimesMillis,
|
34113
|
+
utimesMillisSync
|
34114
|
+
}
|
34115
|
+
|
34116
|
+
|
34117
|
+
/***/ }),
|
34118
|
+
|
34119
|
+
/***/ 16345:
|
32135
34120
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32136
34121
|
|
32137
34122
|
"use strict";
|
@@ -32139,9 +34124,9 @@ module.exports.wrap = wrap;
|
|
32139
34124
|
|
32140
34125
|
const fs = __webpack_require__(62204)
|
32141
34126
|
const path = __webpack_require__(71017)
|
32142
|
-
const mkdirsSync = (__webpack_require__(
|
32143
|
-
const utimesMillisSync = (__webpack_require__(
|
32144
|
-
const stat = __webpack_require__(
|
34127
|
+
const mkdirsSync = (__webpack_require__(59915).mkdirsSync)
|
34128
|
+
const utimesMillisSync = (__webpack_require__(88962).utimesMillisSync)
|
34129
|
+
const stat = __webpack_require__(12021)
|
32145
34130
|
|
32146
34131
|
function copySync (src, dest, opts) {
|
32147
34132
|
if (typeof opts === 'function') {
|
@@ -32305,20 +34290,7 @@ module.exports = copySync
|
|
32305
34290
|
|
32306
34291
|
/***/ }),
|
32307
34292
|
|
32308
|
-
/***/
|
32309
|
-
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32310
|
-
|
32311
|
-
"use strict";
|
32312
|
-
|
32313
|
-
|
32314
|
-
module.exports = {
|
32315
|
-
copySync: __webpack_require__(74714)
|
32316
|
-
}
|
32317
|
-
|
32318
|
-
|
32319
|
-
/***/ }),
|
32320
|
-
|
32321
|
-
/***/ 77544:
|
34293
|
+
/***/ 4266:
|
32322
34294
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32323
34295
|
|
32324
34296
|
"use strict";
|
@@ -32326,10 +34298,10 @@ module.exports = {
|
|
32326
34298
|
|
32327
34299
|
const fs = __webpack_require__(62204)
|
32328
34300
|
const path = __webpack_require__(71017)
|
32329
|
-
const mkdirs = (__webpack_require__(
|
32330
|
-
const pathExists = (__webpack_require__(
|
32331
|
-
const utimesMillis = (__webpack_require__(
|
32332
|
-
const stat = __webpack_require__(
|
34301
|
+
const mkdirs = (__webpack_require__(59915).mkdirs)
|
34302
|
+
const pathExists = (__webpack_require__(9672).pathExists)
|
34303
|
+
const utimesMillis = (__webpack_require__(88962).utimesMillis)
|
34304
|
+
const stat = __webpack_require__(12021)
|
32333
34305
|
|
32334
34306
|
function copy (src, dest, opts, cb) {
|
32335
34307
|
if (typeof opts === 'function' && !cb) {
|
@@ -32558,7 +34530,7 @@ module.exports = copy
|
|
32558
34530
|
|
32559
34531
|
/***/ }),
|
32560
34532
|
|
32561
|
-
/***/
|
34533
|
+
/***/ 1105:
|
32562
34534
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32563
34535
|
|
32564
34536
|
"use strict";
|
@@ -32566,23 +34538,24 @@ module.exports = copy
|
|
32566
34538
|
|
32567
34539
|
const u = (__webpack_require__(84357).fromCallback)
|
32568
34540
|
module.exports = {
|
32569
|
-
copy: u(__webpack_require__(
|
34541
|
+
copy: u(__webpack_require__(4266)),
|
34542
|
+
copySync: __webpack_require__(16345)
|
32570
34543
|
}
|
32571
34544
|
|
32572
34545
|
|
32573
34546
|
/***/ }),
|
32574
34547
|
|
32575
|
-
/***/
|
34548
|
+
/***/ 19102:
|
32576
34549
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32577
34550
|
|
32578
34551
|
"use strict";
|
32579
34552
|
|
32580
34553
|
|
32581
34554
|
const u = (__webpack_require__(84357).fromPromise)
|
32582
|
-
const fs = __webpack_require__(
|
34555
|
+
const fs = __webpack_require__(73664)
|
32583
34556
|
const path = __webpack_require__(71017)
|
32584
|
-
const mkdir = __webpack_require__(
|
32585
|
-
const remove = __webpack_require__(
|
34557
|
+
const mkdir = __webpack_require__(59915)
|
34558
|
+
const remove = __webpack_require__(21133)
|
32586
34559
|
|
32587
34560
|
const emptyDir = u(async function emptyDir (dir) {
|
32588
34561
|
let items
|
@@ -32619,7 +34592,7 @@ module.exports = {
|
|
32619
34592
|
|
32620
34593
|
/***/ }),
|
32621
34594
|
|
32622
|
-
/***/
|
34595
|
+
/***/ 19570:
|
32623
34596
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32624
34597
|
|
32625
34598
|
"use strict";
|
@@ -32628,7 +34601,7 @@ module.exports = {
|
|
32628
34601
|
const u = (__webpack_require__(84357).fromCallback)
|
32629
34602
|
const path = __webpack_require__(71017)
|
32630
34603
|
const fs = __webpack_require__(62204)
|
32631
|
-
const mkdir = __webpack_require__(
|
34604
|
+
const mkdir = __webpack_require__(59915)
|
32632
34605
|
|
32633
34606
|
function createFile (file, callback) {
|
32634
34607
|
function makeFile () {
|
@@ -32696,38 +34669,38 @@ module.exports = {
|
|
32696
34669
|
|
32697
34670
|
/***/ }),
|
32698
34671
|
|
32699
|
-
/***/
|
34672
|
+
/***/ 99793:
|
32700
34673
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32701
34674
|
|
32702
34675
|
"use strict";
|
32703
34676
|
|
32704
34677
|
|
32705
|
-
const
|
32706
|
-
const
|
32707
|
-
const
|
34678
|
+
const { createFile, createFileSync } = __webpack_require__(19570)
|
34679
|
+
const { createLink, createLinkSync } = __webpack_require__(19986)
|
34680
|
+
const { createSymlink, createSymlinkSync } = __webpack_require__(63762)
|
32708
34681
|
|
32709
34682
|
module.exports = {
|
32710
34683
|
// file
|
32711
|
-
createFile
|
32712
|
-
createFileSync
|
32713
|
-
ensureFile:
|
32714
|
-
ensureFileSync:
|
34684
|
+
createFile,
|
34685
|
+
createFileSync,
|
34686
|
+
ensureFile: createFile,
|
34687
|
+
ensureFileSync: createFileSync,
|
32715
34688
|
// link
|
32716
|
-
createLink
|
32717
|
-
createLinkSync
|
32718
|
-
ensureLink:
|
32719
|
-
ensureLinkSync:
|
34689
|
+
createLink,
|
34690
|
+
createLinkSync,
|
34691
|
+
ensureLink: createLink,
|
34692
|
+
ensureLinkSync: createLinkSync,
|
32720
34693
|
// symlink
|
32721
|
-
createSymlink
|
32722
|
-
createSymlinkSync
|
32723
|
-
ensureSymlink:
|
32724
|
-
ensureSymlinkSync:
|
34694
|
+
createSymlink,
|
34695
|
+
createSymlinkSync,
|
34696
|
+
ensureSymlink: createSymlink,
|
34697
|
+
ensureSymlinkSync: createSymlinkSync
|
32725
34698
|
}
|
32726
34699
|
|
32727
34700
|
|
32728
34701
|
/***/ }),
|
32729
34702
|
|
32730
|
-
/***/
|
34703
|
+
/***/ 19986:
|
32731
34704
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32732
34705
|
|
32733
34706
|
"use strict";
|
@@ -32736,9 +34709,9 @@ module.exports = {
|
|
32736
34709
|
const u = (__webpack_require__(84357).fromCallback)
|
32737
34710
|
const path = __webpack_require__(71017)
|
32738
34711
|
const fs = __webpack_require__(62204)
|
32739
|
-
const mkdir = __webpack_require__(
|
32740
|
-
const pathExists = (__webpack_require__(
|
32741
|
-
const { areIdentical } = __webpack_require__(
|
34712
|
+
const mkdir = __webpack_require__(59915)
|
34713
|
+
const pathExists = (__webpack_require__(9672).pathExists)
|
34714
|
+
const { areIdentical } = __webpack_require__(12021)
|
32742
34715
|
|
32743
34716
|
function createLink (srcpath, dstpath, callback) {
|
32744
34717
|
function makeLink (srcpath, dstpath) {
|
@@ -32799,7 +34772,7 @@ module.exports = {
|
|
32799
34772
|
|
32800
34773
|
/***/ }),
|
32801
34774
|
|
32802
|
-
/***/
|
34775
|
+
/***/ 5461:
|
32803
34776
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32804
34777
|
|
32805
34778
|
"use strict";
|
@@ -32807,7 +34780,7 @@ module.exports = {
|
|
32807
34780
|
|
32808
34781
|
const path = __webpack_require__(71017)
|
32809
34782
|
const fs = __webpack_require__(62204)
|
32810
|
-
const pathExists = (__webpack_require__(
|
34783
|
+
const pathExists = (__webpack_require__(9672).pathExists)
|
32811
34784
|
|
32812
34785
|
/**
|
32813
34786
|
* Function that returns two types of paths, one relative to symlink, and one
|
@@ -32906,7 +34879,7 @@ module.exports = {
|
|
32906
34879
|
|
32907
34880
|
/***/ }),
|
32908
34881
|
|
32909
|
-
/***/
|
34882
|
+
/***/ 95375:
|
32910
34883
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32911
34884
|
|
32912
34885
|
"use strict";
|
@@ -32945,7 +34918,7 @@ module.exports = {
|
|
32945
34918
|
|
32946
34919
|
/***/ }),
|
32947
34920
|
|
32948
|
-
/***/
|
34921
|
+
/***/ 63762:
|
32949
34922
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
32950
34923
|
|
32951
34924
|
"use strict";
|
@@ -32953,22 +34926,22 @@ module.exports = {
|
|
32953
34926
|
|
32954
34927
|
const u = (__webpack_require__(84357).fromCallback)
|
32955
34928
|
const path = __webpack_require__(71017)
|
32956
|
-
const fs = __webpack_require__(
|
32957
|
-
const _mkdirs = __webpack_require__(
|
34929
|
+
const fs = __webpack_require__(73664)
|
34930
|
+
const _mkdirs = __webpack_require__(59915)
|
32958
34931
|
const mkdirs = _mkdirs.mkdirs
|
32959
34932
|
const mkdirsSync = _mkdirs.mkdirsSync
|
32960
34933
|
|
32961
|
-
const _symlinkPaths = __webpack_require__(
|
34934
|
+
const _symlinkPaths = __webpack_require__(5461)
|
32962
34935
|
const symlinkPaths = _symlinkPaths.symlinkPaths
|
32963
34936
|
const symlinkPathsSync = _symlinkPaths.symlinkPathsSync
|
32964
34937
|
|
32965
|
-
const _symlinkType = __webpack_require__(
|
34938
|
+
const _symlinkType = __webpack_require__(95375)
|
32966
34939
|
const symlinkType = _symlinkType.symlinkType
|
32967
34940
|
const symlinkTypeSync = _symlinkType.symlinkTypeSync
|
32968
34941
|
|
32969
|
-
const pathExists = (__webpack_require__(
|
34942
|
+
const pathExists = (__webpack_require__(9672).pathExists)
|
32970
34943
|
|
32971
|
-
const { areIdentical } = __webpack_require__(
|
34944
|
+
const { areIdentical } = __webpack_require__(12021)
|
32972
34945
|
|
32973
34946
|
function createSymlink (srcpath, dstpath, type, callback) {
|
32974
34947
|
callback = (typeof type === 'function') ? type : callback
|
@@ -33035,7 +35008,7 @@ module.exports = {
|
|
33035
35008
|
|
33036
35009
|
/***/ }),
|
33037
35010
|
|
33038
|
-
/***/
|
35011
|
+
/***/ 73664:
|
33039
35012
|
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
33040
35013
|
|
33041
35014
|
"use strict";
|
@@ -33162,7 +35135,7 @@ if (typeof fs.writev === 'function') {
|
|
33162
35135
|
|
33163
35136
|
/***/ }),
|
33164
35137
|
|
33165
|
-
/***/
|
35138
|
+
/***/ 83950:
|
33166
35139
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33167
35140
|
|
33168
35141
|
"use strict";
|
@@ -33170,35 +35143,33 @@ if (typeof fs.writev === 'function') {
|
|
33170
35143
|
|
33171
35144
|
module.exports = {
|
33172
35145
|
// Export promiseified graceful-fs:
|
33173
|
-
...__webpack_require__(
|
35146
|
+
...__webpack_require__(73664),
|
33174
35147
|
// Export extra methods:
|
33175
|
-
...__webpack_require__(
|
33176
|
-
...__webpack_require__(
|
33177
|
-
...__webpack_require__(
|
33178
|
-
...__webpack_require__(
|
33179
|
-
...__webpack_require__(
|
33180
|
-
...__webpack_require__(
|
33181
|
-
...__webpack_require__(
|
33182
|
-
...__webpack_require__(
|
33183
|
-
...__webpack_require__(
|
33184
|
-
...__webpack_require__(84906),
|
33185
|
-
...__webpack_require__(13490)
|
35148
|
+
...__webpack_require__(1105),
|
35149
|
+
...__webpack_require__(19102),
|
35150
|
+
...__webpack_require__(99793),
|
35151
|
+
...__webpack_require__(37557),
|
35152
|
+
...__webpack_require__(59915),
|
35153
|
+
...__webpack_require__(14449),
|
35154
|
+
...__webpack_require__(65889),
|
35155
|
+
...__webpack_require__(9672),
|
35156
|
+
...__webpack_require__(21133)
|
33186
35157
|
}
|
33187
35158
|
|
33188
35159
|
|
33189
35160
|
/***/ }),
|
33190
35161
|
|
33191
|
-
/***/
|
35162
|
+
/***/ 37557:
|
33192
35163
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33193
35164
|
|
33194
35165
|
"use strict";
|
33195
35166
|
|
33196
35167
|
|
33197
35168
|
const u = (__webpack_require__(84357).fromPromise)
|
33198
|
-
const jsonFile = __webpack_require__(
|
35169
|
+
const jsonFile = __webpack_require__(42915)
|
33199
35170
|
|
33200
|
-
jsonFile.outputJson = u(__webpack_require__(
|
33201
|
-
jsonFile.outputJsonSync = __webpack_require__(
|
35171
|
+
jsonFile.outputJson = u(__webpack_require__(87482))
|
35172
|
+
jsonFile.outputJsonSync = __webpack_require__(48467)
|
33202
35173
|
// aliases
|
33203
35174
|
jsonFile.outputJSON = jsonFile.outputJson
|
33204
35175
|
jsonFile.outputJSONSync = jsonFile.outputJsonSync
|
@@ -33212,7 +35183,7 @@ module.exports = jsonFile
|
|
33212
35183
|
|
33213
35184
|
/***/ }),
|
33214
35185
|
|
33215
|
-
/***/
|
35186
|
+
/***/ 42915:
|
33216
35187
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33217
35188
|
|
33218
35189
|
"use strict";
|
@@ -33231,14 +35202,14 @@ module.exports = {
|
|
33231
35202
|
|
33232
35203
|
/***/ }),
|
33233
35204
|
|
33234
|
-
/***/
|
35205
|
+
/***/ 48467:
|
33235
35206
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33236
35207
|
|
33237
35208
|
"use strict";
|
33238
35209
|
|
33239
35210
|
|
33240
35211
|
const { stringify } = __webpack_require__(27546)
|
33241
|
-
const { outputFileSync } = __webpack_require__(
|
35212
|
+
const { outputFileSync } = __webpack_require__(65889)
|
33242
35213
|
|
33243
35214
|
function outputJsonSync (file, data, options) {
|
33244
35215
|
const str = stringify(data, options)
|
@@ -33251,14 +35222,14 @@ module.exports = outputJsonSync
|
|
33251
35222
|
|
33252
35223
|
/***/ }),
|
33253
35224
|
|
33254
|
-
/***/
|
35225
|
+
/***/ 87482:
|
33255
35226
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33256
35227
|
|
33257
35228
|
"use strict";
|
33258
35229
|
|
33259
35230
|
|
33260
35231
|
const { stringify } = __webpack_require__(27546)
|
33261
|
-
const { outputFile } = __webpack_require__(
|
35232
|
+
const { outputFile } = __webpack_require__(65889)
|
33262
35233
|
|
33263
35234
|
async function outputJson (file, data, options = {}) {
|
33264
35235
|
const str = stringify(data, options)
|
@@ -33271,13 +35242,13 @@ module.exports = outputJson
|
|
33271
35242
|
|
33272
35243
|
/***/ }),
|
33273
35244
|
|
33274
|
-
/***/
|
35245
|
+
/***/ 59915:
|
33275
35246
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33276
35247
|
|
33277
35248
|
"use strict";
|
33278
35249
|
|
33279
35250
|
const u = (__webpack_require__(84357).fromPromise)
|
33280
|
-
const { makeDir: _makeDir, makeDirSync } = __webpack_require__(
|
35251
|
+
const { makeDir: _makeDir, makeDirSync } = __webpack_require__(15602)
|
33281
35252
|
const makeDir = u(_makeDir)
|
33282
35253
|
|
33283
35254
|
module.exports = {
|
@@ -33293,13 +35264,13 @@ module.exports = {
|
|
33293
35264
|
|
33294
35265
|
/***/ }),
|
33295
35266
|
|
33296
|
-
/***/
|
35267
|
+
/***/ 15602:
|
33297
35268
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33298
35269
|
|
33299
35270
|
"use strict";
|
33300
35271
|
|
33301
|
-
const fs = __webpack_require__(
|
33302
|
-
const { checkPath } = __webpack_require__(
|
35272
|
+
const fs = __webpack_require__(73664)
|
35273
|
+
const { checkPath } = __webpack_require__(92751)
|
33303
35274
|
|
33304
35275
|
const getMode = options => {
|
33305
35276
|
const defaults = { mode: 0o777 }
|
@@ -33328,7 +35299,7 @@ module.exports.makeDirSync = (dir, options) => {
|
|
33328
35299
|
|
33329
35300
|
/***/ }),
|
33330
35301
|
|
33331
|
-
/***/
|
35302
|
+
/***/ 92751:
|
33332
35303
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33333
35304
|
|
33334
35305
|
"use strict";
|
@@ -33357,20 +35328,22 @@ module.exports.checkPath = function checkPath (pth) {
|
|
33357
35328
|
|
33358
35329
|
/***/ }),
|
33359
35330
|
|
33360
|
-
/***/
|
35331
|
+
/***/ 14449:
|
33361
35332
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33362
35333
|
|
33363
35334
|
"use strict";
|
33364
35335
|
|
33365
35336
|
|
35337
|
+
const u = (__webpack_require__(84357).fromCallback)
|
33366
35338
|
module.exports = {
|
33367
|
-
|
35339
|
+
move: u(__webpack_require__(10000)),
|
35340
|
+
moveSync: __webpack_require__(40665)
|
33368
35341
|
}
|
33369
35342
|
|
33370
35343
|
|
33371
35344
|
/***/ }),
|
33372
35345
|
|
33373
|
-
/***/
|
35346
|
+
/***/ 40665:
|
33374
35347
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33375
35348
|
|
33376
35349
|
"use strict";
|
@@ -33378,10 +35351,10 @@ module.exports = {
|
|
33378
35351
|
|
33379
35352
|
const fs = __webpack_require__(62204)
|
33380
35353
|
const path = __webpack_require__(71017)
|
33381
|
-
const copySync = (__webpack_require__(
|
33382
|
-
const removeSync = (__webpack_require__(
|
33383
|
-
const mkdirpSync = (__webpack_require__(
|
33384
|
-
const stat = __webpack_require__(
|
35354
|
+
const copySync = (__webpack_require__(1105).copySync)
|
35355
|
+
const removeSync = (__webpack_require__(21133).removeSync)
|
35356
|
+
const mkdirpSync = (__webpack_require__(59915).mkdirpSync)
|
35357
|
+
const stat = __webpack_require__(12021)
|
33385
35358
|
|
33386
35359
|
function moveSync (src, dest, opts) {
|
33387
35360
|
opts = opts || {}
|
@@ -33432,21 +35405,7 @@ module.exports = moveSync
|
|
33432
35405
|
|
33433
35406
|
/***/ }),
|
33434
35407
|
|
33435
|
-
/***/
|
33436
|
-
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33437
|
-
|
33438
|
-
"use strict";
|
33439
|
-
|
33440
|
-
|
33441
|
-
const u = (__webpack_require__(84357).fromCallback)
|
33442
|
-
module.exports = {
|
33443
|
-
move: u(__webpack_require__(69071))
|
33444
|
-
}
|
33445
|
-
|
33446
|
-
|
33447
|
-
/***/ }),
|
33448
|
-
|
33449
|
-
/***/ 69071:
|
35408
|
+
/***/ 10000:
|
33450
35409
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33451
35410
|
|
33452
35411
|
"use strict";
|
@@ -33454,11 +35413,11 @@ module.exports = {
|
|
33454
35413
|
|
33455
35414
|
const fs = __webpack_require__(62204)
|
33456
35415
|
const path = __webpack_require__(71017)
|
33457
|
-
const copy = (__webpack_require__(
|
33458
|
-
const remove = (__webpack_require__(
|
33459
|
-
const mkdirp = (__webpack_require__(
|
33460
|
-
const pathExists = (__webpack_require__(
|
33461
|
-
const stat = __webpack_require__(
|
35416
|
+
const copy = (__webpack_require__(1105).copy)
|
35417
|
+
const remove = (__webpack_require__(21133).remove)
|
35418
|
+
const mkdirp = (__webpack_require__(59915).mkdirp)
|
35419
|
+
const pathExists = (__webpack_require__(9672).pathExists)
|
35420
|
+
const stat = __webpack_require__(12021)
|
33462
35421
|
|
33463
35422
|
function move (src, dest, opts, cb) {
|
33464
35423
|
if (typeof opts === 'function') {
|
@@ -33527,7 +35486,7 @@ module.exports = move
|
|
33527
35486
|
|
33528
35487
|
/***/ }),
|
33529
35488
|
|
33530
|
-
/***/
|
35489
|
+
/***/ 65889:
|
33531
35490
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33532
35491
|
|
33533
35492
|
"use strict";
|
@@ -33536,8 +35495,8 @@ module.exports = move
|
|
33536
35495
|
const u = (__webpack_require__(84357).fromCallback)
|
33537
35496
|
const fs = __webpack_require__(62204)
|
33538
35497
|
const path = __webpack_require__(71017)
|
33539
|
-
const mkdir = __webpack_require__(
|
33540
|
-
const pathExists = (__webpack_require__(
|
35498
|
+
const mkdir = __webpack_require__(59915)
|
35499
|
+
const pathExists = (__webpack_require__(9672).pathExists)
|
33541
35500
|
|
33542
35501
|
function outputFile (file, data, encoding, callback) {
|
33543
35502
|
if (typeof encoding === 'function') {
|
@@ -33575,13 +35534,13 @@ module.exports = {
|
|
33575
35534
|
|
33576
35535
|
/***/ }),
|
33577
35536
|
|
33578
|
-
/***/
|
35537
|
+
/***/ 9672:
|
33579
35538
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33580
35539
|
|
33581
35540
|
"use strict";
|
33582
35541
|
|
33583
35542
|
const u = (__webpack_require__(84357).fromPromise)
|
33584
|
-
const fs = __webpack_require__(
|
35543
|
+
const fs = __webpack_require__(73664)
|
33585
35544
|
|
33586
35545
|
function pathExists (path) {
|
33587
35546
|
return fs.access(path).then(() => true).catch(() => false)
|
@@ -33595,7 +35554,7 @@ module.exports = {
|
|
33595
35554
|
|
33596
35555
|
/***/ }),
|
33597
35556
|
|
33598
|
-
/***/
|
35557
|
+
/***/ 21133:
|
33599
35558
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33600
35559
|
|
33601
35560
|
"use strict";
|
@@ -33603,7 +35562,7 @@ module.exports = {
|
|
33603
35562
|
|
33604
35563
|
const fs = __webpack_require__(62204)
|
33605
35564
|
const u = (__webpack_require__(84357).fromCallback)
|
33606
|
-
const rimraf = __webpack_require__(
|
35565
|
+
const rimraf = __webpack_require__(58088)
|
33607
35566
|
|
33608
35567
|
function remove (path, callback) {
|
33609
35568
|
// Node 14.14.0+
|
@@ -33625,7 +35584,7 @@ module.exports = {
|
|
33625
35584
|
|
33626
35585
|
/***/ }),
|
33627
35586
|
|
33628
|
-
/***/
|
35587
|
+
/***/ 58088:
|
33629
35588
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33630
35589
|
|
33631
35590
|
"use strict";
|
@@ -33935,13 +35894,13 @@ rimraf.sync = rimrafSync
|
|
33935
35894
|
|
33936
35895
|
/***/ }),
|
33937
35896
|
|
33938
|
-
/***/
|
35897
|
+
/***/ 12021:
|
33939
35898
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
33940
35899
|
|
33941
35900
|
"use strict";
|
33942
35901
|
|
33943
35902
|
|
33944
|
-
const fs = __webpack_require__(
|
35903
|
+
const fs = __webpack_require__(73664)
|
33945
35904
|
const path = __webpack_require__(71017)
|
33946
35905
|
const util = __webpack_require__(73837)
|
33947
35906
|
|
@@ -34097,7 +36056,7 @@ module.exports = {
|
|
34097
36056
|
|
34098
36057
|
/***/ }),
|
34099
36058
|
|
34100
|
-
/***/
|
36059
|
+
/***/ 88962:
|
34101
36060
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
34102
36061
|
|
34103
36062
|
"use strict";
|
@@ -82216,7 +84175,7 @@ exports.ConnectableObservable = void 0;
|
|
82216
84175
|
var Observable_1 = __webpack_require__(47082);
|
82217
84176
|
var Subscription_1 = __webpack_require__(69661);
|
82218
84177
|
var refCount_1 = __webpack_require__(75181);
|
82219
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
84178
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
82220
84179
|
var lift_1 = __webpack_require__(12370);
|
82221
84180
|
var ConnectableObservable = (function (_super) {
|
82222
84181
|
__extends(ConnectableObservable, _super);
|
@@ -82434,7 +84393,7 @@ var identity_1 = __webpack_require__(12418);
|
|
82434
84393
|
var mapOneOrManyArgs_1 = __webpack_require__(59377);
|
82435
84394
|
var args_1 = __webpack_require__(47844);
|
82436
84395
|
var createObject_1 = __webpack_require__(22573);
|
82437
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
84396
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
82438
84397
|
var executeSchedule_1 = __webpack_require__(28420);
|
82439
84398
|
function combineLatest() {
|
82440
84399
|
var args = [];
|
@@ -82652,7 +84611,7 @@ var Observable_1 = __webpack_require__(47082);
|
|
82652
84611
|
var argsArgArrayOrObject_1 = __webpack_require__(12671);
|
82653
84612
|
var innerFrom_1 = __webpack_require__(17438);
|
82654
84613
|
var args_1 = __webpack_require__(47844);
|
82655
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
84614
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
82656
84615
|
var mapOneOrManyArgs_1 = __webpack_require__(59377);
|
82657
84616
|
var createObject_1 = __webpack_require__(22573);
|
82658
84617
|
function forkJoin() {
|
@@ -83325,7 +85284,7 @@ exports.raceInit = exports.race = void 0;
|
|
83325
85284
|
var Observable_1 = __webpack_require__(47082);
|
83326
85285
|
var innerFrom_1 = __webpack_require__(17438);
|
83327
85286
|
var argsOrArgArray_1 = __webpack_require__(25796);
|
83328
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
85287
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
83329
85288
|
function race() {
|
83330
85289
|
var sources = [];
|
83331
85290
|
for (var _i = 0; _i < arguments.length; _i++) {
|
@@ -83531,7 +85490,7 @@ var Observable_1 = __webpack_require__(47082);
|
|
83531
85490
|
var innerFrom_1 = __webpack_require__(17438);
|
83532
85491
|
var argsOrArgArray_1 = __webpack_require__(25796);
|
83533
85492
|
var empty_1 = __webpack_require__(18939);
|
83534
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
85493
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
83535
85494
|
var args_1 = __webpack_require__(47844);
|
83536
85495
|
function zip() {
|
83537
85496
|
var args = [];
|
@@ -83576,7 +85535,7 @@ exports.zip = zip;
|
|
83576
85535
|
|
83577
85536
|
/***/ }),
|
83578
85537
|
|
83579
|
-
/***/
|
85538
|
+
/***/ 83028:
|
83580
85539
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
83581
85540
|
|
83582
85541
|
"use strict";
|
@@ -83664,7 +85623,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
83664
85623
|
exports.audit = void 0;
|
83665
85624
|
var lift_1 = __webpack_require__(12370);
|
83666
85625
|
var innerFrom_1 = __webpack_require__(17438);
|
83667
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
85626
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
83668
85627
|
function audit(durationSelector) {
|
83669
85628
|
return lift_1.operate(function (source, subscriber) {
|
83670
85629
|
var hasValue = false;
|
@@ -83731,7 +85690,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
83731
85690
|
exports.buffer = void 0;
|
83732
85691
|
var lift_1 = __webpack_require__(12370);
|
83733
85692
|
var noop_1 = __webpack_require__(3064);
|
83734
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
85693
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
83735
85694
|
function buffer(closingNotifier) {
|
83736
85695
|
return lift_1.operate(function (source, subscriber) {
|
83737
85696
|
var currentBuffer = [];
|
@@ -83773,7 +85732,7 @@ var __values = (this && this.__values) || function(o) {
|
|
83773
85732
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
83774
85733
|
exports.bufferCount = void 0;
|
83775
85734
|
var lift_1 = __webpack_require__(12370);
|
83776
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
85735
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
83777
85736
|
var arrRemove_1 = __webpack_require__(19503);
|
83778
85737
|
function bufferCount(bufferSize, startBufferEvery) {
|
83779
85738
|
if (startBufferEvery === void 0) { startBufferEvery = null; }
|
@@ -83866,7 +85825,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
83866
85825
|
exports.bufferTime = void 0;
|
83867
85826
|
var Subscription_1 = __webpack_require__(69661);
|
83868
85827
|
var lift_1 = __webpack_require__(12370);
|
83869
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
85828
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
83870
85829
|
var arrRemove_1 = __webpack_require__(19503);
|
83871
85830
|
var async_1 = __webpack_require__(11644);
|
83872
85831
|
var args_1 = __webpack_require__(47844);
|
@@ -83965,7 +85924,7 @@ exports.bufferToggle = void 0;
|
|
83965
85924
|
var Subscription_1 = __webpack_require__(69661);
|
83966
85925
|
var lift_1 = __webpack_require__(12370);
|
83967
85926
|
var innerFrom_1 = __webpack_require__(17438);
|
83968
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
85927
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
83969
85928
|
var noop_1 = __webpack_require__(3064);
|
83970
85929
|
var arrRemove_1 = __webpack_require__(19503);
|
83971
85930
|
function bufferToggle(openings, closingSelector) {
|
@@ -84019,7 +85978,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
84019
85978
|
exports.bufferWhen = void 0;
|
84020
85979
|
var lift_1 = __webpack_require__(12370);
|
84021
85980
|
var noop_1 = __webpack_require__(3064);
|
84022
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
85981
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
84023
85982
|
var innerFrom_1 = __webpack_require__(17438);
|
84024
85983
|
function bufferWhen(closingSelector) {
|
84025
85984
|
return lift_1.operate(function (source, subscriber) {
|
@@ -84052,7 +86011,7 @@ exports.bufferWhen = bufferWhen;
|
|
84052
86011
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
84053
86012
|
exports.catchError = void 0;
|
84054
86013
|
var innerFrom_1 = __webpack_require__(17438);
|
84055
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
86014
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
84056
86015
|
var lift_1 = __webpack_require__(12370);
|
84057
86016
|
function catchError(selector) {
|
84058
86017
|
return lift_1.operate(function (source, subscriber) {
|
@@ -84395,7 +86354,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
84395
86354
|
exports.debounce = void 0;
|
84396
86355
|
var lift_1 = __webpack_require__(12370);
|
84397
86356
|
var noop_1 = __webpack_require__(3064);
|
84398
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
86357
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
84399
86358
|
var innerFrom_1 = __webpack_require__(17438);
|
84400
86359
|
function debounce(durationSelector) {
|
84401
86360
|
return lift_1.operate(function (source, subscriber) {
|
@@ -84440,7 +86399,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
84440
86399
|
exports.debounceTime = void 0;
|
84441
86400
|
var async_1 = __webpack_require__(11644);
|
84442
86401
|
var lift_1 = __webpack_require__(12370);
|
84443
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
86402
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
84444
86403
|
function debounceTime(dueTime, scheduler) {
|
84445
86404
|
if (scheduler === void 0) { scheduler = async_1.asyncScheduler; }
|
84446
86405
|
return lift_1.operate(function (source, subscriber) {
|
@@ -84494,7 +86453,7 @@ exports.debounceTime = debounceTime;
|
|
84494
86453
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
84495
86454
|
exports.defaultIfEmpty = void 0;
|
84496
86455
|
var lift_1 = __webpack_require__(12370);
|
84497
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
86456
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
84498
86457
|
function defaultIfEmpty(defaultValue) {
|
84499
86458
|
return lift_1.operate(function (source, subscriber) {
|
84500
86459
|
var hasValue = false;
|
@@ -84568,7 +86527,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
84568
86527
|
exports.dematerialize = void 0;
|
84569
86528
|
var Notification_1 = __webpack_require__(89340);
|
84570
86529
|
var lift_1 = __webpack_require__(12370);
|
84571
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
86530
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
84572
86531
|
function dematerialize() {
|
84573
86532
|
return lift_1.operate(function (source, subscriber) {
|
84574
86533
|
source.subscribe(new OperatorSubscriber_1.OperatorSubscriber(subscriber, function (notification) { return Notification_1.observeNotification(notification, subscriber); }));
|
@@ -84587,7 +86546,7 @@ exports.dematerialize = dematerialize;
|
|
84587
86546
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
84588
86547
|
exports.distinct = void 0;
|
84589
86548
|
var lift_1 = __webpack_require__(12370);
|
84590
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
86549
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
84591
86550
|
var noop_1 = __webpack_require__(3064);
|
84592
86551
|
function distinct(keySelector, flushes) {
|
84593
86552
|
return lift_1.operate(function (source, subscriber) {
|
@@ -84616,7 +86575,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
84616
86575
|
exports.distinctUntilChanged = void 0;
|
84617
86576
|
var identity_1 = __webpack_require__(12418);
|
84618
86577
|
var lift_1 = __webpack_require__(12370);
|
84619
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
86578
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
84620
86579
|
function distinctUntilChanged(comparator, keySelector) {
|
84621
86580
|
if (keySelector === void 0) { keySelector = identity_1.identity; }
|
84622
86581
|
comparator = comparator !== null && comparator !== void 0 ? comparator : defaultCompare;
|
@@ -84733,7 +86692,7 @@ exports.endWith = endWith;
|
|
84733
86692
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
84734
86693
|
exports.every = void 0;
|
84735
86694
|
var lift_1 = __webpack_require__(12370);
|
84736
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
86695
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
84737
86696
|
function every(predicate, thisArg) {
|
84738
86697
|
return lift_1.operate(function (source, subscriber) {
|
84739
86698
|
var index = 0;
|
@@ -84775,7 +86734,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
84775
86734
|
exports.exhaustAll = void 0;
|
84776
86735
|
var lift_1 = __webpack_require__(12370);
|
84777
86736
|
var innerFrom_1 = __webpack_require__(17438);
|
84778
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
86737
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
84779
86738
|
function exhaustAll() {
|
84780
86739
|
return lift_1.operate(function (source, subscriber) {
|
84781
86740
|
var isComplete = false;
|
@@ -84808,7 +86767,7 @@ exports.exhaustMap = void 0;
|
|
84808
86767
|
var map_1 = __webpack_require__(39446);
|
84809
86768
|
var innerFrom_1 = __webpack_require__(17438);
|
84810
86769
|
var lift_1 = __webpack_require__(12370);
|
84811
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
86770
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
84812
86771
|
function exhaustMap(project, resultSelector) {
|
84813
86772
|
if (resultSelector) {
|
84814
86773
|
return function (source) {
|
@@ -84867,7 +86826,7 @@ exports.expand = expand;
|
|
84867
86826
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
84868
86827
|
exports.filter = void 0;
|
84869
86828
|
var lift_1 = __webpack_require__(12370);
|
84870
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
86829
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
84871
86830
|
function filter(predicate, thisArg) {
|
84872
86831
|
return lift_1.operate(function (source, subscriber) {
|
84873
86832
|
var index = 0;
|
@@ -84910,7 +86869,7 @@ exports.finalize = finalize;
|
|
84910
86869
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
84911
86870
|
exports.createFind = exports.find = void 0;
|
84912
86871
|
var lift_1 = __webpack_require__(12370);
|
84913
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
86872
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
84914
86873
|
function find(predicate, thisArg) {
|
84915
86874
|
return lift_1.operate(createFind(predicate, thisArg, 'value'));
|
84916
86875
|
}
|
@@ -85016,7 +86975,7 @@ var Observable_1 = __webpack_require__(47082);
|
|
85016
86975
|
var innerFrom_1 = __webpack_require__(17438);
|
85017
86976
|
var Subject_1 = __webpack_require__(15235);
|
85018
86977
|
var lift_1 = __webpack_require__(12370);
|
85019
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
86978
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
85020
86979
|
function groupBy(keySelector, elementOrOptions, duration, connector) {
|
85021
86980
|
return lift_1.operate(function (source, subscriber) {
|
85022
86981
|
var element;
|
@@ -85098,7 +87057,7 @@ var GroupBySubscriber = (function (_super) {
|
|
85098
87057
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
85099
87058
|
exports.ignoreElements = void 0;
|
85100
87059
|
var lift_1 = __webpack_require__(12370);
|
85101
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
87060
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
85102
87061
|
var noop_1 = __webpack_require__(3064);
|
85103
87062
|
function ignoreElements() {
|
85104
87063
|
return lift_1.operate(function (source, subscriber) {
|
@@ -85118,7 +87077,7 @@ exports.ignoreElements = ignoreElements;
|
|
85118
87077
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
85119
87078
|
exports.isEmpty = void 0;
|
85120
87079
|
var lift_1 = __webpack_require__(12370);
|
85121
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
87080
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
85122
87081
|
function isEmpty() {
|
85123
87082
|
return lift_1.operate(function (source, subscriber) {
|
85124
87083
|
source.subscribe(new OperatorSubscriber_1.OperatorSubscriber(subscriber, function () {
|
@@ -85187,7 +87146,7 @@ exports.last = last;
|
|
85187
87146
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
85188
87147
|
exports.map = void 0;
|
85189
87148
|
var lift_1 = __webpack_require__(12370);
|
85190
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
87149
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
85191
87150
|
function map(project, thisArg) {
|
85192
87151
|
return lift_1.operate(function (source, subscriber) {
|
85193
87152
|
var index = 0;
|
@@ -85226,7 +87185,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
85226
87185
|
exports.materialize = void 0;
|
85227
87186
|
var Notification_1 = __webpack_require__(89340);
|
85228
87187
|
var lift_1 = __webpack_require__(12370);
|
85229
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
87188
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
85230
87189
|
function materialize() {
|
85231
87190
|
return lift_1.operate(function (source, subscriber) {
|
85232
87191
|
source.subscribe(new OperatorSubscriber_1.OperatorSubscriber(subscriber, function (value) {
|
@@ -85339,7 +87298,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
85339
87298
|
exports.mergeInternals = void 0;
|
85340
87299
|
var innerFrom_1 = __webpack_require__(17438);
|
85341
87300
|
var executeSchedule_1 = __webpack_require__(28420);
|
85342
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
87301
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
85343
87302
|
function mergeInternals(source, subscriber, project, concurrent, onBeforeNext, expand, innerSubScheduler, additionalTeardown) {
|
85344
87303
|
var buffer = [];
|
85345
87304
|
var active = 0;
|
@@ -85567,7 +87526,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
85567
87526
|
exports.observeOn = void 0;
|
85568
87527
|
var executeSchedule_1 = __webpack_require__(28420);
|
85569
87528
|
var lift_1 = __webpack_require__(12370);
|
85570
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
87529
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
85571
87530
|
function observeOn(scheduler, delay) {
|
85572
87531
|
if (delay === void 0) { delay = 0; }
|
85573
87532
|
return lift_1.operate(function (source, subscriber) {
|
@@ -85610,7 +87569,7 @@ exports.onErrorResumeNext = void 0;
|
|
85610
87569
|
var lift_1 = __webpack_require__(12370);
|
85611
87570
|
var innerFrom_1 = __webpack_require__(17438);
|
85612
87571
|
var argsOrArgArray_1 = __webpack_require__(25796);
|
85613
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
87572
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
85614
87573
|
var noop_1 = __webpack_require__(3064);
|
85615
87574
|
function onErrorResumeNext() {
|
85616
87575
|
var sources = [];
|
@@ -85656,7 +87615,7 @@ exports.onErrorResumeNext = onErrorResumeNext;
|
|
85656
87615
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
85657
87616
|
exports.pairwise = void 0;
|
85658
87617
|
var lift_1 = __webpack_require__(12370);
|
85659
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
87618
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
85660
87619
|
function pairwise() {
|
85661
87620
|
return lift_1.operate(function (source, subscriber) {
|
85662
87621
|
var prev;
|
@@ -85923,7 +87882,7 @@ exports.reduce = reduce;
|
|
85923
87882
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
85924
87883
|
exports.refCount = void 0;
|
85925
87884
|
var lift_1 = __webpack_require__(12370);
|
85926
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
87885
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
85927
87886
|
function refCount() {
|
85928
87887
|
return lift_1.operate(function (source, subscriber) {
|
85929
87888
|
var connection = null;
|
@@ -85961,7 +87920,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
85961
87920
|
exports.repeat = void 0;
|
85962
87921
|
var empty_1 = __webpack_require__(18939);
|
85963
87922
|
var lift_1 = __webpack_require__(12370);
|
85964
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
87923
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
85965
87924
|
var innerFrom_1 = __webpack_require__(17438);
|
85966
87925
|
var timer_1 = __webpack_require__(64820);
|
85967
87926
|
function repeat(countOrConfig) {
|
@@ -86032,7 +87991,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
86032
87991
|
exports.repeatWhen = void 0;
|
86033
87992
|
var Subject_1 = __webpack_require__(15235);
|
86034
87993
|
var lift_1 = __webpack_require__(12370);
|
86035
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
87994
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86036
87995
|
function repeatWhen(notifier) {
|
86037
87996
|
return lift_1.operate(function (source, subscriber) {
|
86038
87997
|
var innerSub;
|
@@ -86087,7 +88046,7 @@ exports.repeatWhen = repeatWhen;
|
|
86087
88046
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
86088
88047
|
exports.retry = void 0;
|
86089
88048
|
var lift_1 = __webpack_require__(12370);
|
86090
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88049
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86091
88050
|
var identity_1 = __webpack_require__(12418);
|
86092
88051
|
var timer_1 = __webpack_require__(64820);
|
86093
88052
|
var innerFrom_1 = __webpack_require__(17438);
|
@@ -86168,7 +88127,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
86168
88127
|
exports.retryWhen = void 0;
|
86169
88128
|
var Subject_1 = __webpack_require__(15235);
|
86170
88129
|
var lift_1 = __webpack_require__(12370);
|
86171
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88130
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86172
88131
|
function retryWhen(notifier) {
|
86173
88132
|
return lift_1.operate(function (source, subscriber) {
|
86174
88133
|
var innerSub;
|
@@ -86210,7 +88169,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
86210
88169
|
exports.sample = void 0;
|
86211
88170
|
var lift_1 = __webpack_require__(12370);
|
86212
88171
|
var noop_1 = __webpack_require__(3064);
|
86213
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88172
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86214
88173
|
function sample(notifier) {
|
86215
88174
|
return lift_1.operate(function (source, subscriber) {
|
86216
88175
|
var hasValue = false;
|
@@ -86278,7 +88237,7 @@ exports.scan = scan;
|
|
86278
88237
|
|
86279
88238
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
86280
88239
|
exports.scanInternals = void 0;
|
86281
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88240
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86282
88241
|
function scanInternals(accumulator, seed, hasSeed, emitOnNext, emitBeforeComplete) {
|
86283
88242
|
return function (source, subscriber) {
|
86284
88243
|
var hasState = hasSeed;
|
@@ -86312,7 +88271,7 @@ exports.scanInternals = scanInternals;
|
|
86312
88271
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
86313
88272
|
exports.sequenceEqual = void 0;
|
86314
88273
|
var lift_1 = __webpack_require__(12370);
|
86315
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88274
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86316
88275
|
function sequenceEqual(compareTo, comparator) {
|
86317
88276
|
if (comparator === void 0) { comparator = function (a, b) { return a === b; }; }
|
86318
88277
|
return lift_1.operate(function (source, subscriber) {
|
@@ -86510,7 +88469,7 @@ var EmptyError_1 = __webpack_require__(77404);
|
|
86510
88469
|
var SequenceError_1 = __webpack_require__(28585);
|
86511
88470
|
var NotFoundError_1 = __webpack_require__(51403);
|
86512
88471
|
var lift_1 = __webpack_require__(12370);
|
86513
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88472
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86514
88473
|
function single(predicate) {
|
86515
88474
|
return lift_1.operate(function (source, subscriber) {
|
86516
88475
|
var hasValue = false;
|
@@ -86565,7 +88524,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
86565
88524
|
exports.skipLast = void 0;
|
86566
88525
|
var identity_1 = __webpack_require__(12418);
|
86567
88526
|
var lift_1 = __webpack_require__(12370);
|
86568
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88527
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86569
88528
|
function skipLast(skipCount) {
|
86570
88529
|
return skipCount <= 0
|
86571
88530
|
?
|
@@ -86603,7 +88562,7 @@ exports.skipLast = skipLast;
|
|
86603
88562
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
86604
88563
|
exports.skipUntil = void 0;
|
86605
88564
|
var lift_1 = __webpack_require__(12370);
|
86606
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88565
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86607
88566
|
var innerFrom_1 = __webpack_require__(17438);
|
86608
88567
|
var noop_1 = __webpack_require__(3064);
|
86609
88568
|
function skipUntil(notifier) {
|
@@ -86630,7 +88589,7 @@ exports.skipUntil = skipUntil;
|
|
86630
88589
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
86631
88590
|
exports.skipWhile = void 0;
|
86632
88591
|
var lift_1 = __webpack_require__(12370);
|
86633
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88592
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86634
88593
|
function skipWhile(predicate) {
|
86635
88594
|
return lift_1.operate(function (source, subscriber) {
|
86636
88595
|
var taking = false;
|
@@ -86713,7 +88672,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
86713
88672
|
exports.switchMap = void 0;
|
86714
88673
|
var innerFrom_1 = __webpack_require__(17438);
|
86715
88674
|
var lift_1 = __webpack_require__(12370);
|
86716
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88675
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86717
88676
|
function switchMap(project, resultSelector) {
|
86718
88677
|
return lift_1.operate(function (source, subscriber) {
|
86719
88678
|
var innerSubscriber = null;
|
@@ -86788,7 +88747,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
86788
88747
|
exports.take = void 0;
|
86789
88748
|
var empty_1 = __webpack_require__(18939);
|
86790
88749
|
var lift_1 = __webpack_require__(12370);
|
86791
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88750
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86792
88751
|
function take(count) {
|
86793
88752
|
return count <= 0
|
86794
88753
|
?
|
@@ -86830,7 +88789,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
86830
88789
|
exports.takeLast = void 0;
|
86831
88790
|
var empty_1 = __webpack_require__(18939);
|
86832
88791
|
var lift_1 = __webpack_require__(12370);
|
86833
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88792
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86834
88793
|
function takeLast(count) {
|
86835
88794
|
return count <= 0
|
86836
88795
|
? function () { return empty_1.EMPTY; }
|
@@ -86873,7 +88832,7 @@ exports.takeLast = takeLast;
|
|
86873
88832
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
86874
88833
|
exports.takeUntil = void 0;
|
86875
88834
|
var lift_1 = __webpack_require__(12370);
|
86876
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88835
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86877
88836
|
var innerFrom_1 = __webpack_require__(17438);
|
86878
88837
|
var noop_1 = __webpack_require__(3064);
|
86879
88838
|
function takeUntil(notifier) {
|
@@ -86895,7 +88854,7 @@ exports.takeUntil = takeUntil;
|
|
86895
88854
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
86896
88855
|
exports.takeWhile = void 0;
|
86897
88856
|
var lift_1 = __webpack_require__(12370);
|
86898
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88857
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86899
88858
|
function takeWhile(predicate, inclusive) {
|
86900
88859
|
if (inclusive === void 0) { inclusive = false; }
|
86901
88860
|
return lift_1.operate(function (source, subscriber) {
|
@@ -86921,7 +88880,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
86921
88880
|
exports.tap = void 0;
|
86922
88881
|
var isFunction_1 = __webpack_require__(44366);
|
86923
88882
|
var lift_1 = __webpack_require__(12370);
|
86924
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88883
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86925
88884
|
var identity_1 = __webpack_require__(12418);
|
86926
88885
|
function tap(observerOrNext, error, complete) {
|
86927
88886
|
var tapObserver = isFunction_1.isFunction(observerOrNext) || error || complete
|
@@ -86971,7 +88930,7 @@ exports.tap = tap;
|
|
86971
88930
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
86972
88931
|
exports.throttle = exports.defaultThrottleConfig = void 0;
|
86973
88932
|
var lift_1 = __webpack_require__(12370);
|
86974
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
88933
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
86975
88934
|
var innerFrom_1 = __webpack_require__(17438);
|
86976
88935
|
exports.defaultThrottleConfig = {
|
86977
88936
|
leading: true,
|
@@ -87054,7 +89013,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
87054
89013
|
exports.throwIfEmpty = void 0;
|
87055
89014
|
var EmptyError_1 = __webpack_require__(77404);
|
87056
89015
|
var lift_1 = __webpack_require__(12370);
|
87057
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
89016
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
87058
89017
|
function throwIfEmpty(errorFactory) {
|
87059
89018
|
if (errorFactory === void 0) { errorFactory = defaultErrorFactory; }
|
87060
89019
|
return lift_1.operate(function (source, subscriber) {
|
@@ -87127,7 +89086,7 @@ var isDate_1 = __webpack_require__(19327);
|
|
87127
89086
|
var lift_1 = __webpack_require__(12370);
|
87128
89087
|
var innerFrom_1 = __webpack_require__(17438);
|
87129
89088
|
var createErrorClass_1 = __webpack_require__(92589);
|
87130
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
89089
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
87131
89090
|
var executeSchedule_1 = __webpack_require__(28420);
|
87132
89091
|
exports.TimeoutError = createErrorClass_1.createErrorClass(function (_super) {
|
87133
89092
|
return function TimeoutErrorImpl(info) {
|
@@ -87278,7 +89237,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
87278
89237
|
exports.window = void 0;
|
87279
89238
|
var Subject_1 = __webpack_require__(15235);
|
87280
89239
|
var lift_1 = __webpack_require__(12370);
|
87281
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
89240
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
87282
89241
|
var noop_1 = __webpack_require__(3064);
|
87283
89242
|
function window(windowBoundaries) {
|
87284
89243
|
return lift_1.operate(function (source, subscriber) {
|
@@ -87327,7 +89286,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
87327
89286
|
exports.windowCount = void 0;
|
87328
89287
|
var Subject_1 = __webpack_require__(15235);
|
87329
89288
|
var lift_1 = __webpack_require__(12370);
|
87330
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
89289
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
87331
89290
|
function windowCount(windowSize, startWindowEvery) {
|
87332
89291
|
if (startWindowEvery === void 0) { startWindowEvery = 0; }
|
87333
89292
|
var startEvery = startWindowEvery > 0 ? startWindowEvery : windowSize;
|
@@ -87392,7 +89351,7 @@ var Subject_1 = __webpack_require__(15235);
|
|
87392
89351
|
var async_1 = __webpack_require__(11644);
|
87393
89352
|
var Subscription_1 = __webpack_require__(69661);
|
87394
89353
|
var lift_1 = __webpack_require__(12370);
|
87395
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
89354
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
87396
89355
|
var arrRemove_1 = __webpack_require__(19503);
|
87397
89356
|
var args_1 = __webpack_require__(47844);
|
87398
89357
|
var executeSchedule_1 = __webpack_require__(28420);
|
@@ -87484,7 +89443,7 @@ var Subject_1 = __webpack_require__(15235);
|
|
87484
89443
|
var Subscription_1 = __webpack_require__(69661);
|
87485
89444
|
var lift_1 = __webpack_require__(12370);
|
87486
89445
|
var innerFrom_1 = __webpack_require__(17438);
|
87487
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
89446
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
87488
89447
|
var noop_1 = __webpack_require__(3064);
|
87489
89448
|
var arrRemove_1 = __webpack_require__(19503);
|
87490
89449
|
function windowToggle(openings, closingSelector) {
|
@@ -87558,7 +89517,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
87558
89517
|
exports.windowWhen = void 0;
|
87559
89518
|
var Subject_1 = __webpack_require__(15235);
|
87560
89519
|
var lift_1 = __webpack_require__(12370);
|
87561
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
89520
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
87562
89521
|
var innerFrom_1 = __webpack_require__(17438);
|
87563
89522
|
function windowWhen(closingSelector) {
|
87564
89523
|
return lift_1.operate(function (source, subscriber) {
|
@@ -87627,7 +89586,7 @@ var __spreadArray = (this && this.__spreadArray) || function (to, from) {
|
|
87627
89586
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
87628
89587
|
exports.withLatestFrom = void 0;
|
87629
89588
|
var lift_1 = __webpack_require__(12370);
|
87630
|
-
var OperatorSubscriber_1 = __webpack_require__(
|
89589
|
+
var OperatorSubscriber_1 = __webpack_require__(83028);
|
87631
89590
|
var innerFrom_1 = __webpack_require__(17438);
|
87632
89591
|
var identity_1 = __webpack_require__(12418);
|
87633
89592
|
var noop_1 = __webpack_require__(3064);
|
@@ -100148,11 +102107,13 @@ exports.PackageManager = PackageManager;
|
|
100148
102107
|
(function (PackageManager) {
|
100149
102108
|
PackageManager["Pnpm"] = "pnpm";
|
100150
102109
|
PackageManager["Yarn"] = "yarn";
|
102110
|
+
PackageManager["Npm"] = "npm";
|
100151
102111
|
})(PackageManager || (exports.PackageManager = PackageManager = {}));
|
100152
102112
|
|
100153
102113
|
const PackageManagerName = {
|
100154
102114
|
[PackageManager.Pnpm]: () => 'pnpm',
|
100155
|
-
[PackageManager.Yarn]: () => 'Yarn'
|
102115
|
+
[PackageManager.Yarn]: () => 'Yarn',
|
102116
|
+
[PackageManager.Npm]: () => 'npm'
|
100156
102117
|
};
|
100157
102118
|
exports.PackageManagerName = PackageManagerName;
|
100158
102119
|
const PackageManagerSchema = {
|
@@ -100161,7 +102122,7 @@ const PackageManagerSchema = {
|
|
100161
102122
|
label: () => _locale.i18n.t(_locale.localeKeys.packageManager.self),
|
100162
102123
|
mutualExclusion: true,
|
100163
102124
|
when: (_values, extra) => !(extra !== null && extra !== void 0 && extra.isMonorepoSubProject),
|
100164
|
-
items: Object.values(PackageManager).map(packageManager => ({
|
102125
|
+
items: (_values, extra) => Object.values(PackageManager).filter(packageManager => extra !== null && extra !== void 0 && extra.isMonorepo ? packageManager !== PackageManager.Npm : true).map(packageManager => ({
|
100165
102126
|
key: packageManager,
|
100166
102127
|
label: PackageManagerName[packageManager]
|
100167
102128
|
}))
|
@@ -100401,7 +102362,7 @@ const SubSolutionSchema = {
|
|
100401
102362
|
}));
|
100402
102363
|
|
100403
102364
|
if (data.solution && data.solution !== 'custom') {
|
100404
|
-
items.
|
102365
|
+
items.unshift({
|
100405
102366
|
key: data.solution,
|
100406
102367
|
label: `${SubSolutionText[data.solution]()}(${_locale.i18n.t(_locale.localeKeys.solution.default)})`
|
100407
102368
|
});
|
@@ -100684,7 +102645,9 @@ const EN_LOCALE = {
|
|
100684
102645
|
runtime_api: 'Enable "Runtime API"',
|
100685
102646
|
mwa_storybook: 'Enable "Visual Testing (Storybook)"',
|
100686
102647
|
ssg: 'Enable "SSG"',
|
100687
|
-
|
102648
|
+
polyfill: 'Enable "UA-based Polyfill feature"',
|
102649
|
+
deploy: 'Enable "Deploy"',
|
102650
|
+
proxy: 'Enable "Global Proxy"'
|
100688
102651
|
},
|
100689
102652
|
element: {
|
100690
102653
|
self: 'Create project element',
|
@@ -100849,7 +102812,9 @@ const ZH_LOCALE = {
|
|
100849
102812
|
runtime_api: '启用「Rumtime API」',
|
100850
102813
|
mwa_storybook: '启用「Visual Testing (Storybook)」模式',
|
100851
102814
|
ssg: '启用「SSG」功能',
|
100852
|
-
|
102815
|
+
polyfill: '启用「基于 UA 的 Polyfill」功能',
|
102816
|
+
deploy: '启用「部署」功能',
|
102817
|
+
proxy: '启用「全局代理」'
|
100853
102818
|
},
|
100854
102819
|
element: {
|
100855
102820
|
self: '创建工程元素',
|
@@ -101336,7 +103301,6 @@ const LambdaTypeSchema = {
|
|
101336
103301
|
type: ['string'],
|
101337
103302
|
label: () => _locale.i18n.t(_locale.localeKeys.deploy.lambda.self),
|
101338
103303
|
mutualExclusion: true,
|
101339
|
-
when: values => values.disableModernServer === _common.BooleanConfig.NO,
|
101340
103304
|
items: Object.values(LambdaType).map(deployType => ({
|
101341
103305
|
key: deployType,
|
101342
103306
|
label: () => _locale.i18n.t(_locale.localeKeys.deploy.lambda[deployType])
|
@@ -101627,7 +103591,9 @@ exports.ActionFunction = ActionFunction;
|
|
101627
103591
|
ActionFunction["Storybook"] = "storybook";
|
101628
103592
|
ActionFunction["RuntimeApi"] = "runtimeApi";
|
101629
103593
|
ActionFunction["SSG"] = "ssg";
|
103594
|
+
ActionFunction["Polyfill"] = "polyfill";
|
101630
103595
|
ActionFunction["Deploy"] = "deploy";
|
103596
|
+
ActionFunction["Proxy"] = "proxy";
|
101631
103597
|
})(ActionFunction || (exports.ActionFunction = ActionFunction = {}));
|
101632
103598
|
|
101633
103599
|
let ActionRefactor;
|
@@ -101663,7 +103629,9 @@ const ActionFunctionText = {
|
|
101663
103629
|
[ActionFunction.Storybook]: () => _locale.i18n.t(_locale.localeKeys.action.function.storybook),
|
101664
103630
|
[ActionFunction.RuntimeApi]: () => _locale.i18n.t(_locale.localeKeys.action.function.runtime_api),
|
101665
103631
|
[ActionFunction.SSG]: () => _locale.i18n.t(_locale.localeKeys.action.function.ssg),
|
101666
|
-
[ActionFunction.
|
103632
|
+
[ActionFunction.Polyfill]: () => _locale.i18n.t(_locale.localeKeys.action.function.polyfill),
|
103633
|
+
[ActionFunction.Deploy]: () => _locale.i18n.t(_locale.localeKeys.action.function.deploy),
|
103634
|
+
[ActionFunction.Proxy]: () => _locale.i18n.t(_locale.localeKeys.action.function.proxy)
|
101667
103635
|
};
|
101668
103636
|
exports.ActionFunctionText = ActionFunctionText;
|
101669
103637
|
const ActionRefactorText = {
|
@@ -101888,7 +103856,7 @@ exports.MWAActionTypes = MWAActionTypes;
|
|
101888
103856
|
const MWAActionFunctions = [_common.ActionFunction.UnBundle, _common.ActionFunction.TailwindCSS, _common.ActionFunction.Less, _common.ActionFunction.Sass, _common.ActionFunction.BFF, _common.ActionFunction.SSG, _common.ActionFunction.MicroFrontend, _common.ActionFunction.Electron, // ActionFunction.I18n,
|
101889
103857
|
_common.ActionFunction.Test, _common.ActionFunction.Storybook, // ActionFunction.E2ETest,
|
101890
103858
|
// ActionFunction.Doc,
|
101891
|
-
_common.ActionFunction.Deploy];
|
103859
|
+
_common.ActionFunction.Polyfill, _common.ActionFunction.Deploy, _common.ActionFunction.Proxy];
|
101892
103860
|
exports.MWAActionFunctions = MWAActionFunctions;
|
101893
103861
|
const MWAActionElements = [_common.ActionElement.Entry, _common.ActionElement.Server];
|
101894
103862
|
exports.MWAActionElements = MWAActionElements;
|
@@ -101935,21 +103903,23 @@ const MWAActionFunctionsDevDependencies = {
|
|
101935
103903
|
[_common.ActionFunction.E2ETest]: '@modern-js/plugin-e2e',
|
101936
103904
|
[_common.ActionFunction.Doc]: '@modern-js/plugin-docsite',
|
101937
103905
|
[_common.ActionFunction.Electron]: '@modern-js/plugin-electron',
|
101938
|
-
[_common.ActionFunction.Storybook]: '@modern-js/plugin-storybook'
|
103906
|
+
[_common.ActionFunction.Storybook]: '@modern-js/plugin-storybook',
|
103907
|
+
[_common.ActionFunction.Proxy]: '@modern-js/plugin-proxy'
|
101939
103908
|
};
|
101940
103909
|
exports.MWAActionFunctionsDevDependencies = MWAActionFunctionsDevDependencies;
|
101941
103910
|
const MWAActionFunctionsDependencies = {
|
101942
103911
|
[_common.ActionFunction.Less]: '@modern-js/plugin-less',
|
101943
103912
|
[_common.ActionFunction.Sass]: '@modern-js/plugin-sass',
|
101944
103913
|
[_common.ActionFunction.BFF]: '@modern-js/plugin-bff',
|
101945
|
-
[_common.ActionFunction.MicroFrontend]: '@modern-js/plugin-
|
103914
|
+
[_common.ActionFunction.MicroFrontend]: '@modern-js/plugin-garfish',
|
101946
103915
|
[_common.ActionFunction.I18n]: '@modern-js/plugin-i18n',
|
101947
|
-
[_common.ActionFunction.SSG]: '@modern-js/plugin-ssg'
|
103916
|
+
[_common.ActionFunction.SSG]: '@modern-js/plugin-ssg',
|
103917
|
+
[_common.ActionFunction.Polyfill]: '@modern-js/plugin-polyfill'
|
101948
103918
|
};
|
101949
103919
|
exports.MWAActionFunctionsDependencies = MWAActionFunctionsDependencies;
|
101950
103920
|
const MWAActionFunctionsAppendTypeContent = {
|
101951
103921
|
[_common.ActionFunction.Test]: `/// <reference types='@modern-js/plugin-testing/type' />`,
|
101952
|
-
[_common.ActionFunction.MicroFrontend]: `/// <reference types='@modern-js/plugin-
|
103922
|
+
[_common.ActionFunction.MicroFrontend]: `/// <reference types='@modern-js/plugin-garfish/type' />`
|
101953
103923
|
};
|
101954
103924
|
exports.MWAActionFunctionsAppendTypeContent = MWAActionFunctionsAppendTypeContent;
|
101955
103925
|
const MWANewActionGenerators = {
|
@@ -101971,7 +103941,9 @@ const MWANewActionGenerators = {
|
|
101971
103941
|
[_common.ActionFunction.Doc]: '@modern-js/dependence-generator',
|
101972
103942
|
[_common.ActionFunction.Storybook]: '@modern-js/dependence-generator',
|
101973
103943
|
[_common.ActionFunction.SSG]: '@modern-js/ssg-generator',
|
101974
|
-
[_common.ActionFunction.
|
103944
|
+
[_common.ActionFunction.Polyfill]: '@modern-js/dependence-generator',
|
103945
|
+
[_common.ActionFunction.Deploy]: '@modern-js/cloud-deploy-generator',
|
103946
|
+
[_common.ActionFunction.Proxy]: '@modern-js/dependence-generator'
|
101975
103947
|
},
|
101976
103948
|
[_common.ActionType.Refactor]: {
|
101977
103949
|
[_common.ActionRefactor.BFFToApp]: '@modern-js/bff-refactor-generator'
|
@@ -101981,7 +103953,7 @@ exports.MWANewActionGenerators = MWANewActionGenerators;
|
|
101981
103953
|
|
101982
103954
|
/***/ }),
|
101983
103955
|
|
101984
|
-
/***/
|
103956
|
+
/***/ 82022:
|
101985
103957
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
101986
103958
|
|
101987
103959
|
"use strict";
|
@@ -102018,7 +103990,7 @@ __webpack_require__.d(handlers_namespaceObject, {
|
|
102018
103990
|
"rootNode": () => (rootNode)
|
102019
103991
|
});
|
102020
103992
|
|
102021
|
-
// NAMESPACE OBJECT: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.
|
103993
|
+
// NAMESPACE OBJECT: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.8/node_modules/@modern-js/codesmith-api-app/dist/js/modern/handlers/index.js
|
102022
103994
|
var modern_handlers_namespaceObject = {};
|
102023
103995
|
__webpack_require__.r(modern_handlers_namespaceObject);
|
102024
103996
|
__webpack_require__.d(modern_handlers_namespaceObject, {
|
@@ -102237,7 +104209,9 @@ const zh_ZH_LOCALE = {
|
|
102237
104209
|
runtime_api: '启用「Rumtime API」',
|
102238
104210
|
mwa_storybook: '启用「Visual Testing (Storybook)」模式',
|
102239
104211
|
ssg: '启用「SSG」功能',
|
102240
|
-
|
104212
|
+
polyfill: '启用「基于 UA 的 Polyfill」功能',
|
104213
|
+
deploy: '启用「部署」功能',
|
104214
|
+
proxy: '启用「全局代理」'
|
102241
104215
|
},
|
102242
104216
|
element: {
|
102243
104217
|
self: '创建工程元素',
|
@@ -102364,7 +104338,9 @@ const en_EN_LOCALE = {
|
|
102364
104338
|
runtime_api: 'Enable "Runtime API"',
|
102365
104339
|
mwa_storybook: 'Enable "Visual Testing (Storybook)"',
|
102366
104340
|
ssg: 'Enable "SSG"',
|
102367
|
-
|
104341
|
+
polyfill: 'Enable "UA-based Polyfill feature"',
|
104342
|
+
deploy: 'Enable "Deploy"',
|
104343
|
+
proxy: 'Enable "Global Proxy"'
|
102368
104344
|
},
|
102369
104345
|
element: {
|
102370
104346
|
self: 'Create project element',
|
@@ -102467,11 +104443,13 @@ let PackageManager;
|
|
102467
104443
|
(function (PackageManager) {
|
102468
104444
|
PackageManager["Pnpm"] = "pnpm";
|
102469
104445
|
PackageManager["Yarn"] = "yarn";
|
104446
|
+
PackageManager["Npm"] = "npm";
|
102470
104447
|
})(PackageManager || (PackageManager = {}));
|
102471
104448
|
|
102472
104449
|
const PackageManagerName = {
|
102473
104450
|
[PackageManager.Pnpm]: () => 'pnpm',
|
102474
|
-
[PackageManager.Yarn]: () => 'Yarn'
|
104451
|
+
[PackageManager.Yarn]: () => 'Yarn',
|
104452
|
+
[PackageManager.Npm]: () => 'npm'
|
102475
104453
|
};
|
102476
104454
|
const PackageManagerSchema = {
|
102477
104455
|
key: 'packageManager',
|
@@ -102479,7 +104457,7 @@ const PackageManagerSchema = {
|
|
102479
104457
|
label: () => modern_locale_i18n.t(modern_locale_localeKeys.packageManager.self),
|
102480
104458
|
mutualExclusion: true,
|
102481
104459
|
when: (_values, extra) => !(extra !== null && extra !== void 0 && extra.isMonorepoSubProject),
|
102482
|
-
items: Object.values(PackageManager).map(packageManager => ({
|
104460
|
+
items: (_values, extra) => Object.values(PackageManager).filter(packageManager => extra !== null && extra !== void 0 && extra.isMonorepo ? packageManager !== PackageManager.Npm : true).map(packageManager => ({
|
102483
104461
|
key: packageManager,
|
102484
104462
|
label: PackageManagerName[packageManager]
|
102485
104463
|
}))
|
@@ -102623,7 +104601,7 @@ const SubSolutionSchema = {
|
|
102623
104601
|
}));
|
102624
104602
|
|
102625
104603
|
if (data.solution && data.solution !== 'custom') {
|
102626
|
-
items.
|
104604
|
+
items.unshift({
|
102627
104605
|
key: data.solution,
|
102628
104606
|
label: `${SubSolutionText[data.solution]()}(${modern_locale_i18n.t(modern_locale_localeKeys.solution["default"])})`
|
102629
104607
|
});
|
@@ -103046,6 +105024,9 @@ class JsonAPI {
|
|
103046
105024
|
// EXTERNAL MODULE: ../../../../node_modules/.pnpm/glob-promise@4.2.2_glob@7.2.0/node_modules/glob-promise/lib/index.js
|
103047
105025
|
var glob_promise_lib = __webpack_require__(39646);
|
103048
105026
|
var glob_promise_lib_default = /*#__PURE__*/__webpack_require__.n(glob_promise_lib);
|
105027
|
+
// EXTERNAL MODULE: ../../../../node_modules/.pnpm/fs-extra@10.0.1/node_modules/fs-extra/lib/index.js
|
105028
|
+
var fs_extra_lib = __webpack_require__(83950);
|
105029
|
+
var fs_extra_lib_default = /*#__PURE__*/__webpack_require__.n(fs_extra_lib);
|
103049
105030
|
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith@1.0.8/node_modules/@modern-js/codesmith/dist/js/modern/materials/constants.js
|
103050
105031
|
const IMAGE_EXT_LIST = ['.jpg', '.jpeg', '.png', '.gif', '.bmp', '.ico', '.icon', '.mpt', '.psd', '.wmf'];
|
103051
105032
|
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith@1.0.8/node_modules/@modern-js/codesmith/dist/js/modern/materials/FsResource.js
|
@@ -103066,12 +105047,12 @@ class FsResource {
|
|
103066
105047
|
const resourceFileExt = external_path_default().extname(this.filePath);
|
103067
105048
|
|
103068
105049
|
if (IMAGE_EXT_LIST.includes(resourceFileExt)) {
|
103069
|
-
const buffer = await
|
105050
|
+
const buffer = await fs_extra_lib_default().readFile(external_path_default().resolve(this.filePath));
|
103070
105051
|
return {
|
103071
105052
|
content: buffer
|
103072
105053
|
};
|
103073
105054
|
} else {
|
103074
|
-
const text = await
|
105055
|
+
const text = await fs_extra_lib_default().readFile(external_path_default().resolve(this.filePath), 'utf8');
|
103075
105056
|
return {
|
103076
105057
|
content: text
|
103077
105058
|
};
|
@@ -103603,13 +105584,14 @@ var PluginFileAPI = /*#__PURE__*/function () {
|
|
103603
105584
|
while (1) {
|
103604
105585
|
switch (_context4.prev = _context4.next) {
|
103605
105586
|
case 0:
|
103606
|
-
update =
|
103607
|
-
|
105587
|
+
update = {};
|
105588
|
+
Object.keys(updateInfo).forEach(function (key) {
|
105589
|
+
update["modernConfig.".concat(key)] = updateInfo[key];
|
103608
105590
|
});
|
103609
|
-
_context4.next =
|
105591
|
+
_context4.next = 4;
|
103610
105592
|
return this.updateJSONFile('package.json', update);
|
103611
105593
|
|
103612
|
-
case
|
105594
|
+
case 4:
|
103613
105595
|
case "end":
|
103614
105596
|
return _context4.stop();
|
103615
105597
|
}
|
@@ -104700,7 +106682,9 @@ let ActionFunction;
|
|
104700
106682
|
ActionFunction["Storybook"] = "storybook";
|
104701
106683
|
ActionFunction["RuntimeApi"] = "runtimeApi";
|
104702
106684
|
ActionFunction["SSG"] = "ssg";
|
106685
|
+
ActionFunction["Polyfill"] = "polyfill";
|
104703
106686
|
ActionFunction["Deploy"] = "deploy";
|
106687
|
+
ActionFunction["Proxy"] = "proxy";
|
104704
106688
|
})(ActionFunction || (ActionFunction = {}));
|
104705
106689
|
|
104706
106690
|
let ActionRefactor;
|
@@ -104733,7 +106717,9 @@ const ActionFunctionText = {
|
|
104733
106717
|
[ActionFunction.Storybook]: () => modern_locale_i18n.t(modern_locale_localeKeys.action["function"].storybook),
|
104734
106718
|
[ActionFunction.RuntimeApi]: () => modern_locale_i18n.t(modern_locale_localeKeys.action["function"].runtime_api),
|
104735
106719
|
[ActionFunction.SSG]: () => modern_locale_i18n.t(modern_locale_localeKeys.action["function"].ssg),
|
104736
|
-
[ActionFunction.
|
106720
|
+
[ActionFunction.Polyfill]: () => modern_locale_i18n.t(modern_locale_localeKeys.action["function"].polyfill),
|
106721
|
+
[ActionFunction.Deploy]: () => modern_locale_i18n.t(modern_locale_localeKeys.action["function"].deploy),
|
106722
|
+
[ActionFunction.Proxy]: () => modern_locale_i18n.t(modern_locale_localeKeys.action["function"].proxy)
|
104737
106723
|
};
|
104738
106724
|
const ActionRefactorText = {
|
104739
106725
|
[ActionRefactor.BFFToApp]: () => modern_locale_i18n.t(modern_locale_localeKeys.action.refactor.bff_to_app)
|
@@ -104751,7 +106737,7 @@ const MWAActionTypes = [ActionType.Element, ActionType.Function // ActionType.Re
|
|
104751
106737
|
const MWAActionFunctions = [ActionFunction.UnBundle, ActionFunction.TailwindCSS, ActionFunction.Less, ActionFunction.Sass, ActionFunction.BFF, ActionFunction.SSG, ActionFunction.MicroFrontend, ActionFunction.Electron, // ActionFunction.I18n,
|
104752
106738
|
ActionFunction.Test, ActionFunction.Storybook, // ActionFunction.E2ETest,
|
104753
106739
|
// ActionFunction.Doc,
|
104754
|
-
ActionFunction.Deploy];
|
106740
|
+
ActionFunction.Polyfill, ActionFunction.Deploy, ActionFunction.Proxy];
|
104755
106741
|
const MWAActionElements = [ActionElement.Entry, ActionElement.Server];
|
104756
106742
|
const MWAActionReactors = [ActionRefactor.BFFToApp];
|
104757
106743
|
const MWAActionTypesMap = {
|
@@ -104792,19 +106778,21 @@ const MWAActionFunctionsDevDependencies = {
|
|
104792
106778
|
[ActionFunction.E2ETest]: '@modern-js/plugin-e2e',
|
104793
106779
|
[ActionFunction.Doc]: '@modern-js/plugin-docsite',
|
104794
106780
|
[ActionFunction.Electron]: '@modern-js/plugin-electron',
|
104795
|
-
[ActionFunction.Storybook]: '@modern-js/plugin-storybook'
|
106781
|
+
[ActionFunction.Storybook]: '@modern-js/plugin-storybook',
|
106782
|
+
[ActionFunction.Proxy]: '@modern-js/plugin-proxy'
|
104796
106783
|
};
|
104797
106784
|
const MWAActionFunctionsDependencies = {
|
104798
106785
|
[ActionFunction.Less]: '@modern-js/plugin-less',
|
104799
106786
|
[ActionFunction.Sass]: '@modern-js/plugin-sass',
|
104800
106787
|
[ActionFunction.BFF]: '@modern-js/plugin-bff',
|
104801
|
-
[ActionFunction.MicroFrontend]: '@modern-js/plugin-
|
106788
|
+
[ActionFunction.MicroFrontend]: '@modern-js/plugin-garfish',
|
104802
106789
|
[ActionFunction.I18n]: '@modern-js/plugin-i18n',
|
104803
|
-
[ActionFunction.SSG]: '@modern-js/plugin-ssg'
|
106790
|
+
[ActionFunction.SSG]: '@modern-js/plugin-ssg',
|
106791
|
+
[ActionFunction.Polyfill]: '@modern-js/plugin-polyfill'
|
104804
106792
|
};
|
104805
106793
|
const MWAActionFunctionsAppendTypeContent = {
|
104806
106794
|
[ActionFunction.Test]: `/// <reference types='@modern-js/plugin-testing/type' />`,
|
104807
|
-
[ActionFunction.MicroFrontend]: `/// <reference types='@modern-js/plugin-
|
106795
|
+
[ActionFunction.MicroFrontend]: `/// <reference types='@modern-js/plugin-garfish/type' />`
|
104808
106796
|
};
|
104809
106797
|
const MWANewActionGenerators = {
|
104810
106798
|
[ActionType.Element]: {
|
@@ -104825,7 +106813,9 @@ const MWANewActionGenerators = {
|
|
104825
106813
|
[ActionFunction.Doc]: '@modern-js/dependence-generator',
|
104826
106814
|
[ActionFunction.Storybook]: '@modern-js/dependence-generator',
|
104827
106815
|
[ActionFunction.SSG]: '@modern-js/ssg-generator',
|
104828
|
-
[ActionFunction.
|
106816
|
+
[ActionFunction.Polyfill]: '@modern-js/dependence-generator',
|
106817
|
+
[ActionFunction.Deploy]: '@modern-js/cloud-deploy-generator',
|
106818
|
+
[ActionFunction.Proxy]: '@modern-js/dependence-generator'
|
104829
106819
|
},
|
104830
106820
|
[ActionType.Refactor]: {
|
104831
106821
|
[ActionRefactor.BFFToApp]: '@modern-js/bff-refactor-generator'
|
@@ -104933,7 +106923,7 @@ const nodeRequire = path => {
|
|
104933
106923
|
|
104934
106924
|
async function fsExists(path) {
|
104935
106925
|
try {
|
104936
|
-
await
|
106926
|
+
await fs_extra_lib_default().access(path);
|
104937
106927
|
return true;
|
104938
106928
|
} catch (e) {
|
104939
106929
|
return false;
|
@@ -104946,7 +106936,7 @@ async function fsExists(path) {
|
|
104946
106936
|
const MaxTimes = 5;
|
104947
106937
|
async function getGeneratorDir(generator) {
|
104948
106938
|
let result = generator;
|
104949
|
-
const isDirectory = (await
|
106939
|
+
const isDirectory = (await fs_extra_lib_default().stat(generator)).isDirectory();
|
104950
106940
|
|
104951
106941
|
if (!isDirectory) {
|
104952
106942
|
result = external_path_default().dirname(generator);
|
@@ -104993,8 +106983,8 @@ class GeneratorCore {
|
|
104993
106983
|
this.output = {
|
104994
106984
|
fs: async (file, content, options) => {
|
104995
106985
|
const filePath = external_path_default().resolve(this.outputPath, file.toString());
|
104996
|
-
await
|
104997
|
-
await
|
106986
|
+
await fs_extra_lib_default().mkdirp(external_path_default().dirname(filePath));
|
106987
|
+
await fs_extra_lib_default().writeFile(filePath, content, options);
|
104998
106988
|
}
|
104999
106989
|
};
|
105000
106990
|
this._context = void 0;
|
@@ -105393,11 +107383,11 @@ async function runInstall(targetDir, registryUrl) {
|
|
105393
107383
|
|
105394
107384
|
try {
|
105395
107385
|
const pkgPath = external_path_default().join(targetDir, 'package.json');
|
105396
|
-
const pkgJSON = JSON.parse(
|
107386
|
+
const pkgJSON = JSON.parse(fs_extra_lib_default().readFileSync(pkgPath, {
|
105397
107387
|
encoding: 'utf-8'
|
105398
107388
|
}));
|
105399
107389
|
delete pkgJSON.devDependencies;
|
105400
|
-
|
107390
|
+
fs_extra_lib_default().writeFileSync(pkgPath, JSON.stringify(pkgJSON, null, 2), {
|
105401
107391
|
encoding: 'utf-8'
|
105402
107392
|
});
|
105403
107393
|
} catch (e) {
|
@@ -105449,7 +107439,7 @@ async function isValidCache(cacheDir) {
|
|
105449
107439
|
* 2. cache time is within the validity period
|
105450
107440
|
*/
|
105451
107441
|
if (await fsExists(`${cacheDir}/.codesmith.completed`)) {
|
105452
|
-
const preCacheTimeStr = await
|
107442
|
+
const preCacheTimeStr = await fs_extra_lib_default().readFile(`${cacheDir}/.codesmith.completed`, {
|
105453
107443
|
encoding: 'utf-8'
|
105454
107444
|
});
|
105455
107445
|
const preCacheTime = preCacheTimeStr ? new Date(preCacheTimeStr) : new Date(0);
|
@@ -105479,7 +107469,7 @@ async function downloadAndDecompressTargz(tarballPkg, targetDir) {
|
|
105479
107469
|
|
105480
107470
|
const randomId = Math.floor(Math.random() * 10000);
|
105481
107471
|
const tempTgzFilePath = `${external_os_default().tmpdir()}/temp-${randomId}.tgz`;
|
105482
|
-
const dest =
|
107472
|
+
const dest = fs_extra_lib_default().createWriteStream(tempTgzFilePath);
|
105483
107473
|
await new Promise((resolve, reject) => {
|
105484
107474
|
response.data.pipe(dest);
|
105485
107475
|
response.data.on('error', err => {
|
@@ -105490,12 +107480,12 @@ async function downloadAndDecompressTargz(tarballPkg, targetDir) {
|
|
105490
107480
|
});
|
105491
107481
|
});
|
105492
107482
|
|
105493
|
-
if ((await
|
107483
|
+
if ((await fs_extra_lib_default().stat(tempTgzFilePath)).size !== contentLength) {
|
105494
107484
|
throw new Error('download tar package get bad content length');
|
105495
107485
|
}
|
105496
107486
|
|
105497
107487
|
await new Promise((resolve, reject) => {
|
105498
|
-
|
107488
|
+
fs_extra_lib_default().createReadStream(tempTgzFilePath).pipe(tar.x({
|
105499
107489
|
strip: 1,
|
105500
107490
|
C: `${targetDir}`
|
105501
107491
|
})).on('finish', () => {
|
@@ -105535,8 +107525,8 @@ async function downloadPackage(pkgName, pkgVersion = 'latest', options = {}) {
|
|
105535
107525
|
return targetDir;
|
105536
107526
|
}
|
105537
107527
|
|
105538
|
-
await
|
105539
|
-
await
|
107528
|
+
await fs_extra_lib_default().remove(targetDir);
|
107529
|
+
await fs_extra_lib_default().mkdirp(targetDir); // get package tarball
|
105540
107530
|
|
105541
107531
|
const tarballPkg = await getNpmTarballUrl(pkgName, version, {
|
105542
107532
|
registryUrl
|
@@ -105549,7 +107539,7 @@ async function downloadPackage(pkgName, pkgVersion = 'latest', options = {}) {
|
|
105549
107539
|
} // write completed flag
|
105550
107540
|
|
105551
107541
|
|
105552
|
-
await
|
107542
|
+
await fs_extra_lib_default().writeFile(`${targetDir}/.codesmith.completed`, new Date().toISOString(), {
|
105553
107543
|
encoding: 'utf-8'
|
105554
107544
|
});
|
105555
107545
|
return targetDir;
|
@@ -107342,7 +109332,7 @@ setCliQuestionsHandlers(handlers_namespaceObject);
|
|
107342
109332
|
// EXTERNAL MODULE: ../../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isUndefined.js
|
107343
109333
|
var isUndefined = __webpack_require__(88066);
|
107344
109334
|
var isUndefined_default = /*#__PURE__*/__webpack_require__.n(isUndefined);
|
107345
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.
|
109335
|
+
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.8/node_modules/@modern-js/codesmith-api-app/dist/js/modern/utils/transformSchema.js
|
107346
109336
|
|
107347
109337
|
|
107348
109338
|
function transformSchema(schema, configValue = {}, validateMap = {}) {
|
@@ -107609,7 +109599,7 @@ class List extends (base_default()) {
|
|
107609
109599
|
}
|
107610
109600
|
|
107611
109601
|
}
|
107612
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.
|
109602
|
+
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.8/node_modules/@modern-js/codesmith-api-app/dist/js/modern/handlers/constant.js
|
107613
109603
|
function constant_ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
107614
109604
|
|
107615
109605
|
function constant_objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? constant_ownKeys(Object(source), !0).forEach(function (key) { constant_defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : constant_ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
@@ -107618,7 +109608,7 @@ function constant_defineProperty(obj, key, value) { if (key in obj) { Object.def
|
|
107618
109608
|
|
107619
109609
|
|
107620
109610
|
const constant_CLI_TYPE = constant_objectSpread({}, CLI_TYPE);
|
107621
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.
|
109611
|
+
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.8/node_modules/@modern-js/codesmith-api-app/dist/js/modern/handlers/ListNode.js
|
107622
109612
|
|
107623
109613
|
|
107624
109614
|
|
@@ -107700,9 +109690,9 @@ const ListNode_listNode = options => {
|
|
107700
109690
|
return true;
|
107701
109691
|
};
|
107702
109692
|
};
|
107703
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.
|
109693
|
+
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.8/node_modules/@modern-js/codesmith-api-app/dist/js/modern/handlers/index.js
|
107704
109694
|
|
107705
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+plugin-i18n@1.
|
109695
|
+
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+plugin-i18n@1.2.2/node_modules/@modern-js/plugin-i18n/dist/js/modern/utils/index.js
|
107706
109696
|
|
107707
109697
|
|
107708
109698
|
function utils_getObjKeyMap(obj, prefix = '') {
|
@@ -107716,7 +109706,7 @@ function utils_getObjKeyMap(obj, prefix = '') {
|
|
107716
109706
|
});
|
107717
109707
|
return result;
|
107718
109708
|
}
|
107719
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+plugin-i18n@1.
|
109709
|
+
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+plugin-i18n@1.2.2/node_modules/@modern-js/plugin-i18n/dist/js/modern/index.js
|
107720
109710
|
|
107721
109711
|
|
107722
109712
|
|
@@ -107783,12 +109773,12 @@ class modern_I18n {
|
|
107783
109773
|
}
|
107784
109774
|
|
107785
109775
|
|
107786
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.
|
109776
|
+
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.8/node_modules/@modern-js/codesmith-api-app/dist/js/modern/locale/zh.js
|
107787
109777
|
const locale_zh_ZH_LOCALE = {
|
107788
109778
|
environment: {
|
107789
109779
|
node_version: '请升级 Node 版本至 LIS',
|
107790
109780
|
nvm_install: '检测到环境中未安装 nvm,请先安装 nvm',
|
107791
|
-
|
109781
|
+
yarn_pnpm_npm: '检测到环境中未安装包管理工具,请先安装 yarn 或 pnpm 或 npm'
|
107792
109782
|
},
|
107793
109783
|
install: {
|
107794
109784
|
failed: '依赖自动安装失败,请手动执行 `{command}` 命令进行安装',
|
@@ -107809,12 +109799,12 @@ const locale_zh_ZH_LOCALE = {
|
|
107809
109799
|
info: '成功!'
|
107810
109800
|
}
|
107811
109801
|
};
|
107812
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.
|
109802
|
+
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.8/node_modules/@modern-js/codesmith-api-app/dist/js/modern/locale/en.js
|
107813
109803
|
const locale_en_EN_LOCALE = {
|
107814
109804
|
environment: {
|
107815
109805
|
node_version: 'please upgrade node to lts version',
|
107816
109806
|
nvm_install: 'please install nvm first',
|
107817
|
-
|
109807
|
+
yarn_pnpm_npm: 'please install yarn or pnpm or npm first'
|
107818
109808
|
},
|
107819
109809
|
install: {
|
107820
109810
|
failed: 'dependencies install failed, please execute `{command}` to install the dependencies ',
|
@@ -107835,7 +109825,7 @@ const locale_en_EN_LOCALE = {
|
|
107835
109825
|
info: 'Success!'
|
107836
109826
|
}
|
107837
109827
|
};
|
107838
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.
|
109828
|
+
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.8/node_modules/@modern-js/codesmith-api-app/dist/js/modern/locale/index.js
|
107839
109829
|
|
107840
109830
|
|
107841
109831
|
|
@@ -107845,7 +109835,7 @@ const js_modern_locale_localeKeys = js_modern_locale_i18n.init('zh', {
|
|
107845
109835
|
en: locale_en_EN_LOCALE
|
107846
109836
|
});
|
107847
109837
|
|
107848
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.
|
109838
|
+
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.8/node_modules/@modern-js/codesmith-api-app/dist/js/modern/index.js
|
107849
109839
|
|
107850
109840
|
|
107851
109841
|
function modern_ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
@@ -107890,9 +109880,9 @@ class AppAPI {
|
|
107890
109880
|
return false;
|
107891
109881
|
}
|
107892
109882
|
|
107893
|
-
if (!(await canUseYarn()) && !(await canUsePnpm())) {
|
107894
|
-
this.generatorCore.logger.debug("can't use yarn or pnpm");
|
107895
|
-
this.generatorCore.logger.warn(js_modern_locale_i18n.t(js_modern_locale_localeKeys.environment.
|
109883
|
+
if (!(await canUseYarn()) && !(await canUsePnpm()) && !(await canUseNpm())) {
|
109884
|
+
this.generatorCore.logger.debug("can't use yarn or pnpm or npm");
|
109885
|
+
this.generatorCore.logger.warn(js_modern_locale_i18n.t(js_modern_locale_localeKeys.environment.yarn_pnpm_npm));
|
107896
109886
|
return false;
|
107897
109887
|
}
|
107898
109888
|
|
@@ -108006,15 +109996,15 @@ class AppAPI {
|
|
108006
109996
|
filePath
|
108007
109997
|
} = this.generatorContext.materials.default.get(workspaceName);
|
108008
109998
|
|
108009
|
-
if (!
|
109999
|
+
if (!fs_extra_lib_default().existsSync(filePath)) {
|
108010
110000
|
return;
|
108011
110001
|
}
|
108012
110002
|
|
108013
|
-
const content = await
|
110003
|
+
const content = await fs_extra_lib_default().readFile(filePath);
|
108014
110004
|
const workspace = (0,src.parse)(content.toString());
|
108015
110005
|
workspace.folders = [folder, ...(workspace.folders || [])];
|
108016
110006
|
const indent = 2;
|
108017
|
-
await
|
110007
|
+
await fs_extra_lib_default().writeFile(filePath, (0,src.stringify)(workspace, null, indent), {
|
108018
110008
|
encoding: 'utf-8'
|
108019
110009
|
});
|
108020
110010
|
}
|
@@ -108064,430 +110054,7 @@ class AppAPI {
|
|
108064
110054
|
}
|
108065
110055
|
|
108066
110056
|
}
|
108067
|
-
;// CONCATENATED MODULE:
|
108068
|
-
const modern_locale_zh_ZH_LOCALE = {
|
108069
|
-
solution: {
|
108070
|
-
self: '请选择你想创建的工程类型',
|
108071
|
-
mwa: '应用',
|
108072
|
-
module: '模块',
|
108073
|
-
monorepo: '项目组',
|
108074
|
-
custom: '自定义',
|
108075
|
-
default: '默认'
|
108076
|
-
},
|
108077
|
-
scenes: {
|
108078
|
-
self: '请选择项目场景'
|
108079
|
-
},
|
108080
|
-
sub_solution: {
|
108081
|
-
self: '请选择你想创建的工程类型',
|
108082
|
-
mwa: '应用',
|
108083
|
-
mwa_test: '应用(测试)',
|
108084
|
-
module: '模块',
|
108085
|
-
inner_module: '模块(内部)'
|
108086
|
-
},
|
108087
|
-
action: {
|
108088
|
-
self: '请选择你想要的操作',
|
108089
|
-
function: {
|
108090
|
-
self: '启用可选功能',
|
108091
|
-
unbundle: '启用「Unbundled 开发」模式',
|
108092
|
-
tailwindcss: '启用 Tailwind CSS 支持',
|
108093
|
-
less: '启用 Less 支持',
|
108094
|
-
sass: '启用 Sass 支持',
|
108095
|
-
bff: '启用「BFF」功能',
|
108096
|
-
micro_frontend: '启用「微前端」模式',
|
108097
|
-
electron: '启用「Electron」模式',
|
108098
|
-
i18n: '启用「国际化(i18n)」功能',
|
108099
|
-
test: '启用「单元测试 / 集成测试」功能',
|
108100
|
-
e2e_test: '启用「E2E 测试」功能',
|
108101
|
-
doc: '启用「文档站」功能',
|
108102
|
-
storybook: '启用「Storybook」',
|
108103
|
-
runtime_api: '启用「Rumtime API」',
|
108104
|
-
mwa_storybook: '启用「Visual Testing (Storybook)」模式',
|
108105
|
-
ssg: '启用「SSG」功能',
|
108106
|
-
deploy: '启用「部署」功能'
|
108107
|
-
},
|
108108
|
-
element: {
|
108109
|
-
self: '创建工程元素',
|
108110
|
-
entry: '新建「应用入口」',
|
108111
|
-
server: '新建「Server 自定义」源码目录'
|
108112
|
-
},
|
108113
|
-
refactor: {
|
108114
|
-
self: '自动重构',
|
108115
|
-
bff_to_app: 'BFF 切换框架模式'
|
108116
|
-
}
|
108117
|
-
},
|
108118
|
-
boolean: {
|
108119
|
-
yes: '是',
|
108120
|
-
no: '否'
|
108121
|
-
},
|
108122
|
-
language: {
|
108123
|
-
self: '请选择开发语言'
|
108124
|
-
},
|
108125
|
-
packageManager: {
|
108126
|
-
self: '请选择包管理工具'
|
108127
|
-
},
|
108128
|
-
runWay: {
|
108129
|
-
self: '是否需要支持以下类型应用',
|
108130
|
-
no: '不需要',
|
108131
|
-
electron: 'Electron'
|
108132
|
-
},
|
108133
|
-
needModifyConfig: {
|
108134
|
-
self: '是否需要调整默认配置?',
|
108135
|
-
enableLess: '是否启用 Less 支持?',
|
108136
|
-
enableSass: '是否启用 Sass 支持?'
|
108137
|
-
},
|
108138
|
-
entry: {
|
108139
|
-
name: '请填写入口名称',
|
108140
|
-
no_empty: '入口名称不能为空!',
|
108141
|
-
no_pages: '入口名称不支持 "pages"!',
|
108142
|
-
needModifyConfig: '是否需要调整默认配置?',
|
108143
|
-
disableStateManagement: '是否关闭「应用状态管理」功能?',
|
108144
|
-
clientRoute: {
|
108145
|
-
self: '请选择客户端路由方式',
|
108146
|
-
selfControlRoute: '启用自控路由',
|
108147
|
-
conventionalRoute: '启用约定式路由',
|
108148
|
-
no: '不启用'
|
108149
|
-
}
|
108150
|
-
},
|
108151
|
-
packageName: {
|
108152
|
-
self: '请填写项目名称',
|
108153
|
-
sub_name: '请填写子项目名称',
|
108154
|
-
no_empty: '项目名称不能为空!'
|
108155
|
-
},
|
108156
|
-
packagePath: {
|
108157
|
-
self: '请填写子项目目录名称',
|
108158
|
-
no_empty: '目录名称不能为空!',
|
108159
|
-
format: '目录名称只能使用小写字母、数字和分隔线(-)、下划线(_)和目录分隔符(/)'
|
108160
|
-
},
|
108161
|
-
framework: {
|
108162
|
-
self: '请选择运行时框架',
|
108163
|
-
egg: 'Egg',
|
108164
|
-
express: 'Express',
|
108165
|
-
koa: 'Koa',
|
108166
|
-
nest: 'Nest'
|
108167
|
-
},
|
108168
|
-
bff: {
|
108169
|
-
bffType: {
|
108170
|
-
self: '请选择 BFF 类型',
|
108171
|
-
func: '函数模式',
|
108172
|
-
framework: '框架模式'
|
108173
|
-
}
|
108174
|
-
},
|
108175
|
-
deploy: {
|
108176
|
-
cloud: {
|
108177
|
-
self: '默认使用框架内置的产品级 Web 服务器,是否调整?'
|
108178
|
-
},
|
108179
|
-
cdn: {
|
108180
|
-
self: '请选择 CDN 平台',
|
108181
|
-
oss: '阿里云 OSS',
|
108182
|
-
cos: '腾讯云 COS',
|
108183
|
-
no: '不使用 CDN'
|
108184
|
-
},
|
108185
|
-
lambda: {
|
108186
|
-
self: '请选择云函数平台',
|
108187
|
-
fc: '阿里云 FC',
|
108188
|
-
scf: '腾讯云 SCF',
|
108189
|
-
no: '不使用云函数部署'
|
108190
|
-
}
|
108191
|
-
}
|
108192
|
-
};
|
108193
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+generator-common@1.2.3/node_modules/@modern-js/generator-common/dist/js/modern/locale/en.js
|
108194
|
-
const modern_locale_en_EN_LOCALE = {
|
108195
|
-
solution: {
|
108196
|
-
self: 'Please select the solution you want to create',
|
108197
|
-
mwa: 'MWA Solution',
|
108198
|
-
module: 'Module Solution',
|
108199
|
-
monorepo: 'Monorepo Solution',
|
108200
|
-
custom: 'Custom Solution',
|
108201
|
-
default: 'Default'
|
108202
|
-
},
|
108203
|
-
scenes: {
|
108204
|
-
self: 'Please select the scense you want to create'
|
108205
|
-
},
|
108206
|
-
sub_solution: {
|
108207
|
-
self: 'Please select the solution you want to create',
|
108208
|
-
mwa: 'MWA Solution',
|
108209
|
-
mwa_test: 'MWA Solution(Test)',
|
108210
|
-
module: 'Module Solution',
|
108211
|
-
inner_module: 'Module Solution(Inner)',
|
108212
|
-
monorepo: 'Monorepo Solution'
|
108213
|
-
},
|
108214
|
-
action: {
|
108215
|
-
self: 'Action',
|
108216
|
-
function: {
|
108217
|
-
self: 'Enable features',
|
108218
|
-
unbundle: 'Enable "Unbundled Development"',
|
108219
|
-
tailwindcss: 'Enable Tailwind CSS',
|
108220
|
-
less: 'Enable Less',
|
108221
|
-
sass: 'Enable Sass',
|
108222
|
-
bff: 'Enable "BFF"',
|
108223
|
-
micro_frontend: 'Enable "micro frontend"',
|
108224
|
-
electron: 'Enable "Electron"',
|
108225
|
-
i18n: 'Enable "Internationalization (i18n)"',
|
108226
|
-
test: 'Enable "Unit Test / Integration Test"',
|
108227
|
-
e2e_test: 'Enable "E2E Test"',
|
108228
|
-
doc: 'Enable "Document Station"',
|
108229
|
-
storybook: 'Enable "Storybook"',
|
108230
|
-
runtime_api: 'Enable "Runtime API"',
|
108231
|
-
mwa_storybook: 'Enable "Visual Testing (Storybook)"',
|
108232
|
-
ssg: 'Enable "SSG"',
|
108233
|
-
deploy: 'Enable "Deploy"'
|
108234
|
-
},
|
108235
|
-
element: {
|
108236
|
-
self: 'Create project element',
|
108237
|
-
entry: 'New "entry"',
|
108238
|
-
server: 'New "Server Custom" source code directory'
|
108239
|
-
},
|
108240
|
-
refactor: {
|
108241
|
-
self: 'Automatic refactor',
|
108242
|
-
bff_to_app: 'Transform BFF to frame mode'
|
108243
|
-
}
|
108244
|
-
},
|
108245
|
-
boolean: {
|
108246
|
-
yes: 'Yes',
|
108247
|
-
no: 'No'
|
108248
|
-
},
|
108249
|
-
language: {
|
108250
|
-
self: 'Development Language'
|
108251
|
-
},
|
108252
|
-
packageManager: {
|
108253
|
-
self: 'Package Management Tool'
|
108254
|
-
},
|
108255
|
-
packageName: {
|
108256
|
-
self: 'Package Name',
|
108257
|
-
sub_name: 'Package Name',
|
108258
|
-
no_empty: 'The package name cannot be empty!'
|
108259
|
-
},
|
108260
|
-
packagePath: {
|
108261
|
-
self: 'Package Path',
|
108262
|
-
no_empty: 'The package path cannot be empty!',
|
108263
|
-
format: 'Only lowercase letters, numbers and delimiters (-), and underscore(_), and directory delimiters (/) can be used in package path.'
|
108264
|
-
},
|
108265
|
-
runWay: {
|
108266
|
-
self: 'Do you need to support the following types of applications',
|
108267
|
-
no: 'Not Enabled',
|
108268
|
-
electron: 'Electron'
|
108269
|
-
},
|
108270
|
-
needModifyConfig: {
|
108271
|
-
self: 'Modify the Default Configuration?',
|
108272
|
-
enableLess: 'Enable Less?',
|
108273
|
-
enableSass: 'Enable Sass?'
|
108274
|
-
},
|
108275
|
-
entry: {
|
108276
|
-
name: 'Entry name',
|
108277
|
-
no_empty: 'The entry name cannot be empty!',
|
108278
|
-
no_pages: 'The entry name cannot be "pages"!',
|
108279
|
-
disableStateManagement: 'Disable App State Management?',
|
108280
|
-
clientRoute: {
|
108281
|
-
self: 'Client Routing',
|
108282
|
-
selfControlRoute: 'Enable Self Control Route',
|
108283
|
-
conventionalRoute: 'Enable Conventional Route',
|
108284
|
-
no: 'Not Enabled'
|
108285
|
-
}
|
108286
|
-
},
|
108287
|
-
framework: {
|
108288
|
-
self: 'Please select the framework you want to use',
|
108289
|
-
egg: 'Egg',
|
108290
|
-
express: 'Express',
|
108291
|
-
koa: 'Koa',
|
108292
|
-
nest: 'Nest'
|
108293
|
-
},
|
108294
|
-
bff: {
|
108295
|
-
bffType: {
|
108296
|
-
self: 'BFF Type',
|
108297
|
-
func: 'Function',
|
108298
|
-
framework: 'Framework'
|
108299
|
-
}
|
108300
|
-
},
|
108301
|
-
deploy: {
|
108302
|
-
cloud: {
|
108303
|
-
self: 'Modify the default Web Server?'
|
108304
|
-
},
|
108305
|
-
cdn: {
|
108306
|
-
self: 'Please select the cdn platform you want to use',
|
108307
|
-
oss: 'Aliyun OSS',
|
108308
|
-
cos: 'Tencent COS',
|
108309
|
-
no: 'Not Enabled'
|
108310
|
-
},
|
108311
|
-
lambda: {
|
108312
|
-
self: 'Please select the lambda you want to use',
|
108313
|
-
fc: 'Aliyun FC',
|
108314
|
-
scf: 'Tencent SCF',
|
108315
|
-
no: 'Not Enabled'
|
108316
|
-
}
|
108317
|
-
}
|
108318
|
-
};
|
108319
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+generator-common@1.2.3/node_modules/@modern-js/generator-common/dist/js/modern/locale/index.js
|
108320
|
-
|
108321
|
-
|
108322
|
-
|
108323
|
-
const dist_js_modern_locale_i18n = new modern_I18n();
|
108324
|
-
const dist_js_modern_locale_localeKeys = dist_js_modern_locale_i18n.init('zh', {
|
108325
|
-
zh: modern_locale_zh_ZH_LOCALE,
|
108326
|
-
en: modern_locale_en_EN_LOCALE
|
108327
|
-
});
|
108328
|
-
|
108329
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+generator-common@1.2.3/node_modules/@modern-js/generator-common/dist/js/modern/newAction/common/index.js
|
108330
|
-
|
108331
|
-
let common_ActionType;
|
108332
|
-
|
108333
|
-
(function (ActionType) {
|
108334
|
-
ActionType["Function"] = "function";
|
108335
|
-
ActionType["Element"] = "element";
|
108336
|
-
ActionType["Refactor"] = "refactor";
|
108337
|
-
})(common_ActionType || (common_ActionType = {}));
|
108338
|
-
|
108339
|
-
let common_ActionElement;
|
108340
|
-
|
108341
|
-
(function (ActionElement) {
|
108342
|
-
ActionElement["Entry"] = "entry";
|
108343
|
-
ActionElement["Server"] = "server";
|
108344
|
-
})(common_ActionElement || (common_ActionElement = {}));
|
108345
|
-
|
108346
|
-
let common_ActionFunction;
|
108347
|
-
|
108348
|
-
(function (ActionFunction) {
|
108349
|
-
ActionFunction["UnBundle"] = "unbundle";
|
108350
|
-
ActionFunction["TailwindCSS"] = "tailwindcss";
|
108351
|
-
ActionFunction["Less"] = "less";
|
108352
|
-
ActionFunction["Sass"] = "sass";
|
108353
|
-
ActionFunction["BFF"] = "bff";
|
108354
|
-
ActionFunction["MicroFrontend"] = "micro_frontend";
|
108355
|
-
ActionFunction["Electron"] = "electron";
|
108356
|
-
ActionFunction["I18n"] = "i18n";
|
108357
|
-
ActionFunction["Test"] = "test";
|
108358
|
-
ActionFunction["E2ETest"] = "e2e_test";
|
108359
|
-
ActionFunction["Doc"] = "doc";
|
108360
|
-
ActionFunction["Storybook"] = "storybook";
|
108361
|
-
ActionFunction["RuntimeApi"] = "runtimeApi";
|
108362
|
-
ActionFunction["SSG"] = "ssg";
|
108363
|
-
ActionFunction["Deploy"] = "deploy";
|
108364
|
-
})(common_ActionFunction || (common_ActionFunction = {}));
|
108365
|
-
|
108366
|
-
let common_ActionRefactor;
|
108367
|
-
|
108368
|
-
(function (ActionRefactor) {
|
108369
|
-
ActionRefactor["BFFToApp"] = "bff_to_app";
|
108370
|
-
})(common_ActionRefactor || (common_ActionRefactor = {}));
|
108371
|
-
|
108372
|
-
const common_ActionTypeText = {
|
108373
|
-
[common_ActionType.Function]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].self),
|
108374
|
-
[common_ActionType.Element]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action.element.self),
|
108375
|
-
[common_ActionType.Refactor]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action.refactor.self)
|
108376
|
-
};
|
108377
|
-
const common_ActionElementText = {
|
108378
|
-
[common_ActionElement.Entry]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action.element.entry),
|
108379
|
-
[common_ActionElement.Server]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action.element.server)
|
108380
|
-
};
|
108381
|
-
const common_ActionFunctionText = {
|
108382
|
-
[common_ActionFunction.UnBundle]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].unbundle),
|
108383
|
-
[common_ActionFunction.TailwindCSS]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].tailwindcss),
|
108384
|
-
[common_ActionFunction.Less]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].less),
|
108385
|
-
[common_ActionFunction.Sass]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].sass),
|
108386
|
-
[common_ActionFunction.BFF]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].bff),
|
108387
|
-
[common_ActionFunction.MicroFrontend]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].micro_frontend),
|
108388
|
-
[common_ActionFunction.Electron]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].electron),
|
108389
|
-
[common_ActionFunction.I18n]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].i18n),
|
108390
|
-
[common_ActionFunction.Test]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].test),
|
108391
|
-
[common_ActionFunction.E2ETest]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].e2e_test),
|
108392
|
-
[common_ActionFunction.Doc]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].doc),
|
108393
|
-
[common_ActionFunction.Storybook]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].storybook),
|
108394
|
-
[common_ActionFunction.RuntimeApi]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].runtime_api),
|
108395
|
-
[common_ActionFunction.SSG]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].ssg),
|
108396
|
-
[common_ActionFunction.Deploy]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].deploy)
|
108397
|
-
};
|
108398
|
-
const common_ActionRefactorText = {
|
108399
|
-
[common_ActionRefactor.BFFToApp]: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action.refactor.bff_to_app)
|
108400
|
-
};
|
108401
|
-
const common_ActionTypeTextMap = {
|
108402
|
-
[common_ActionType.Element]: common_ActionElementText,
|
108403
|
-
[common_ActionType.Function]: common_ActionFunctionText,
|
108404
|
-
[common_ActionType.Refactor]: common_ActionRefactorText
|
108405
|
-
};
|
108406
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+generator-common@1.2.3/node_modules/@modern-js/generator-common/dist/js/modern/newAction/mwa/index.js
|
108407
|
-
|
108408
|
-
|
108409
|
-
const mwa_MWAActionTypes = [common_ActionType.Element, common_ActionType.Function // ActionType.Refactor,
|
108410
|
-
];
|
108411
|
-
const mwa_MWAActionFunctions = [common_ActionFunction.UnBundle, common_ActionFunction.TailwindCSS, common_ActionFunction.Less, common_ActionFunction.Sass, common_ActionFunction.BFF, common_ActionFunction.SSG, common_ActionFunction.MicroFrontend, common_ActionFunction.Electron, // ActionFunction.I18n,
|
108412
|
-
common_ActionFunction.Test, common_ActionFunction.Storybook, // ActionFunction.E2ETest,
|
108413
|
-
// ActionFunction.Doc,
|
108414
|
-
common_ActionFunction.Deploy];
|
108415
|
-
const mwa_MWAActionElements = [common_ActionElement.Entry, common_ActionElement.Server];
|
108416
|
-
const mwa_MWAActionReactors = [common_ActionRefactor.BFFToApp];
|
108417
|
-
const mwa_MWAActionTypesMap = {
|
108418
|
-
[common_ActionType.Element]: mwa_MWAActionElements,
|
108419
|
-
[common_ActionType.Function]: mwa_MWAActionFunctions,
|
108420
|
-
[common_ActionType.Refactor]: mwa_MWAActionReactors
|
108421
|
-
};
|
108422
|
-
const mwa_MWASpecialSchemaMap = {
|
108423
|
-
[common_ActionFunction.Storybook]: {
|
108424
|
-
key: common_ActionFunction.Storybook,
|
108425
|
-
label: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action["function"].mwa_storybook)
|
108426
|
-
}
|
108427
|
-
};
|
108428
|
-
const mwa_MWANewActionSchema = {
|
108429
|
-
key: 'mwa_new_action',
|
108430
|
-
isObject: true,
|
108431
|
-
items: [{
|
108432
|
-
key: 'actionType',
|
108433
|
-
label: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action.self),
|
108434
|
-
type: ['string'],
|
108435
|
-
mutualExclusion: true,
|
108436
|
-
items: mwa_MWAActionTypes.map(type => ({
|
108437
|
-
key: type,
|
108438
|
-
label: common_ActionTypeText[type],
|
108439
|
-
type: ['string'],
|
108440
|
-
mutualExclusion: true,
|
108441
|
-
items: mwa_MWAActionTypesMap[type].map(item => mwa_MWASpecialSchemaMap[item] || {
|
108442
|
-
key: item,
|
108443
|
-
label: common_ActionTypeTextMap[type][item]
|
108444
|
-
})
|
108445
|
-
}))
|
108446
|
-
}]
|
108447
|
-
};
|
108448
|
-
const mwa_MWAActionFunctionsDevDependencies = {
|
108449
|
-
[common_ActionFunction.UnBundle]: '@modern-js/plugin-unbundle',
|
108450
|
-
[common_ActionFunction.TailwindCSS]: '@modern-js/plugin-tailwindcss',
|
108451
|
-
[common_ActionFunction.Test]: '@modern-js/plugin-testing',
|
108452
|
-
[common_ActionFunction.E2ETest]: '@modern-js/plugin-e2e',
|
108453
|
-
[common_ActionFunction.Doc]: '@modern-js/plugin-docsite',
|
108454
|
-
[common_ActionFunction.Electron]: '@modern-js/plugin-electron',
|
108455
|
-
[common_ActionFunction.Storybook]: '@modern-js/plugin-storybook'
|
108456
|
-
};
|
108457
|
-
const mwa_MWAActionFunctionsDependencies = {
|
108458
|
-
[common_ActionFunction.Less]: '@modern-js/plugin-less',
|
108459
|
-
[common_ActionFunction.Sass]: '@modern-js/plugin-sass',
|
108460
|
-
[common_ActionFunction.BFF]: '@modern-js/plugin-bff',
|
108461
|
-
[common_ActionFunction.MicroFrontend]: '@modern-js/plugin-micro-frontend',
|
108462
|
-
[common_ActionFunction.I18n]: '@modern-js/plugin-i18n',
|
108463
|
-
[common_ActionFunction.SSG]: '@modern-js/plugin-ssg'
|
108464
|
-
};
|
108465
|
-
const mwa_MWANewActionGenerators = {
|
108466
|
-
[common_ActionType.Element]: {
|
108467
|
-
[common_ActionElement.Entry]: '@modern-js/entry-generator',
|
108468
|
-
[common_ActionElement.Server]: '@modern-js/server-generator'
|
108469
|
-
},
|
108470
|
-
[common_ActionType.Function]: {
|
108471
|
-
[common_ActionFunction.UnBundle]: '@modern-js/unbundle-generator',
|
108472
|
-
[common_ActionFunction.TailwindCSS]: '@modern-js/tailwindcss-generator',
|
108473
|
-
[common_ActionFunction.Less]: '@modern-js/dependence-generator',
|
108474
|
-
[common_ActionFunction.Sass]: '@modern-js/dependence-generator',
|
108475
|
-
[common_ActionFunction.BFF]: '@modern-js/bff-generator',
|
108476
|
-
[common_ActionFunction.MicroFrontend]: '@modern-js/dependence-generator',
|
108477
|
-
[common_ActionFunction.Electron]: '@modern-js/electron-generator',
|
108478
|
-
[common_ActionFunction.I18n]: '@modern-js/dependence-generator',
|
108479
|
-
[common_ActionFunction.Test]: '@modern-js/test-generator',
|
108480
|
-
[common_ActionFunction.E2ETest]: '@modern-js/dependence-generator',
|
108481
|
-
[common_ActionFunction.Doc]: '@modern-js/dependence-generator',
|
108482
|
-
[common_ActionFunction.Storybook]: '@modern-js/dependence-generator',
|
108483
|
-
[common_ActionFunction.SSG]: '@modern-js/ssg-generator',
|
108484
|
-
[common_ActionFunction.Deploy]: '@modern-js/cloud-deploy-generator'
|
108485
|
-
},
|
108486
|
-
[common_ActionType.Refactor]: {
|
108487
|
-
[common_ActionRefactor.BFFToApp]: '@modern-js/bff-refactor-generator'
|
108488
|
-
}
|
108489
|
-
};
|
108490
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+utils@1.1.6_typescript@4.5.4/node_modules/@modern-js/utils/dist/js/modern/nodeEnv.js
|
110057
|
+
;// CONCATENATED MODULE: ../../../toolkit/utils/dist/js/modern/nodeEnv.js
|
108491
110058
|
|
108492
110059
|
async function nodeEnv_canUseNpm() {
|
108493
110060
|
try {
|
@@ -108519,7 +110086,7 @@ async function nodeEnv_canUsePnpm() {
|
|
108519
110086
|
return false;
|
108520
110087
|
}
|
108521
110088
|
}
|
108522
|
-
;// CONCATENATED MODULE:
|
110089
|
+
;// CONCATENATED MODULE: ../../generator-utils/dist/js/modern/utils/strip-ansi.js
|
108523
110090
|
function ansiRegex({
|
108524
110091
|
onlyFirst = false
|
108525
110092
|
} = {}) {
|
@@ -108534,7 +110101,7 @@ function stripAnsi(string) {
|
|
108534
110101
|
|
108535
110102
|
return string.replace(ansiRegex(), '');
|
108536
110103
|
}
|
108537
|
-
;// CONCATENATED MODULE:
|
110104
|
+
;// CONCATENATED MODULE: ../../generator-utils/dist/js/modern/index.js
|
108538
110105
|
|
108539
110106
|
|
108540
110107
|
|
@@ -108667,7 +110234,7 @@ function getMWAProjectPath(packagePath, isMonorepoSubProject, isTest = false) {
|
|
108667
110234
|
|
108668
110235
|
return '';
|
108669
110236
|
}
|
108670
|
-
;// CONCATENATED MODULE:
|
110237
|
+
;// CONCATENATED MODULE: ../../../toolkit/utils/dist/js/modern/getPackageManager.js
|
108671
110238
|
|
108672
110239
|
|
108673
110240
|
|
@@ -110106,7 +111673,7 @@ var dist_lib = JSON5;
|
|
110106
111673
|
|
110107
111674
|
/* harmony default export */ const json5_dist = (dist_lib);
|
110108
111675
|
|
110109
|
-
;// CONCATENATED MODULE:
|
111676
|
+
;// CONCATENATED MODULE: ../../new-action/dist/js/modern/utils/index.js
|
110110
111677
|
|
110111
111678
|
|
110112
111679
|
|
@@ -110155,7 +111722,7 @@ function hasEnabledFunction(action, dependencies, devDependencies, peerDependenc
|
|
110155
111722
|
|
110156
111723
|
return false;
|
110157
111724
|
}
|
110158
|
-
;// CONCATENATED MODULE:
|
111725
|
+
;// CONCATENATED MODULE: ../../new-action/dist/js/modern/mwa.js
|
110159
111726
|
|
110160
111727
|
|
110161
111728
|
|
@@ -110180,7 +111747,7 @@ const MWANewAction = async options => {
|
|
110180
111747
|
throw new Error('config is not a valid json');
|
110181
111748
|
}
|
110182
111749
|
|
110183
|
-
|
111750
|
+
modern_locale_i18n.changeLanguage({
|
110184
111751
|
locale: UserConfig.locale || locale
|
110185
111752
|
});
|
110186
111753
|
const smith = new CodeSmith({
|
@@ -110203,9 +111770,9 @@ const MWANewAction = async options => {
|
|
110203
111770
|
data: {},
|
110204
111771
|
current: null
|
110205
111772
|
}, mockGeneratorCore);
|
110206
|
-
const schema = forEach(
|
110207
|
-
if (
|
110208
|
-
const enable = hasEnabledFunction(schemaItem.key,
|
111773
|
+
const schema = forEach(MWANewActionSchema, schemaItem => {
|
111774
|
+
if (MWAActionFunctions.includes(schemaItem.key)) {
|
111775
|
+
const enable = hasEnabledFunction(schemaItem.key, MWAActionFunctionsDependencies, MWAActionFunctionsDevDependencies, {}, cwd);
|
110209
111776
|
const {
|
110210
111777
|
when
|
110211
111778
|
} = schemaItem;
|
@@ -110215,7 +111782,7 @@ const MWANewAction = async options => {
|
|
110215
111782
|
const ans = await appAPI.getInputBySchema(schema, UserConfig);
|
110216
111783
|
const actionType = ans.actionType;
|
110217
111784
|
const action = ans[actionType];
|
110218
|
-
let generator =
|
111785
|
+
let generator = MWANewActionGenerators[actionType][action];
|
110219
111786
|
|
110220
111787
|
if (!generator) {
|
110221
111788
|
throw new Error(`no valid option`);
|
@@ -110225,8 +111792,8 @@ const MWANewAction = async options => {
|
|
110225
111792
|
generator = `${generator}@${distTag}`;
|
110226
111793
|
}
|
110227
111794
|
|
110228
|
-
const devDependency =
|
110229
|
-
const dependency =
|
111795
|
+
const devDependency = MWAActionFunctionsDevDependencies[action];
|
111796
|
+
const dependency = MWAActionFunctionsDependencies[action];
|
110230
111797
|
|
110231
111798
|
const finalConfig = merge_default()(UserConfig, ans, {
|
110232
111799
|
locale: UserConfig.locale || locale,
|
@@ -110237,7 +111804,8 @@ const MWANewAction = async options => {
|
|
110237
111804
|
} : {},
|
110238
111805
|
dependencies: dependency ? {
|
110239
111806
|
[dependency]: `^${await getPackageVersion(dependency)}`
|
110240
|
-
} : {}
|
111807
|
+
} : {},
|
111808
|
+
appendTypeContent: MWAActionFunctionsAppendTypeContent[action]
|
110241
111809
|
});
|
110242
111810
|
|
110243
111811
|
const task = [{
|
@@ -110252,66 +111820,7 @@ const MWANewAction = async options => {
|
|
110252
111820
|
pwd: cwd
|
110253
111821
|
});
|
110254
111822
|
};
|
110255
|
-
;// CONCATENATED MODULE:
|
110256
|
-
|
110257
|
-
|
110258
|
-
const module_ModuleActionTypes = [common_ActionType.Function];
|
110259
|
-
const module_ModuleActionFunctions = [common_ActionFunction.TailwindCSS, common_ActionFunction.Less, common_ActionFunction.Sass, // ActionFunction.I18n,
|
110260
|
-
// ActionFunction.Doc,
|
110261
|
-
common_ActionFunction.Storybook, common_ActionFunction.RuntimeApi];
|
110262
|
-
const module_ModuleActionTypesMap = {
|
110263
|
-
[common_ActionType.Function]: module_ModuleActionFunctions
|
110264
|
-
};
|
110265
|
-
const module_ModuleSpecialSchemaMap = {};
|
110266
|
-
const module_ModuleNewActionSchema = {
|
110267
|
-
key: 'Module_new_action',
|
110268
|
-
isObject: true,
|
110269
|
-
items: [{
|
110270
|
-
key: 'actionType',
|
110271
|
-
label: () => dist_js_modern_locale_i18n.t(dist_js_modern_locale_localeKeys.action.self),
|
110272
|
-
type: ['string'],
|
110273
|
-
mutualExclusion: true,
|
110274
|
-
items: module_ModuleActionTypes.map(type => ({
|
110275
|
-
key: type,
|
110276
|
-
label: common_ActionTypeText[type],
|
110277
|
-
type: ['string'],
|
110278
|
-
mutualExclusion: true,
|
110279
|
-
items: module_ModuleActionFunctions.map(func => module_ModuleSpecialSchemaMap[func] || {
|
110280
|
-
key: func,
|
110281
|
-
label: common_ActionFunctionText[func]
|
110282
|
-
})
|
110283
|
-
}))
|
110284
|
-
}]
|
110285
|
-
};
|
110286
|
-
const module_ModuleActionFunctionsDevDependencies = {
|
110287
|
-
[common_ActionFunction.Doc]: '@modern-js/plugin-docsite',
|
110288
|
-
[common_ActionFunction.Storybook]: '@modern-js/plugin-storybook',
|
110289
|
-
[common_ActionFunction.RuntimeApi]: '@modern-js/runtime',
|
110290
|
-
[common_ActionFunction.TailwindCSS]: 'tailwindcss'
|
110291
|
-
};
|
110292
|
-
const module_ModuleActionFunctionsPeerDependencies = {
|
110293
|
-
[common_ActionFunction.RuntimeApi]: '@modern-js/runtime',
|
110294
|
-
[common_ActionFunction.TailwindCSS]: 'tailwindcss'
|
110295
|
-
};
|
110296
|
-
const module_ModuleActionFunctionsDependencies = {
|
110297
|
-
[common_ActionFunction.I18n]: '@modern-js/plugin-i18n',
|
110298
|
-
[common_ActionFunction.TailwindCSS]: '@modern-js/plugin-tailwindcss',
|
110299
|
-
[common_ActionFunction.Less]: '@modern-js/plugin-less',
|
110300
|
-
[common_ActionFunction.Sass]: '@modern-js/plugin-sass'
|
110301
|
-
};
|
110302
|
-
const module_ModuleNewActionGenerators = {
|
110303
|
-
[common_ActionType.Function]: {
|
110304
|
-
[common_ActionFunction.TailwindCSS]: '@modern-js/dependence-generator',
|
110305
|
-
[common_ActionFunction.Less]: '@modern-js/dependence-generator',
|
110306
|
-
[common_ActionFunction.Sass]: '@modern-js/dependence-generator',
|
110307
|
-
[common_ActionFunction.I18n]: '@modern-js/dependence-generator',
|
110308
|
-
[common_ActionFunction.Test]: '@modern-js/dependence-generator',
|
110309
|
-
[common_ActionFunction.Doc]: '@modern-js/dependence-generator',
|
110310
|
-
[common_ActionFunction.Storybook]: '@modern-js/storybook-generator',
|
110311
|
-
[common_ActionFunction.RuntimeApi]: '@modern-js/dependence-generator'
|
110312
|
-
}
|
110313
|
-
};
|
110314
|
-
;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+new-action@1.2.2_typescript@4.5.4/node_modules/@modern-js/new-action/dist/js/modern/module.js
|
111823
|
+
;// CONCATENATED MODULE: ../../new-action/dist/js/modern/module.js
|
110315
111824
|
|
110316
111825
|
|
110317
111826
|
|
@@ -110336,7 +111845,7 @@ const ModuleNewAction = async options => {
|
|
110336
111845
|
throw new Error('config is not a valid json');
|
110337
111846
|
}
|
110338
111847
|
|
110339
|
-
|
111848
|
+
modern_locale_i18n.changeLanguage({
|
110340
111849
|
locale: UserConfig.locale || locale
|
110341
111850
|
});
|
110342
111851
|
const smith = new CodeSmith({
|
@@ -110360,9 +111869,9 @@ const ModuleNewAction = async options => {
|
|
110360
111869
|
current: null
|
110361
111870
|
}, mockGeneratorCore);
|
110362
111871
|
let hasOption = false;
|
110363
|
-
const schema = forEach(
|
110364
|
-
if (
|
110365
|
-
const enable = hasEnabledFunction(schemaItem.key,
|
111872
|
+
const schema = forEach(ModuleNewActionSchema, schemaItem => {
|
111873
|
+
if (ModuleActionFunctions.includes(schemaItem.key)) {
|
111874
|
+
const enable = hasEnabledFunction(schemaItem.key, ModuleActionFunctionsDependencies, ModuleActionFunctionsDevDependencies, ModuleActionFunctionsPeerDependencies, cwd);
|
110366
111875
|
const {
|
110367
111876
|
when
|
110368
111877
|
} = schemaItem;
|
@@ -110383,7 +111892,7 @@ const ModuleNewAction = async options => {
|
|
110383
111892
|
const ans = await appAPI.getInputBySchema(schema, UserConfig);
|
110384
111893
|
const actionType = ans.actionType;
|
110385
111894
|
const action = ans[actionType];
|
110386
|
-
let generator =
|
111895
|
+
let generator = ModuleNewActionGenerators[actionType] && ModuleNewActionGenerators[actionType][action];
|
110387
111896
|
|
110388
111897
|
if (!generator) {
|
110389
111898
|
throw new Error(`no valid option`);
|
@@ -110393,9 +111902,9 @@ const ModuleNewAction = async options => {
|
|
110393
111902
|
generator = `${generator}@${distTag}`;
|
110394
111903
|
}
|
110395
111904
|
|
110396
|
-
const devDependency =
|
110397
|
-
const dependency =
|
110398
|
-
const peerDependency =
|
111905
|
+
const devDependency = ModuleActionFunctionsDevDependencies[action];
|
111906
|
+
const dependency = ModuleActionFunctionsDependencies[action];
|
111907
|
+
const peerDependency = ModuleActionFunctionsPeerDependencies[action];
|
110399
111908
|
|
110400
111909
|
const finalConfig = merge_default()(UserConfig, ans, {
|
110401
111910
|
locale: UserConfig.locale || locale,
|
@@ -110424,7 +111933,7 @@ const ModuleNewAction = async options => {
|
|
110424
111933
|
pwd: cwd
|
110425
111934
|
});
|
110426
111935
|
};
|
110427
|
-
;// CONCATENATED MODULE:
|
111936
|
+
;// CONCATENATED MODULE: ../../new-action/dist/js/modern/monorepo.js
|
110428
111937
|
|
110429
111938
|
|
110430
111939
|
|
@@ -110449,7 +111958,7 @@ const MonorepoNewAction = async options => {
|
|
110449
111958
|
throw new Error('config is not a valid json');
|
110450
111959
|
}
|
110451
111960
|
|
110452
|
-
|
111961
|
+
modern_locale_i18n.changeLanguage({
|
110453
111962
|
locale: UserConfig.locale || locale
|
110454
111963
|
});
|
110455
111964
|
const smith = new CodeSmith({
|
@@ -110472,7 +111981,7 @@ const MonorepoNewAction = async options => {
|
|
110472
111981
|
let generator = REPO_GENERAROE;
|
110473
111982
|
|
110474
111983
|
if (process.env.CODESMITH_ENV === 'development') {
|
110475
|
-
generator = /*require.resolve*/(__webpack_require__(
|
111984
|
+
generator = /*require.resolve*/(__webpack_require__(30794).resolve(generator));
|
110476
111985
|
} else if (distTag) {
|
110477
111986
|
generator = `${generator}@${distTag}`;
|
110478
111987
|
}
|
@@ -111395,6 +112904,21 @@ module.exports = webpackEmptyContext;
|
|
111395
112904
|
|
111396
112905
|
/***/ }),
|
111397
112906
|
|
112907
|
+
/***/ 30794:
|
112908
|
+
/***/ ((module) => {
|
112909
|
+
|
112910
|
+
function webpackEmptyContext(req) {
|
112911
|
+
var e = new Error("Cannot find module '" + req + "'");
|
112912
|
+
e.code = 'MODULE_NOT_FOUND';
|
112913
|
+
throw e;
|
112914
|
+
}
|
112915
|
+
webpackEmptyContext.keys = () => ([]);
|
112916
|
+
webpackEmptyContext.resolve = webpackEmptyContext;
|
112917
|
+
webpackEmptyContext.id = 30794;
|
112918
|
+
module.exports = webpackEmptyContext;
|
112919
|
+
|
112920
|
+
/***/ }),
|
112921
|
+
|
111398
112922
|
/***/ 39491:
|
111399
112923
|
/***/ ((module) => {
|
111400
112924
|
|
@@ -111747,11 +113271,11 @@ var _merge2 = _interopRequireDefault(__webpack_require__(13904));
|
|
111747
113271
|
|
111748
113272
|
var _path = _interopRequireDefault(__webpack_require__(71017));
|
111749
113273
|
|
111750
|
-
var _codesmithApiApp = __webpack_require__(
|
113274
|
+
var _codesmithApiApp = __webpack_require__(80355);
|
111751
113275
|
|
111752
113276
|
var _generatorCommon = __webpack_require__(50828);
|
111753
113277
|
|
111754
|
-
var _generatorPlugin = __webpack_require__(
|
113278
|
+
var _generatorPlugin = __webpack_require__(82022);
|
111755
113279
|
|
111756
113280
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
111757
113281
|
|