@modern-js/repo-generator 1.3.1 → 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.
Files changed (2) hide show
  1. package/dist/js/node/main.js +2416 -422
  2. package/package.json +7 -8
@@ -9,7 +9,7 @@ module.exports = __webpack_require__(75339);
9
9
 
10
10
  /***/ }),
11
11
 
12
- /***/ 31302:
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__(10169);
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
- /***/ 10169:
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
- /***/ 7764:
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__(31302);
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
- /***/ 83028:
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__(96576));
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__(536);
202
+ var _transformSchema = __webpack_require__(90115);
203
203
 
204
- var handlers = _interopRequireWildcard(__webpack_require__(7764));
204
+ var handlers = _interopRequireWildcard(__webpack_require__(96354));
205
205
 
206
- var _locale = __webpack_require__(94864);
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.yarn_pnpm));
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
- /***/ 88918:
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
- yarn_pnpm: 'please install yarn or pnpm first'
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
- /***/ 94864:
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__(80539);
477
+ var _pluginI18n = __webpack_require__(54207);
478
478
 
479
- var _zh = __webpack_require__(57724);
479
+ var _zh = __webpack_require__(12214);
480
480
 
481
- var _en = __webpack_require__(88918);
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
- /***/ 57724:
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
- yarn_pnpm: '检测到环境中未安装 yarn 或者 pnpm,请先安装 yarn pnpm'
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
- /***/ 536:
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__(96576));
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__(96576));
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__(96576));
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__(96576));
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__(96576));
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__(96576));
2407
+ var _fsExtra = _interopRequireDefault(__webpack_require__(83950));
2408
2408
 
2409
2409
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
2410
2410
 
@@ -5604,7 +5604,7 @@ exports.pointer = pointer;
5604
5604
 
5605
5605
  /***/ }),
5606
5606
 
5607
- /***/ 80539:
5607
+ /***/ 54207:
5608
5608
  /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
5609
5609
 
5610
5610
  "use strict";
@@ -5617,7 +5617,7 @@ exports.I18n = void 0;
5617
5617
 
5618
5618
  var _get2 = _interopRequireDefault(__webpack_require__(71189));
5619
5619
 
5620
- var _utils = __webpack_require__(4960);
5620
+ var _utils = __webpack_require__(41083);
5621
5621
 
5622
5622
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
5623
5623
 
@@ -5686,7 +5686,7 @@ exports.I18n = I18n;
5686
5686
 
5687
5687
  /***/ }),
5688
5688
 
5689
- /***/ 4960:
5689
+ /***/ 41083:
5690
5690
  /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
5691
5691
 
5692
5692
  "use strict";
@@ -31937,186 +31937,2186 @@ RedirectableRequest.prototype._processResponse = function (response) {
31937
31937
  var redirectUrlParts = url.parse(redirectUrl);
31938
31938
  Object.assign(this._options, redirectUrlParts);
31939
31939
 
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);
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
31943
33848
  }
31944
33849
 
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);
33850
+ // Windows can EPERM on stat. Life is suffering.
33851
+ if (er.code === 'EPERM' && isWindows) {
33852
+ fixWinEPERMSync(p, options, er)
31956
33853
  }
33854
+ }
31957
33855
 
31958
- // Perform the redirected request
31959
- try {
31960
- this._performRequest();
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)
31961
33862
  }
31962
- catch (cause) {
31963
- this.emit("error", new RedirectionError(cause));
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
31964
33870
  }
33871
+ rmdirSync(p, options, er)
31965
33872
  }
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);
33873
+ }
31971
33874
 
31972
- // Clean up
31973
- this._requestBodyBuffers = [];
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
+ }
31974
33889
  }
31975
- };
33890
+ }
31976
33891
 
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
- };
33892
+ function rmkidsSync (p, options) {
33893
+ assert(p)
33894
+ assert(options)
33895
+ options.readdirSync(p).forEach(f => rimrafSync(path.join(p, f), options))
31984
33896
 
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);
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
+ }
31991
33916
 
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);
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 })
32003
33974
  }
33975
+ return cb(new Error('Source and destination must not be the same.'))
32004
33976
  }
32005
- else if (URL && (input instanceof URL)) {
32006
- input = urlToOptions(input);
32007
- }
32008
- else {
32009
- callback = options;
32010
- options = input;
32011
- input = { protocol: protocol };
33977
+ if (srcStat.isDirectory() && !destStat.isDirectory()) {
33978
+ return cb(new Error(`Cannot overwrite non-directory '${dest}' with directory '${src}'.`))
32012
33979
  }
32013
- if (typeof options === "function") {
32014
- callback = options;
32015
- options = null;
33980
+ if (!srcStat.isDirectory() && destStat.isDirectory()) {
33981
+ return cb(new Error(`Cannot overwrite directory '${dest}' with non-directory '${src}'.`))
32016
33982
  }
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
33983
  }
32029
33984
 
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;
33985
+ if (srcStat.isDirectory() && isSrcSubdir(src, dest)) {
33986
+ return cb(new Error(errMsg(src, dest, funcName)))
32035
33987
  }
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;
33988
+ return cb(null, { srcStat, destStat })
33989
+ })
32044
33990
  }
32045
33991
 
32046
- /* istanbul ignore next */
32047
- function noop() { /* empty */ }
33992
+ function checkPathsSync (src, dest, funcName, opts) {
33993
+ const { srcStat, destStat } = getStatsSync(src, dest, opts)
32048
33994
 
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);
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
+ }
32065
34012
  }
32066
- return options;
32067
- }
32068
34013
 
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
- }
34014
+ if (srcStat.isDirectory() && isSrcSubdir(src, dest)) {
34015
+ throw new Error(errMsg(src, dest, funcName))
32076
34016
  }
32077
- return (lastValue === null || typeof lastValue === "undefined") ?
32078
- undefined : String(lastValue).trim();
34017
+ return { srcStat, destStat }
32079
34018
  }
32080
34019
 
32081
- function createErrorType(code, defaultMessage) {
32082
- function CustomError(cause) {
32083
- Error.captureStackTrace(this, this.constructor);
32084
- if (!cause) {
32085
- this.message = defaultMessage;
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)
32086
34032
  }
32087
- else {
32088
- this.message = defaultMessage + ": " + cause.message;
32089
- this.cause = cause;
34033
+ if (areIdentical(srcStat, destStat)) {
34034
+ return cb(new Error(errMsg(src, dest, funcName)))
32090
34035
  }
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;
34036
+ return checkParentPaths(src, srcStat, destParent, funcName, cb)
34037
+ })
32097
34038
  }
32098
34039
 
32099
- function abortRequest(request) {
32100
- for (var e = 0; e < events.length; e++) {
32101
- request.removeListener(events[e], eventHandlers[events[e]]);
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
32102
34050
  }
32103
- request.on("error", noop);
32104
- request.abort();
34051
+ if (areIdentical(srcStat, destStat)) {
34052
+ throw new Error(errMsg(src, dest, funcName))
34053
+ }
34054
+ return checkParentPathsSync(src, srcStat, destParent, funcName)
32105
34055
  }
32106
34056
 
32107
- function isSubdomainOf(subdomain, domain) {
32108
- const dot = subdomain.length - domain.length - 1;
32109
- 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
32110
34059
  }
32111
34060
 
32112
- // Exports
32113
- module.exports = wrap({ http: http, https: https });
32114
- module.exports.wrap = wrap;
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
+ }
32115
34081
 
32116
34082
 
32117
34083
  /***/ }),
32118
34084
 
32119
- /***/ 74714:
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:
32120
34120
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
32121
34121
 
32122
34122
  "use strict";
@@ -32124,9 +34124,9 @@ module.exports.wrap = wrap;
32124
34124
 
32125
34125
  const fs = __webpack_require__(62204)
32126
34126
  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)
34127
+ const mkdirsSync = (__webpack_require__(59915).mkdirsSync)
34128
+ const utimesMillisSync = (__webpack_require__(88962).utimesMillisSync)
34129
+ const stat = __webpack_require__(12021)
32130
34130
 
32131
34131
  function copySync (src, dest, opts) {
32132
34132
  if (typeof opts === 'function') {
@@ -32290,20 +34290,7 @@ module.exports = copySync
32290
34290
 
32291
34291
  /***/ }),
32292
34292
 
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:
34293
+ /***/ 4266:
32307
34294
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
32308
34295
 
32309
34296
  "use strict";
@@ -32311,10 +34298,10 @@ module.exports = {
32311
34298
 
32312
34299
  const fs = __webpack_require__(62204)
32313
34300
  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)
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)
32318
34305
 
32319
34306
  function copy (src, dest, opts, cb) {
32320
34307
  if (typeof opts === 'function' && !cb) {
@@ -32543,7 +34530,7 @@ module.exports = copy
32543
34530
 
32544
34531
  /***/ }),
32545
34532
 
32546
- /***/ 97969:
34533
+ /***/ 1105:
32547
34534
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
32548
34535
 
32549
34536
  "use strict";
@@ -32551,23 +34538,24 @@ module.exports = copy
32551
34538
 
32552
34539
  const u = (__webpack_require__(84357).fromCallback)
32553
34540
  module.exports = {
32554
- copy: u(__webpack_require__(77544))
34541
+ copy: u(__webpack_require__(4266)),
34542
+ copySync: __webpack_require__(16345)
32555
34543
  }
32556
34544
 
32557
34545
 
32558
34546
  /***/ }),
32559
34547
 
32560
- /***/ 54656:
34548
+ /***/ 19102:
32561
34549
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
32562
34550
 
32563
34551
  "use strict";
32564
34552
 
32565
34553
 
32566
34554
  const u = (__webpack_require__(84357).fromPromise)
32567
- const fs = __webpack_require__(48085)
34555
+ const fs = __webpack_require__(73664)
32568
34556
  const path = __webpack_require__(71017)
32569
- const mkdir = __webpack_require__(17433)
32570
- const remove = __webpack_require__(13490)
34557
+ const mkdir = __webpack_require__(59915)
34558
+ const remove = __webpack_require__(21133)
32571
34559
 
32572
34560
  const emptyDir = u(async function emptyDir (dir) {
32573
34561
  let items
@@ -32604,7 +34592,7 @@ module.exports = {
32604
34592
 
32605
34593
  /***/ }),
32606
34594
 
32607
- /***/ 3805:
34595
+ /***/ 19570:
32608
34596
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
32609
34597
 
32610
34598
  "use strict";
@@ -32613,7 +34601,7 @@ module.exports = {
32613
34601
  const u = (__webpack_require__(84357).fromCallback)
32614
34602
  const path = __webpack_require__(71017)
32615
34603
  const fs = __webpack_require__(62204)
32616
- const mkdir = __webpack_require__(17433)
34604
+ const mkdir = __webpack_require__(59915)
32617
34605
 
32618
34606
  function createFile (file, callback) {
32619
34607
  function makeFile () {
@@ -32681,38 +34669,38 @@ module.exports = {
32681
34669
 
32682
34670
  /***/ }),
32683
34671
 
32684
- /***/ 61435:
34672
+ /***/ 99793:
32685
34673
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
32686
34674
 
32687
34675
  "use strict";
32688
34676
 
32689
34677
 
32690
- const file = __webpack_require__(3805)
32691
- const link = __webpack_require__(34711)
32692
- const symlink = __webpack_require__(9480)
34678
+ const { createFile, createFileSync } = __webpack_require__(19570)
34679
+ const { createLink, createLinkSync } = __webpack_require__(19986)
34680
+ const { createSymlink, createSymlinkSync } = __webpack_require__(63762)
32693
34681
 
32694
34682
  module.exports = {
32695
34683
  // file
32696
- createFile: file.createFile,
32697
- createFileSync: file.createFileSync,
32698
- ensureFile: file.createFile,
32699
- ensureFileSync: file.createFileSync,
34684
+ createFile,
34685
+ createFileSync,
34686
+ ensureFile: createFile,
34687
+ ensureFileSync: createFileSync,
32700
34688
  // link
32701
- createLink: link.createLink,
32702
- createLinkSync: link.createLinkSync,
32703
- ensureLink: link.createLink,
32704
- ensureLinkSync: link.createLinkSync,
34689
+ createLink,
34690
+ createLinkSync,
34691
+ ensureLink: createLink,
34692
+ ensureLinkSync: createLinkSync,
32705
34693
  // symlink
32706
- createSymlink: symlink.createSymlink,
32707
- createSymlinkSync: symlink.createSymlinkSync,
32708
- ensureSymlink: symlink.createSymlink,
32709
- ensureSymlinkSync: symlink.createSymlinkSync
34694
+ createSymlink,
34695
+ createSymlinkSync,
34696
+ ensureSymlink: createSymlink,
34697
+ ensureSymlinkSync: createSymlinkSync
32710
34698
  }
32711
34699
 
32712
34700
 
32713
34701
  /***/ }),
32714
34702
 
32715
- /***/ 34711:
34703
+ /***/ 19986:
32716
34704
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
32717
34705
 
32718
34706
  "use strict";
@@ -32721,9 +34709,9 @@ module.exports = {
32721
34709
  const u = (__webpack_require__(84357).fromCallback)
32722
34710
  const path = __webpack_require__(71017)
32723
34711
  const fs = __webpack_require__(62204)
32724
- const mkdir = __webpack_require__(17433)
32725
- const pathExists = (__webpack_require__(84906).pathExists)
32726
- const { areIdentical } = __webpack_require__(31197)
34712
+ const mkdir = __webpack_require__(59915)
34713
+ const pathExists = (__webpack_require__(9672).pathExists)
34714
+ const { areIdentical } = __webpack_require__(12021)
32727
34715
 
32728
34716
  function createLink (srcpath, dstpath, callback) {
32729
34717
  function makeLink (srcpath, dstpath) {
@@ -32784,7 +34772,7 @@ module.exports = {
32784
34772
 
32785
34773
  /***/ }),
32786
34774
 
32787
- /***/ 31528:
34775
+ /***/ 5461:
32788
34776
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
32789
34777
 
32790
34778
  "use strict";
@@ -32792,7 +34780,7 @@ module.exports = {
32792
34780
 
32793
34781
  const path = __webpack_require__(71017)
32794
34782
  const fs = __webpack_require__(62204)
32795
- const pathExists = (__webpack_require__(84906).pathExists)
34783
+ const pathExists = (__webpack_require__(9672).pathExists)
32796
34784
 
32797
34785
  /**
32798
34786
  * Function that returns two types of paths, one relative to symlink, and one
@@ -32891,7 +34879,7 @@ module.exports = {
32891
34879
 
32892
34880
  /***/ }),
32893
34881
 
32894
- /***/ 68938:
34882
+ /***/ 95375:
32895
34883
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
32896
34884
 
32897
34885
  "use strict";
@@ -32930,7 +34918,7 @@ module.exports = {
32930
34918
 
32931
34919
  /***/ }),
32932
34920
 
32933
- /***/ 9480:
34921
+ /***/ 63762:
32934
34922
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
32935
34923
 
32936
34924
  "use strict";
@@ -32938,22 +34926,22 @@ module.exports = {
32938
34926
 
32939
34927
  const u = (__webpack_require__(84357).fromCallback)
32940
34928
  const path = __webpack_require__(71017)
32941
- const fs = __webpack_require__(48085)
32942
- const _mkdirs = __webpack_require__(17433)
34929
+ const fs = __webpack_require__(73664)
34930
+ const _mkdirs = __webpack_require__(59915)
32943
34931
  const mkdirs = _mkdirs.mkdirs
32944
34932
  const mkdirsSync = _mkdirs.mkdirsSync
32945
34933
 
32946
- const _symlinkPaths = __webpack_require__(31528)
34934
+ const _symlinkPaths = __webpack_require__(5461)
32947
34935
  const symlinkPaths = _symlinkPaths.symlinkPaths
32948
34936
  const symlinkPathsSync = _symlinkPaths.symlinkPathsSync
32949
34937
 
32950
- const _symlinkType = __webpack_require__(68938)
34938
+ const _symlinkType = __webpack_require__(95375)
32951
34939
  const symlinkType = _symlinkType.symlinkType
32952
34940
  const symlinkTypeSync = _symlinkType.symlinkTypeSync
32953
34941
 
32954
- const pathExists = (__webpack_require__(84906).pathExists)
34942
+ const pathExists = (__webpack_require__(9672).pathExists)
32955
34943
 
32956
- const { areIdentical } = __webpack_require__(31197)
34944
+ const { areIdentical } = __webpack_require__(12021)
32957
34945
 
32958
34946
  function createSymlink (srcpath, dstpath, type, callback) {
32959
34947
  callback = (typeof type === 'function') ? type : callback
@@ -33020,7 +35008,7 @@ module.exports = {
33020
35008
 
33021
35009
  /***/ }),
33022
35010
 
33023
- /***/ 48085:
35011
+ /***/ 73664:
33024
35012
  /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
33025
35013
 
33026
35014
  "use strict";
@@ -33147,7 +35135,7 @@ if (typeof fs.writev === 'function') {
33147
35135
 
33148
35136
  /***/ }),
33149
35137
 
33150
- /***/ 96576:
35138
+ /***/ 83950:
33151
35139
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33152
35140
 
33153
35141
  "use strict";
@@ -33155,35 +35143,33 @@ if (typeof fs.writev === 'function') {
33155
35143
 
33156
35144
  module.exports = {
33157
35145
  // Export promiseified graceful-fs:
33158
- ...__webpack_require__(48085),
35146
+ ...__webpack_require__(73664),
33159
35147
  // 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)
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)
33171
35157
  }
33172
35158
 
33173
35159
 
33174
35160
  /***/ }),
33175
35161
 
33176
- /***/ 58050:
35162
+ /***/ 37557:
33177
35163
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33178
35164
 
33179
35165
  "use strict";
33180
35166
 
33181
35167
 
33182
35168
  const u = (__webpack_require__(84357).fromPromise)
33183
- const jsonFile = __webpack_require__(73545)
35169
+ const jsonFile = __webpack_require__(42915)
33184
35170
 
33185
- jsonFile.outputJson = u(__webpack_require__(84981))
33186
- jsonFile.outputJsonSync = __webpack_require__(47032)
35171
+ jsonFile.outputJson = u(__webpack_require__(87482))
35172
+ jsonFile.outputJsonSync = __webpack_require__(48467)
33187
35173
  // aliases
33188
35174
  jsonFile.outputJSON = jsonFile.outputJson
33189
35175
  jsonFile.outputJSONSync = jsonFile.outputJsonSync
@@ -33197,7 +35183,7 @@ module.exports = jsonFile
33197
35183
 
33198
35184
  /***/ }),
33199
35185
 
33200
- /***/ 73545:
35186
+ /***/ 42915:
33201
35187
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33202
35188
 
33203
35189
  "use strict";
@@ -33216,14 +35202,14 @@ module.exports = {
33216
35202
 
33217
35203
  /***/ }),
33218
35204
 
33219
- /***/ 47032:
35205
+ /***/ 48467:
33220
35206
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33221
35207
 
33222
35208
  "use strict";
33223
35209
 
33224
35210
 
33225
35211
  const { stringify } = __webpack_require__(27546)
33226
- const { outputFileSync } = __webpack_require__(54379)
35212
+ const { outputFileSync } = __webpack_require__(65889)
33227
35213
 
33228
35214
  function outputJsonSync (file, data, options) {
33229
35215
  const str = stringify(data, options)
@@ -33236,14 +35222,14 @@ module.exports = outputJsonSync
33236
35222
 
33237
35223
  /***/ }),
33238
35224
 
33239
- /***/ 84981:
35225
+ /***/ 87482:
33240
35226
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33241
35227
 
33242
35228
  "use strict";
33243
35229
 
33244
35230
 
33245
35231
  const { stringify } = __webpack_require__(27546)
33246
- const { outputFile } = __webpack_require__(54379)
35232
+ const { outputFile } = __webpack_require__(65889)
33247
35233
 
33248
35234
  async function outputJson (file, data, options = {}) {
33249
35235
  const str = stringify(data, options)
@@ -33256,13 +35242,13 @@ module.exports = outputJson
33256
35242
 
33257
35243
  /***/ }),
33258
35244
 
33259
- /***/ 17433:
35245
+ /***/ 59915:
33260
35246
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33261
35247
 
33262
35248
  "use strict";
33263
35249
 
33264
35250
  const u = (__webpack_require__(84357).fromPromise)
33265
- const { makeDir: _makeDir, makeDirSync } = __webpack_require__(75594)
35251
+ const { makeDir: _makeDir, makeDirSync } = __webpack_require__(15602)
33266
35252
  const makeDir = u(_makeDir)
33267
35253
 
33268
35254
  module.exports = {
@@ -33278,13 +35264,13 @@ module.exports = {
33278
35264
 
33279
35265
  /***/ }),
33280
35266
 
33281
- /***/ 75594:
35267
+ /***/ 15602:
33282
35268
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33283
35269
 
33284
35270
  "use strict";
33285
35271
 
33286
- const fs = __webpack_require__(48085)
33287
- const { checkPath } = __webpack_require__(60937)
35272
+ const fs = __webpack_require__(73664)
35273
+ const { checkPath } = __webpack_require__(92751)
33288
35274
 
33289
35275
  const getMode = options => {
33290
35276
  const defaults = { mode: 0o777 }
@@ -33313,7 +35299,7 @@ module.exports.makeDirSync = (dir, options) => {
33313
35299
 
33314
35300
  /***/ }),
33315
35301
 
33316
- /***/ 60937:
35302
+ /***/ 92751:
33317
35303
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33318
35304
 
33319
35305
  "use strict";
@@ -33342,20 +35328,22 @@ module.exports.checkPath = function checkPath (pth) {
33342
35328
 
33343
35329
  /***/ }),
33344
35330
 
33345
- /***/ 84170:
35331
+ /***/ 14449:
33346
35332
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33347
35333
 
33348
35334
  "use strict";
33349
35335
 
33350
35336
 
35337
+ const u = (__webpack_require__(84357).fromCallback)
33351
35338
  module.exports = {
33352
- moveSync: __webpack_require__(84065)
35339
+ move: u(__webpack_require__(10000)),
35340
+ moveSync: __webpack_require__(40665)
33353
35341
  }
33354
35342
 
33355
35343
 
33356
35344
  /***/ }),
33357
35345
 
33358
- /***/ 84065:
35346
+ /***/ 40665:
33359
35347
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33360
35348
 
33361
35349
  "use strict";
@@ -33363,10 +35351,10 @@ module.exports = {
33363
35351
 
33364
35352
  const fs = __webpack_require__(62204)
33365
35353
  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)
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)
33370
35358
 
33371
35359
  function moveSync (src, dest, opts) {
33372
35360
  opts = opts || {}
@@ -33417,21 +35405,7 @@ module.exports = moveSync
33417
35405
 
33418
35406
  /***/ }),
33419
35407
 
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:
35408
+ /***/ 10000:
33435
35409
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33436
35410
 
33437
35411
  "use strict";
@@ -33439,11 +35413,11 @@ module.exports = {
33439
35413
 
33440
35414
  const fs = __webpack_require__(62204)
33441
35415
  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)
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)
33447
35421
 
33448
35422
  function move (src, dest, opts, cb) {
33449
35423
  if (typeof opts === 'function') {
@@ -33512,7 +35486,7 @@ module.exports = move
33512
35486
 
33513
35487
  /***/ }),
33514
35488
 
33515
- /***/ 54379:
35489
+ /***/ 65889:
33516
35490
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33517
35491
 
33518
35492
  "use strict";
@@ -33521,8 +35495,8 @@ module.exports = move
33521
35495
  const u = (__webpack_require__(84357).fromCallback)
33522
35496
  const fs = __webpack_require__(62204)
33523
35497
  const path = __webpack_require__(71017)
33524
- const mkdir = __webpack_require__(17433)
33525
- const pathExists = (__webpack_require__(84906).pathExists)
35498
+ const mkdir = __webpack_require__(59915)
35499
+ const pathExists = (__webpack_require__(9672).pathExists)
33526
35500
 
33527
35501
  function outputFile (file, data, encoding, callback) {
33528
35502
  if (typeof encoding === 'function') {
@@ -33560,13 +35534,13 @@ module.exports = {
33560
35534
 
33561
35535
  /***/ }),
33562
35536
 
33563
- /***/ 84906:
35537
+ /***/ 9672:
33564
35538
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33565
35539
 
33566
35540
  "use strict";
33567
35541
 
33568
35542
  const u = (__webpack_require__(84357).fromPromise)
33569
- const fs = __webpack_require__(48085)
35543
+ const fs = __webpack_require__(73664)
33570
35544
 
33571
35545
  function pathExists (path) {
33572
35546
  return fs.access(path).then(() => true).catch(() => false)
@@ -33580,7 +35554,7 @@ module.exports = {
33580
35554
 
33581
35555
  /***/ }),
33582
35556
 
33583
- /***/ 13490:
35557
+ /***/ 21133:
33584
35558
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33585
35559
 
33586
35560
  "use strict";
@@ -33588,7 +35562,7 @@ module.exports = {
33588
35562
 
33589
35563
  const fs = __webpack_require__(62204)
33590
35564
  const u = (__webpack_require__(84357).fromCallback)
33591
- const rimraf = __webpack_require__(94392)
35565
+ const rimraf = __webpack_require__(58088)
33592
35566
 
33593
35567
  function remove (path, callback) {
33594
35568
  // Node 14.14.0+
@@ -33610,7 +35584,7 @@ module.exports = {
33610
35584
 
33611
35585
  /***/ }),
33612
35586
 
33613
- /***/ 94392:
35587
+ /***/ 58088:
33614
35588
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33615
35589
 
33616
35590
  "use strict";
@@ -33920,13 +35894,13 @@ rimraf.sync = rimrafSync
33920
35894
 
33921
35895
  /***/ }),
33922
35896
 
33923
- /***/ 31197:
35897
+ /***/ 12021:
33924
35898
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
33925
35899
 
33926
35900
  "use strict";
33927
35901
 
33928
35902
 
33929
- const fs = __webpack_require__(48085)
35903
+ const fs = __webpack_require__(73664)
33930
35904
  const path = __webpack_require__(71017)
33931
35905
  const util = __webpack_require__(73837)
33932
35906
 
@@ -34082,7 +36056,7 @@ module.exports = {
34082
36056
 
34083
36057
  /***/ }),
34084
36058
 
34085
- /***/ 16333:
36059
+ /***/ 88962:
34086
36060
  /***/ ((module, __unused_webpack_exports, __webpack_require__) => {
34087
36061
 
34088
36062
  "use strict";
@@ -82201,7 +84175,7 @@ exports.ConnectableObservable = void 0;
82201
84175
  var Observable_1 = __webpack_require__(47082);
82202
84176
  var Subscription_1 = __webpack_require__(69661);
82203
84177
  var refCount_1 = __webpack_require__(75181);
82204
- var OperatorSubscriber_1 = __webpack_require__(9974);
84178
+ var OperatorSubscriber_1 = __webpack_require__(83028);
82205
84179
  var lift_1 = __webpack_require__(12370);
82206
84180
  var ConnectableObservable = (function (_super) {
82207
84181
  __extends(ConnectableObservable, _super);
@@ -82419,7 +84393,7 @@ var identity_1 = __webpack_require__(12418);
82419
84393
  var mapOneOrManyArgs_1 = __webpack_require__(59377);
82420
84394
  var args_1 = __webpack_require__(47844);
82421
84395
  var createObject_1 = __webpack_require__(22573);
82422
- var OperatorSubscriber_1 = __webpack_require__(9974);
84396
+ var OperatorSubscriber_1 = __webpack_require__(83028);
82423
84397
  var executeSchedule_1 = __webpack_require__(28420);
82424
84398
  function combineLatest() {
82425
84399
  var args = [];
@@ -82637,7 +84611,7 @@ var Observable_1 = __webpack_require__(47082);
82637
84611
  var argsArgArrayOrObject_1 = __webpack_require__(12671);
82638
84612
  var innerFrom_1 = __webpack_require__(17438);
82639
84613
  var args_1 = __webpack_require__(47844);
82640
- var OperatorSubscriber_1 = __webpack_require__(9974);
84614
+ var OperatorSubscriber_1 = __webpack_require__(83028);
82641
84615
  var mapOneOrManyArgs_1 = __webpack_require__(59377);
82642
84616
  var createObject_1 = __webpack_require__(22573);
82643
84617
  function forkJoin() {
@@ -83310,7 +85284,7 @@ exports.raceInit = exports.race = void 0;
83310
85284
  var Observable_1 = __webpack_require__(47082);
83311
85285
  var innerFrom_1 = __webpack_require__(17438);
83312
85286
  var argsOrArgArray_1 = __webpack_require__(25796);
83313
- var OperatorSubscriber_1 = __webpack_require__(9974);
85287
+ var OperatorSubscriber_1 = __webpack_require__(83028);
83314
85288
  function race() {
83315
85289
  var sources = [];
83316
85290
  for (var _i = 0; _i < arguments.length; _i++) {
@@ -83516,7 +85490,7 @@ var Observable_1 = __webpack_require__(47082);
83516
85490
  var innerFrom_1 = __webpack_require__(17438);
83517
85491
  var argsOrArgArray_1 = __webpack_require__(25796);
83518
85492
  var empty_1 = __webpack_require__(18939);
83519
- var OperatorSubscriber_1 = __webpack_require__(9974);
85493
+ var OperatorSubscriber_1 = __webpack_require__(83028);
83520
85494
  var args_1 = __webpack_require__(47844);
83521
85495
  function zip() {
83522
85496
  var args = [];
@@ -83561,7 +85535,7 @@ exports.zip = zip;
83561
85535
 
83562
85536
  /***/ }),
83563
85537
 
83564
- /***/ 9974:
85538
+ /***/ 83028:
83565
85539
  /***/ (function(__unused_webpack_module, exports, __webpack_require__) {
83566
85540
 
83567
85541
  "use strict";
@@ -83649,7 +85623,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
83649
85623
  exports.audit = void 0;
83650
85624
  var lift_1 = __webpack_require__(12370);
83651
85625
  var innerFrom_1 = __webpack_require__(17438);
83652
- var OperatorSubscriber_1 = __webpack_require__(9974);
85626
+ var OperatorSubscriber_1 = __webpack_require__(83028);
83653
85627
  function audit(durationSelector) {
83654
85628
  return lift_1.operate(function (source, subscriber) {
83655
85629
  var hasValue = false;
@@ -83716,7 +85690,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
83716
85690
  exports.buffer = void 0;
83717
85691
  var lift_1 = __webpack_require__(12370);
83718
85692
  var noop_1 = __webpack_require__(3064);
83719
- var OperatorSubscriber_1 = __webpack_require__(9974);
85693
+ var OperatorSubscriber_1 = __webpack_require__(83028);
83720
85694
  function buffer(closingNotifier) {
83721
85695
  return lift_1.operate(function (source, subscriber) {
83722
85696
  var currentBuffer = [];
@@ -83758,7 +85732,7 @@ var __values = (this && this.__values) || function(o) {
83758
85732
  Object.defineProperty(exports, "__esModule", ({ value: true }));
83759
85733
  exports.bufferCount = void 0;
83760
85734
  var lift_1 = __webpack_require__(12370);
83761
- var OperatorSubscriber_1 = __webpack_require__(9974);
85735
+ var OperatorSubscriber_1 = __webpack_require__(83028);
83762
85736
  var arrRemove_1 = __webpack_require__(19503);
83763
85737
  function bufferCount(bufferSize, startBufferEvery) {
83764
85738
  if (startBufferEvery === void 0) { startBufferEvery = null; }
@@ -83851,7 +85825,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
83851
85825
  exports.bufferTime = void 0;
83852
85826
  var Subscription_1 = __webpack_require__(69661);
83853
85827
  var lift_1 = __webpack_require__(12370);
83854
- var OperatorSubscriber_1 = __webpack_require__(9974);
85828
+ var OperatorSubscriber_1 = __webpack_require__(83028);
83855
85829
  var arrRemove_1 = __webpack_require__(19503);
83856
85830
  var async_1 = __webpack_require__(11644);
83857
85831
  var args_1 = __webpack_require__(47844);
@@ -83950,7 +85924,7 @@ exports.bufferToggle = void 0;
83950
85924
  var Subscription_1 = __webpack_require__(69661);
83951
85925
  var lift_1 = __webpack_require__(12370);
83952
85926
  var innerFrom_1 = __webpack_require__(17438);
83953
- var OperatorSubscriber_1 = __webpack_require__(9974);
85927
+ var OperatorSubscriber_1 = __webpack_require__(83028);
83954
85928
  var noop_1 = __webpack_require__(3064);
83955
85929
  var arrRemove_1 = __webpack_require__(19503);
83956
85930
  function bufferToggle(openings, closingSelector) {
@@ -84004,7 +85978,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
84004
85978
  exports.bufferWhen = void 0;
84005
85979
  var lift_1 = __webpack_require__(12370);
84006
85980
  var noop_1 = __webpack_require__(3064);
84007
- var OperatorSubscriber_1 = __webpack_require__(9974);
85981
+ var OperatorSubscriber_1 = __webpack_require__(83028);
84008
85982
  var innerFrom_1 = __webpack_require__(17438);
84009
85983
  function bufferWhen(closingSelector) {
84010
85984
  return lift_1.operate(function (source, subscriber) {
@@ -84037,7 +86011,7 @@ exports.bufferWhen = bufferWhen;
84037
86011
  Object.defineProperty(exports, "__esModule", ({ value: true }));
84038
86012
  exports.catchError = void 0;
84039
86013
  var innerFrom_1 = __webpack_require__(17438);
84040
- var OperatorSubscriber_1 = __webpack_require__(9974);
86014
+ var OperatorSubscriber_1 = __webpack_require__(83028);
84041
86015
  var lift_1 = __webpack_require__(12370);
84042
86016
  function catchError(selector) {
84043
86017
  return lift_1.operate(function (source, subscriber) {
@@ -84380,7 +86354,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
84380
86354
  exports.debounce = void 0;
84381
86355
  var lift_1 = __webpack_require__(12370);
84382
86356
  var noop_1 = __webpack_require__(3064);
84383
- var OperatorSubscriber_1 = __webpack_require__(9974);
86357
+ var OperatorSubscriber_1 = __webpack_require__(83028);
84384
86358
  var innerFrom_1 = __webpack_require__(17438);
84385
86359
  function debounce(durationSelector) {
84386
86360
  return lift_1.operate(function (source, subscriber) {
@@ -84425,7 +86399,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
84425
86399
  exports.debounceTime = void 0;
84426
86400
  var async_1 = __webpack_require__(11644);
84427
86401
  var lift_1 = __webpack_require__(12370);
84428
- var OperatorSubscriber_1 = __webpack_require__(9974);
86402
+ var OperatorSubscriber_1 = __webpack_require__(83028);
84429
86403
  function debounceTime(dueTime, scheduler) {
84430
86404
  if (scheduler === void 0) { scheduler = async_1.asyncScheduler; }
84431
86405
  return lift_1.operate(function (source, subscriber) {
@@ -84479,7 +86453,7 @@ exports.debounceTime = debounceTime;
84479
86453
  Object.defineProperty(exports, "__esModule", ({ value: true }));
84480
86454
  exports.defaultIfEmpty = void 0;
84481
86455
  var lift_1 = __webpack_require__(12370);
84482
- var OperatorSubscriber_1 = __webpack_require__(9974);
86456
+ var OperatorSubscriber_1 = __webpack_require__(83028);
84483
86457
  function defaultIfEmpty(defaultValue) {
84484
86458
  return lift_1.operate(function (source, subscriber) {
84485
86459
  var hasValue = false;
@@ -84553,7 +86527,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
84553
86527
  exports.dematerialize = void 0;
84554
86528
  var Notification_1 = __webpack_require__(89340);
84555
86529
  var lift_1 = __webpack_require__(12370);
84556
- var OperatorSubscriber_1 = __webpack_require__(9974);
86530
+ var OperatorSubscriber_1 = __webpack_require__(83028);
84557
86531
  function dematerialize() {
84558
86532
  return lift_1.operate(function (source, subscriber) {
84559
86533
  source.subscribe(new OperatorSubscriber_1.OperatorSubscriber(subscriber, function (notification) { return Notification_1.observeNotification(notification, subscriber); }));
@@ -84572,7 +86546,7 @@ exports.dematerialize = dematerialize;
84572
86546
  Object.defineProperty(exports, "__esModule", ({ value: true }));
84573
86547
  exports.distinct = void 0;
84574
86548
  var lift_1 = __webpack_require__(12370);
84575
- var OperatorSubscriber_1 = __webpack_require__(9974);
86549
+ var OperatorSubscriber_1 = __webpack_require__(83028);
84576
86550
  var noop_1 = __webpack_require__(3064);
84577
86551
  function distinct(keySelector, flushes) {
84578
86552
  return lift_1.operate(function (source, subscriber) {
@@ -84601,7 +86575,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
84601
86575
  exports.distinctUntilChanged = void 0;
84602
86576
  var identity_1 = __webpack_require__(12418);
84603
86577
  var lift_1 = __webpack_require__(12370);
84604
- var OperatorSubscriber_1 = __webpack_require__(9974);
86578
+ var OperatorSubscriber_1 = __webpack_require__(83028);
84605
86579
  function distinctUntilChanged(comparator, keySelector) {
84606
86580
  if (keySelector === void 0) { keySelector = identity_1.identity; }
84607
86581
  comparator = comparator !== null && comparator !== void 0 ? comparator : defaultCompare;
@@ -84718,7 +86692,7 @@ exports.endWith = endWith;
84718
86692
  Object.defineProperty(exports, "__esModule", ({ value: true }));
84719
86693
  exports.every = void 0;
84720
86694
  var lift_1 = __webpack_require__(12370);
84721
- var OperatorSubscriber_1 = __webpack_require__(9974);
86695
+ var OperatorSubscriber_1 = __webpack_require__(83028);
84722
86696
  function every(predicate, thisArg) {
84723
86697
  return lift_1.operate(function (source, subscriber) {
84724
86698
  var index = 0;
@@ -84760,7 +86734,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
84760
86734
  exports.exhaustAll = void 0;
84761
86735
  var lift_1 = __webpack_require__(12370);
84762
86736
  var innerFrom_1 = __webpack_require__(17438);
84763
- var OperatorSubscriber_1 = __webpack_require__(9974);
86737
+ var OperatorSubscriber_1 = __webpack_require__(83028);
84764
86738
  function exhaustAll() {
84765
86739
  return lift_1.operate(function (source, subscriber) {
84766
86740
  var isComplete = false;
@@ -84793,7 +86767,7 @@ exports.exhaustMap = void 0;
84793
86767
  var map_1 = __webpack_require__(39446);
84794
86768
  var innerFrom_1 = __webpack_require__(17438);
84795
86769
  var lift_1 = __webpack_require__(12370);
84796
- var OperatorSubscriber_1 = __webpack_require__(9974);
86770
+ var OperatorSubscriber_1 = __webpack_require__(83028);
84797
86771
  function exhaustMap(project, resultSelector) {
84798
86772
  if (resultSelector) {
84799
86773
  return function (source) {
@@ -84852,7 +86826,7 @@ exports.expand = expand;
84852
86826
  Object.defineProperty(exports, "__esModule", ({ value: true }));
84853
86827
  exports.filter = void 0;
84854
86828
  var lift_1 = __webpack_require__(12370);
84855
- var OperatorSubscriber_1 = __webpack_require__(9974);
86829
+ var OperatorSubscriber_1 = __webpack_require__(83028);
84856
86830
  function filter(predicate, thisArg) {
84857
86831
  return lift_1.operate(function (source, subscriber) {
84858
86832
  var index = 0;
@@ -84895,7 +86869,7 @@ exports.finalize = finalize;
84895
86869
  Object.defineProperty(exports, "__esModule", ({ value: true }));
84896
86870
  exports.createFind = exports.find = void 0;
84897
86871
  var lift_1 = __webpack_require__(12370);
84898
- var OperatorSubscriber_1 = __webpack_require__(9974);
86872
+ var OperatorSubscriber_1 = __webpack_require__(83028);
84899
86873
  function find(predicate, thisArg) {
84900
86874
  return lift_1.operate(createFind(predicate, thisArg, 'value'));
84901
86875
  }
@@ -85001,7 +86975,7 @@ var Observable_1 = __webpack_require__(47082);
85001
86975
  var innerFrom_1 = __webpack_require__(17438);
85002
86976
  var Subject_1 = __webpack_require__(15235);
85003
86977
  var lift_1 = __webpack_require__(12370);
85004
- var OperatorSubscriber_1 = __webpack_require__(9974);
86978
+ var OperatorSubscriber_1 = __webpack_require__(83028);
85005
86979
  function groupBy(keySelector, elementOrOptions, duration, connector) {
85006
86980
  return lift_1.operate(function (source, subscriber) {
85007
86981
  var element;
@@ -85083,7 +87057,7 @@ var GroupBySubscriber = (function (_super) {
85083
87057
  Object.defineProperty(exports, "__esModule", ({ value: true }));
85084
87058
  exports.ignoreElements = void 0;
85085
87059
  var lift_1 = __webpack_require__(12370);
85086
- var OperatorSubscriber_1 = __webpack_require__(9974);
87060
+ var OperatorSubscriber_1 = __webpack_require__(83028);
85087
87061
  var noop_1 = __webpack_require__(3064);
85088
87062
  function ignoreElements() {
85089
87063
  return lift_1.operate(function (source, subscriber) {
@@ -85103,7 +87077,7 @@ exports.ignoreElements = ignoreElements;
85103
87077
  Object.defineProperty(exports, "__esModule", ({ value: true }));
85104
87078
  exports.isEmpty = void 0;
85105
87079
  var lift_1 = __webpack_require__(12370);
85106
- var OperatorSubscriber_1 = __webpack_require__(9974);
87080
+ var OperatorSubscriber_1 = __webpack_require__(83028);
85107
87081
  function isEmpty() {
85108
87082
  return lift_1.operate(function (source, subscriber) {
85109
87083
  source.subscribe(new OperatorSubscriber_1.OperatorSubscriber(subscriber, function () {
@@ -85172,7 +87146,7 @@ exports.last = last;
85172
87146
  Object.defineProperty(exports, "__esModule", ({ value: true }));
85173
87147
  exports.map = void 0;
85174
87148
  var lift_1 = __webpack_require__(12370);
85175
- var OperatorSubscriber_1 = __webpack_require__(9974);
87149
+ var OperatorSubscriber_1 = __webpack_require__(83028);
85176
87150
  function map(project, thisArg) {
85177
87151
  return lift_1.operate(function (source, subscriber) {
85178
87152
  var index = 0;
@@ -85211,7 +87185,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
85211
87185
  exports.materialize = void 0;
85212
87186
  var Notification_1 = __webpack_require__(89340);
85213
87187
  var lift_1 = __webpack_require__(12370);
85214
- var OperatorSubscriber_1 = __webpack_require__(9974);
87188
+ var OperatorSubscriber_1 = __webpack_require__(83028);
85215
87189
  function materialize() {
85216
87190
  return lift_1.operate(function (source, subscriber) {
85217
87191
  source.subscribe(new OperatorSubscriber_1.OperatorSubscriber(subscriber, function (value) {
@@ -85324,7 +87298,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
85324
87298
  exports.mergeInternals = void 0;
85325
87299
  var innerFrom_1 = __webpack_require__(17438);
85326
87300
  var executeSchedule_1 = __webpack_require__(28420);
85327
- var OperatorSubscriber_1 = __webpack_require__(9974);
87301
+ var OperatorSubscriber_1 = __webpack_require__(83028);
85328
87302
  function mergeInternals(source, subscriber, project, concurrent, onBeforeNext, expand, innerSubScheduler, additionalTeardown) {
85329
87303
  var buffer = [];
85330
87304
  var active = 0;
@@ -85552,7 +87526,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
85552
87526
  exports.observeOn = void 0;
85553
87527
  var executeSchedule_1 = __webpack_require__(28420);
85554
87528
  var lift_1 = __webpack_require__(12370);
85555
- var OperatorSubscriber_1 = __webpack_require__(9974);
87529
+ var OperatorSubscriber_1 = __webpack_require__(83028);
85556
87530
  function observeOn(scheduler, delay) {
85557
87531
  if (delay === void 0) { delay = 0; }
85558
87532
  return lift_1.operate(function (source, subscriber) {
@@ -85595,7 +87569,7 @@ exports.onErrorResumeNext = void 0;
85595
87569
  var lift_1 = __webpack_require__(12370);
85596
87570
  var innerFrom_1 = __webpack_require__(17438);
85597
87571
  var argsOrArgArray_1 = __webpack_require__(25796);
85598
- var OperatorSubscriber_1 = __webpack_require__(9974);
87572
+ var OperatorSubscriber_1 = __webpack_require__(83028);
85599
87573
  var noop_1 = __webpack_require__(3064);
85600
87574
  function onErrorResumeNext() {
85601
87575
  var sources = [];
@@ -85641,7 +87615,7 @@ exports.onErrorResumeNext = onErrorResumeNext;
85641
87615
  Object.defineProperty(exports, "__esModule", ({ value: true }));
85642
87616
  exports.pairwise = void 0;
85643
87617
  var lift_1 = __webpack_require__(12370);
85644
- var OperatorSubscriber_1 = __webpack_require__(9974);
87618
+ var OperatorSubscriber_1 = __webpack_require__(83028);
85645
87619
  function pairwise() {
85646
87620
  return lift_1.operate(function (source, subscriber) {
85647
87621
  var prev;
@@ -85908,7 +87882,7 @@ exports.reduce = reduce;
85908
87882
  Object.defineProperty(exports, "__esModule", ({ value: true }));
85909
87883
  exports.refCount = void 0;
85910
87884
  var lift_1 = __webpack_require__(12370);
85911
- var OperatorSubscriber_1 = __webpack_require__(9974);
87885
+ var OperatorSubscriber_1 = __webpack_require__(83028);
85912
87886
  function refCount() {
85913
87887
  return lift_1.operate(function (source, subscriber) {
85914
87888
  var connection = null;
@@ -85946,7 +87920,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
85946
87920
  exports.repeat = void 0;
85947
87921
  var empty_1 = __webpack_require__(18939);
85948
87922
  var lift_1 = __webpack_require__(12370);
85949
- var OperatorSubscriber_1 = __webpack_require__(9974);
87923
+ var OperatorSubscriber_1 = __webpack_require__(83028);
85950
87924
  var innerFrom_1 = __webpack_require__(17438);
85951
87925
  var timer_1 = __webpack_require__(64820);
85952
87926
  function repeat(countOrConfig) {
@@ -86017,7 +87991,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
86017
87991
  exports.repeatWhen = void 0;
86018
87992
  var Subject_1 = __webpack_require__(15235);
86019
87993
  var lift_1 = __webpack_require__(12370);
86020
- var OperatorSubscriber_1 = __webpack_require__(9974);
87994
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86021
87995
  function repeatWhen(notifier) {
86022
87996
  return lift_1.operate(function (source, subscriber) {
86023
87997
  var innerSub;
@@ -86072,7 +88046,7 @@ exports.repeatWhen = repeatWhen;
86072
88046
  Object.defineProperty(exports, "__esModule", ({ value: true }));
86073
88047
  exports.retry = void 0;
86074
88048
  var lift_1 = __webpack_require__(12370);
86075
- var OperatorSubscriber_1 = __webpack_require__(9974);
88049
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86076
88050
  var identity_1 = __webpack_require__(12418);
86077
88051
  var timer_1 = __webpack_require__(64820);
86078
88052
  var innerFrom_1 = __webpack_require__(17438);
@@ -86153,7 +88127,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
86153
88127
  exports.retryWhen = void 0;
86154
88128
  var Subject_1 = __webpack_require__(15235);
86155
88129
  var lift_1 = __webpack_require__(12370);
86156
- var OperatorSubscriber_1 = __webpack_require__(9974);
88130
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86157
88131
  function retryWhen(notifier) {
86158
88132
  return lift_1.operate(function (source, subscriber) {
86159
88133
  var innerSub;
@@ -86195,7 +88169,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
86195
88169
  exports.sample = void 0;
86196
88170
  var lift_1 = __webpack_require__(12370);
86197
88171
  var noop_1 = __webpack_require__(3064);
86198
- var OperatorSubscriber_1 = __webpack_require__(9974);
88172
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86199
88173
  function sample(notifier) {
86200
88174
  return lift_1.operate(function (source, subscriber) {
86201
88175
  var hasValue = false;
@@ -86263,7 +88237,7 @@ exports.scan = scan;
86263
88237
 
86264
88238
  Object.defineProperty(exports, "__esModule", ({ value: true }));
86265
88239
  exports.scanInternals = void 0;
86266
- var OperatorSubscriber_1 = __webpack_require__(9974);
88240
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86267
88241
  function scanInternals(accumulator, seed, hasSeed, emitOnNext, emitBeforeComplete) {
86268
88242
  return function (source, subscriber) {
86269
88243
  var hasState = hasSeed;
@@ -86297,7 +88271,7 @@ exports.scanInternals = scanInternals;
86297
88271
  Object.defineProperty(exports, "__esModule", ({ value: true }));
86298
88272
  exports.sequenceEqual = void 0;
86299
88273
  var lift_1 = __webpack_require__(12370);
86300
- var OperatorSubscriber_1 = __webpack_require__(9974);
88274
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86301
88275
  function sequenceEqual(compareTo, comparator) {
86302
88276
  if (comparator === void 0) { comparator = function (a, b) { return a === b; }; }
86303
88277
  return lift_1.operate(function (source, subscriber) {
@@ -86495,7 +88469,7 @@ var EmptyError_1 = __webpack_require__(77404);
86495
88469
  var SequenceError_1 = __webpack_require__(28585);
86496
88470
  var NotFoundError_1 = __webpack_require__(51403);
86497
88471
  var lift_1 = __webpack_require__(12370);
86498
- var OperatorSubscriber_1 = __webpack_require__(9974);
88472
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86499
88473
  function single(predicate) {
86500
88474
  return lift_1.operate(function (source, subscriber) {
86501
88475
  var hasValue = false;
@@ -86550,7 +88524,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
86550
88524
  exports.skipLast = void 0;
86551
88525
  var identity_1 = __webpack_require__(12418);
86552
88526
  var lift_1 = __webpack_require__(12370);
86553
- var OperatorSubscriber_1 = __webpack_require__(9974);
88527
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86554
88528
  function skipLast(skipCount) {
86555
88529
  return skipCount <= 0
86556
88530
  ?
@@ -86588,7 +88562,7 @@ exports.skipLast = skipLast;
86588
88562
  Object.defineProperty(exports, "__esModule", ({ value: true }));
86589
88563
  exports.skipUntil = void 0;
86590
88564
  var lift_1 = __webpack_require__(12370);
86591
- var OperatorSubscriber_1 = __webpack_require__(9974);
88565
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86592
88566
  var innerFrom_1 = __webpack_require__(17438);
86593
88567
  var noop_1 = __webpack_require__(3064);
86594
88568
  function skipUntil(notifier) {
@@ -86615,7 +88589,7 @@ exports.skipUntil = skipUntil;
86615
88589
  Object.defineProperty(exports, "__esModule", ({ value: true }));
86616
88590
  exports.skipWhile = void 0;
86617
88591
  var lift_1 = __webpack_require__(12370);
86618
- var OperatorSubscriber_1 = __webpack_require__(9974);
88592
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86619
88593
  function skipWhile(predicate) {
86620
88594
  return lift_1.operate(function (source, subscriber) {
86621
88595
  var taking = false;
@@ -86698,7 +88672,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
86698
88672
  exports.switchMap = void 0;
86699
88673
  var innerFrom_1 = __webpack_require__(17438);
86700
88674
  var lift_1 = __webpack_require__(12370);
86701
- var OperatorSubscriber_1 = __webpack_require__(9974);
88675
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86702
88676
  function switchMap(project, resultSelector) {
86703
88677
  return lift_1.operate(function (source, subscriber) {
86704
88678
  var innerSubscriber = null;
@@ -86773,7 +88747,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
86773
88747
  exports.take = void 0;
86774
88748
  var empty_1 = __webpack_require__(18939);
86775
88749
  var lift_1 = __webpack_require__(12370);
86776
- var OperatorSubscriber_1 = __webpack_require__(9974);
88750
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86777
88751
  function take(count) {
86778
88752
  return count <= 0
86779
88753
  ?
@@ -86815,7 +88789,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
86815
88789
  exports.takeLast = void 0;
86816
88790
  var empty_1 = __webpack_require__(18939);
86817
88791
  var lift_1 = __webpack_require__(12370);
86818
- var OperatorSubscriber_1 = __webpack_require__(9974);
88792
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86819
88793
  function takeLast(count) {
86820
88794
  return count <= 0
86821
88795
  ? function () { return empty_1.EMPTY; }
@@ -86858,7 +88832,7 @@ exports.takeLast = takeLast;
86858
88832
  Object.defineProperty(exports, "__esModule", ({ value: true }));
86859
88833
  exports.takeUntil = void 0;
86860
88834
  var lift_1 = __webpack_require__(12370);
86861
- var OperatorSubscriber_1 = __webpack_require__(9974);
88835
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86862
88836
  var innerFrom_1 = __webpack_require__(17438);
86863
88837
  var noop_1 = __webpack_require__(3064);
86864
88838
  function takeUntil(notifier) {
@@ -86880,7 +88854,7 @@ exports.takeUntil = takeUntil;
86880
88854
  Object.defineProperty(exports, "__esModule", ({ value: true }));
86881
88855
  exports.takeWhile = void 0;
86882
88856
  var lift_1 = __webpack_require__(12370);
86883
- var OperatorSubscriber_1 = __webpack_require__(9974);
88857
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86884
88858
  function takeWhile(predicate, inclusive) {
86885
88859
  if (inclusive === void 0) { inclusive = false; }
86886
88860
  return lift_1.operate(function (source, subscriber) {
@@ -86906,7 +88880,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
86906
88880
  exports.tap = void 0;
86907
88881
  var isFunction_1 = __webpack_require__(44366);
86908
88882
  var lift_1 = __webpack_require__(12370);
86909
- var OperatorSubscriber_1 = __webpack_require__(9974);
88883
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86910
88884
  var identity_1 = __webpack_require__(12418);
86911
88885
  function tap(observerOrNext, error, complete) {
86912
88886
  var tapObserver = isFunction_1.isFunction(observerOrNext) || error || complete
@@ -86956,7 +88930,7 @@ exports.tap = tap;
86956
88930
  Object.defineProperty(exports, "__esModule", ({ value: true }));
86957
88931
  exports.throttle = exports.defaultThrottleConfig = void 0;
86958
88932
  var lift_1 = __webpack_require__(12370);
86959
- var OperatorSubscriber_1 = __webpack_require__(9974);
88933
+ var OperatorSubscriber_1 = __webpack_require__(83028);
86960
88934
  var innerFrom_1 = __webpack_require__(17438);
86961
88935
  exports.defaultThrottleConfig = {
86962
88936
  leading: true,
@@ -87039,7 +89013,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
87039
89013
  exports.throwIfEmpty = void 0;
87040
89014
  var EmptyError_1 = __webpack_require__(77404);
87041
89015
  var lift_1 = __webpack_require__(12370);
87042
- var OperatorSubscriber_1 = __webpack_require__(9974);
89016
+ var OperatorSubscriber_1 = __webpack_require__(83028);
87043
89017
  function throwIfEmpty(errorFactory) {
87044
89018
  if (errorFactory === void 0) { errorFactory = defaultErrorFactory; }
87045
89019
  return lift_1.operate(function (source, subscriber) {
@@ -87112,7 +89086,7 @@ var isDate_1 = __webpack_require__(19327);
87112
89086
  var lift_1 = __webpack_require__(12370);
87113
89087
  var innerFrom_1 = __webpack_require__(17438);
87114
89088
  var createErrorClass_1 = __webpack_require__(92589);
87115
- var OperatorSubscriber_1 = __webpack_require__(9974);
89089
+ var OperatorSubscriber_1 = __webpack_require__(83028);
87116
89090
  var executeSchedule_1 = __webpack_require__(28420);
87117
89091
  exports.TimeoutError = createErrorClass_1.createErrorClass(function (_super) {
87118
89092
  return function TimeoutErrorImpl(info) {
@@ -87263,7 +89237,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
87263
89237
  exports.window = void 0;
87264
89238
  var Subject_1 = __webpack_require__(15235);
87265
89239
  var lift_1 = __webpack_require__(12370);
87266
- var OperatorSubscriber_1 = __webpack_require__(9974);
89240
+ var OperatorSubscriber_1 = __webpack_require__(83028);
87267
89241
  var noop_1 = __webpack_require__(3064);
87268
89242
  function window(windowBoundaries) {
87269
89243
  return lift_1.operate(function (source, subscriber) {
@@ -87312,7 +89286,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
87312
89286
  exports.windowCount = void 0;
87313
89287
  var Subject_1 = __webpack_require__(15235);
87314
89288
  var lift_1 = __webpack_require__(12370);
87315
- var OperatorSubscriber_1 = __webpack_require__(9974);
89289
+ var OperatorSubscriber_1 = __webpack_require__(83028);
87316
89290
  function windowCount(windowSize, startWindowEvery) {
87317
89291
  if (startWindowEvery === void 0) { startWindowEvery = 0; }
87318
89292
  var startEvery = startWindowEvery > 0 ? startWindowEvery : windowSize;
@@ -87377,7 +89351,7 @@ var Subject_1 = __webpack_require__(15235);
87377
89351
  var async_1 = __webpack_require__(11644);
87378
89352
  var Subscription_1 = __webpack_require__(69661);
87379
89353
  var lift_1 = __webpack_require__(12370);
87380
- var OperatorSubscriber_1 = __webpack_require__(9974);
89354
+ var OperatorSubscriber_1 = __webpack_require__(83028);
87381
89355
  var arrRemove_1 = __webpack_require__(19503);
87382
89356
  var args_1 = __webpack_require__(47844);
87383
89357
  var executeSchedule_1 = __webpack_require__(28420);
@@ -87469,7 +89443,7 @@ var Subject_1 = __webpack_require__(15235);
87469
89443
  var Subscription_1 = __webpack_require__(69661);
87470
89444
  var lift_1 = __webpack_require__(12370);
87471
89445
  var innerFrom_1 = __webpack_require__(17438);
87472
- var OperatorSubscriber_1 = __webpack_require__(9974);
89446
+ var OperatorSubscriber_1 = __webpack_require__(83028);
87473
89447
  var noop_1 = __webpack_require__(3064);
87474
89448
  var arrRemove_1 = __webpack_require__(19503);
87475
89449
  function windowToggle(openings, closingSelector) {
@@ -87543,7 +89517,7 @@ Object.defineProperty(exports, "__esModule", ({ value: true }));
87543
89517
  exports.windowWhen = void 0;
87544
89518
  var Subject_1 = __webpack_require__(15235);
87545
89519
  var lift_1 = __webpack_require__(12370);
87546
- var OperatorSubscriber_1 = __webpack_require__(9974);
89520
+ var OperatorSubscriber_1 = __webpack_require__(83028);
87547
89521
  var innerFrom_1 = __webpack_require__(17438);
87548
89522
  function windowWhen(closingSelector) {
87549
89523
  return lift_1.operate(function (source, subscriber) {
@@ -87612,7 +89586,7 @@ var __spreadArray = (this && this.__spreadArray) || function (to, from) {
87612
89586
  Object.defineProperty(exports, "__esModule", ({ value: true }));
87613
89587
  exports.withLatestFrom = void 0;
87614
89588
  var lift_1 = __webpack_require__(12370);
87615
- var OperatorSubscriber_1 = __webpack_require__(9974);
89589
+ var OperatorSubscriber_1 = __webpack_require__(83028);
87616
89590
  var innerFrom_1 = __webpack_require__(17438);
87617
89591
  var identity_1 = __webpack_require__(12418);
87618
89592
  var noop_1 = __webpack_require__(3064);
@@ -100133,11 +102107,13 @@ exports.PackageManager = PackageManager;
100133
102107
  (function (PackageManager) {
100134
102108
  PackageManager["Pnpm"] = "pnpm";
100135
102109
  PackageManager["Yarn"] = "yarn";
102110
+ PackageManager["Npm"] = "npm";
100136
102111
  })(PackageManager || (exports.PackageManager = PackageManager = {}));
100137
102112
 
100138
102113
  const PackageManagerName = {
100139
102114
  [PackageManager.Pnpm]: () => 'pnpm',
100140
- [PackageManager.Yarn]: () => 'Yarn'
102115
+ [PackageManager.Yarn]: () => 'Yarn',
102116
+ [PackageManager.Npm]: () => 'npm'
100141
102117
  };
100142
102118
  exports.PackageManagerName = PackageManagerName;
100143
102119
  const PackageManagerSchema = {
@@ -100146,7 +102122,7 @@ const PackageManagerSchema = {
100146
102122
  label: () => _locale.i18n.t(_locale.localeKeys.packageManager.self),
100147
102123
  mutualExclusion: true,
100148
102124
  when: (_values, extra) => !(extra !== null && extra !== void 0 && extra.isMonorepoSubProject),
100149
- 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 => ({
100150
102126
  key: packageManager,
100151
102127
  label: PackageManagerName[packageManager]
100152
102128
  }))
@@ -100386,7 +102362,7 @@ const SubSolutionSchema = {
100386
102362
  }));
100387
102363
 
100388
102364
  if (data.solution && data.solution !== 'custom') {
100389
- items.push({
102365
+ items.unshift({
100390
102366
  key: data.solution,
100391
102367
  label: `${SubSolutionText[data.solution]()}(${_locale.i18n.t(_locale.localeKeys.solution.default)})`
100392
102368
  });
@@ -100670,7 +102646,8 @@ const EN_LOCALE = {
100670
102646
  mwa_storybook: 'Enable "Visual Testing (Storybook)"',
100671
102647
  ssg: 'Enable "SSG"',
100672
102648
  polyfill: 'Enable "UA-based Polyfill feature"',
100673
- deploy: 'Enable "Deploy"'
102649
+ deploy: 'Enable "Deploy"',
102650
+ proxy: 'Enable "Global Proxy"'
100674
102651
  },
100675
102652
  element: {
100676
102653
  self: 'Create project element',
@@ -100835,8 +102812,9 @@ const ZH_LOCALE = {
100835
102812
  runtime_api: '启用「Rumtime API」',
100836
102813
  mwa_storybook: '启用「Visual Testing (Storybook)」模式',
100837
102814
  ssg: '启用「SSG」功能',
100838
- polyfill: '启用基于「UA 的 Polyfill」功能',
100839
- deploy: '启用「部署」功能'
102815
+ polyfill: '启用「基于 UA 的 Polyfill」功能',
102816
+ deploy: '启用「部署」功能',
102817
+ proxy: '启用「全局代理」'
100840
102818
  },
100841
102819
  element: {
100842
102820
  self: '创建工程元素',
@@ -101615,6 +103593,7 @@ exports.ActionFunction = ActionFunction;
101615
103593
  ActionFunction["SSG"] = "ssg";
101616
103594
  ActionFunction["Polyfill"] = "polyfill";
101617
103595
  ActionFunction["Deploy"] = "deploy";
103596
+ ActionFunction["Proxy"] = "proxy";
101618
103597
  })(ActionFunction || (exports.ActionFunction = ActionFunction = {}));
101619
103598
 
101620
103599
  let ActionRefactor;
@@ -101651,7 +103630,8 @@ const ActionFunctionText = {
101651
103630
  [ActionFunction.RuntimeApi]: () => _locale.i18n.t(_locale.localeKeys.action.function.runtime_api),
101652
103631
  [ActionFunction.SSG]: () => _locale.i18n.t(_locale.localeKeys.action.function.ssg),
101653
103632
  [ActionFunction.Polyfill]: () => _locale.i18n.t(_locale.localeKeys.action.function.polyfill),
101654
- [ActionFunction.Deploy]: () => _locale.i18n.t(_locale.localeKeys.action.function.deploy)
103633
+ [ActionFunction.Deploy]: () => _locale.i18n.t(_locale.localeKeys.action.function.deploy),
103634
+ [ActionFunction.Proxy]: () => _locale.i18n.t(_locale.localeKeys.action.function.proxy)
101655
103635
  };
101656
103636
  exports.ActionFunctionText = ActionFunctionText;
101657
103637
  const ActionRefactorText = {
@@ -101876,7 +103856,7 @@ exports.MWAActionTypes = MWAActionTypes;
101876
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,
101877
103857
  _common.ActionFunction.Test, _common.ActionFunction.Storybook, // ActionFunction.E2ETest,
101878
103858
  // ActionFunction.Doc,
101879
- _common.ActionFunction.Polyfill, _common.ActionFunction.Deploy];
103859
+ _common.ActionFunction.Polyfill, _common.ActionFunction.Deploy, _common.ActionFunction.Proxy];
101880
103860
  exports.MWAActionFunctions = MWAActionFunctions;
101881
103861
  const MWAActionElements = [_common.ActionElement.Entry, _common.ActionElement.Server];
101882
103862
  exports.MWAActionElements = MWAActionElements;
@@ -101923,14 +103903,15 @@ const MWAActionFunctionsDevDependencies = {
101923
103903
  [_common.ActionFunction.E2ETest]: '@modern-js/plugin-e2e',
101924
103904
  [_common.ActionFunction.Doc]: '@modern-js/plugin-docsite',
101925
103905
  [_common.ActionFunction.Electron]: '@modern-js/plugin-electron',
101926
- [_common.ActionFunction.Storybook]: '@modern-js/plugin-storybook'
103906
+ [_common.ActionFunction.Storybook]: '@modern-js/plugin-storybook',
103907
+ [_common.ActionFunction.Proxy]: '@modern-js/plugin-proxy'
101927
103908
  };
101928
103909
  exports.MWAActionFunctionsDevDependencies = MWAActionFunctionsDevDependencies;
101929
103910
  const MWAActionFunctionsDependencies = {
101930
103911
  [_common.ActionFunction.Less]: '@modern-js/plugin-less',
101931
103912
  [_common.ActionFunction.Sass]: '@modern-js/plugin-sass',
101932
103913
  [_common.ActionFunction.BFF]: '@modern-js/plugin-bff',
101933
- [_common.ActionFunction.MicroFrontend]: '@modern-js/plugin-micro-frontend',
103914
+ [_common.ActionFunction.MicroFrontend]: '@modern-js/plugin-garfish',
101934
103915
  [_common.ActionFunction.I18n]: '@modern-js/plugin-i18n',
101935
103916
  [_common.ActionFunction.SSG]: '@modern-js/plugin-ssg',
101936
103917
  [_common.ActionFunction.Polyfill]: '@modern-js/plugin-polyfill'
@@ -101938,7 +103919,7 @@ const MWAActionFunctionsDependencies = {
101938
103919
  exports.MWAActionFunctionsDependencies = MWAActionFunctionsDependencies;
101939
103920
  const MWAActionFunctionsAppendTypeContent = {
101940
103921
  [_common.ActionFunction.Test]: `/// <reference types='@modern-js/plugin-testing/type' />`,
101941
- [_common.ActionFunction.MicroFrontend]: `/// <reference types='@modern-js/plugin-micro-frontend/type' />`
103922
+ [_common.ActionFunction.MicroFrontend]: `/// <reference types='@modern-js/plugin-garfish/type' />`
101942
103923
  };
101943
103924
  exports.MWAActionFunctionsAppendTypeContent = MWAActionFunctionsAppendTypeContent;
101944
103925
  const MWANewActionGenerators = {
@@ -101961,7 +103942,8 @@ const MWANewActionGenerators = {
101961
103942
  [_common.ActionFunction.Storybook]: '@modern-js/dependence-generator',
101962
103943
  [_common.ActionFunction.SSG]: '@modern-js/ssg-generator',
101963
103944
  [_common.ActionFunction.Polyfill]: '@modern-js/dependence-generator',
101964
- [_common.ActionFunction.Deploy]: '@modern-js/cloud-deploy-generator'
103945
+ [_common.ActionFunction.Deploy]: '@modern-js/cloud-deploy-generator',
103946
+ [_common.ActionFunction.Proxy]: '@modern-js/dependence-generator'
101965
103947
  },
101966
103948
  [_common.ActionType.Refactor]: {
101967
103949
  [_common.ActionRefactor.BFFToApp]: '@modern-js/bff-refactor-generator'
@@ -101971,7 +103953,7 @@ exports.MWANewActionGenerators = MWANewActionGenerators;
101971
103953
 
101972
103954
  /***/ }),
101973
103955
 
101974
- /***/ 99457:
103956
+ /***/ 82022:
101975
103957
  /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
101976
103958
 
101977
103959
  "use strict";
@@ -102008,7 +103990,7 @@ __webpack_require__.d(handlers_namespaceObject, {
102008
103990
  "rootNode": () => (rootNode)
102009
103991
  });
102010
103992
 
102011
- // NAMESPACE OBJECT: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.7/node_modules/@modern-js/codesmith-api-app/dist/js/modern/handlers/index.js
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
102012
103994
  var modern_handlers_namespaceObject = {};
102013
103995
  __webpack_require__.r(modern_handlers_namespaceObject);
102014
103996
  __webpack_require__.d(modern_handlers_namespaceObject, {
@@ -102227,8 +104209,9 @@ const zh_ZH_LOCALE = {
102227
104209
  runtime_api: '启用「Rumtime API」',
102228
104210
  mwa_storybook: '启用「Visual Testing (Storybook)」模式',
102229
104211
  ssg: '启用「SSG」功能',
102230
- polyfill: '启用基于「UA 的 Polyfill」功能',
102231
- deploy: '启用「部署」功能'
104212
+ polyfill: '启用「基于 UA 的 Polyfill」功能',
104213
+ deploy: '启用「部署」功能',
104214
+ proxy: '启用「全局代理」'
102232
104215
  },
102233
104216
  element: {
102234
104217
  self: '创建工程元素',
@@ -102356,7 +104339,8 @@ const en_EN_LOCALE = {
102356
104339
  mwa_storybook: 'Enable "Visual Testing (Storybook)"',
102357
104340
  ssg: 'Enable "SSG"',
102358
104341
  polyfill: 'Enable "UA-based Polyfill feature"',
102359
- deploy: 'Enable "Deploy"'
104342
+ deploy: 'Enable "Deploy"',
104343
+ proxy: 'Enable "Global Proxy"'
102360
104344
  },
102361
104345
  element: {
102362
104346
  self: 'Create project element',
@@ -102459,11 +104443,13 @@ let PackageManager;
102459
104443
  (function (PackageManager) {
102460
104444
  PackageManager["Pnpm"] = "pnpm";
102461
104445
  PackageManager["Yarn"] = "yarn";
104446
+ PackageManager["Npm"] = "npm";
102462
104447
  })(PackageManager || (PackageManager = {}));
102463
104448
 
102464
104449
  const PackageManagerName = {
102465
104450
  [PackageManager.Pnpm]: () => 'pnpm',
102466
- [PackageManager.Yarn]: () => 'Yarn'
104451
+ [PackageManager.Yarn]: () => 'Yarn',
104452
+ [PackageManager.Npm]: () => 'npm'
102467
104453
  };
102468
104454
  const PackageManagerSchema = {
102469
104455
  key: 'packageManager',
@@ -102471,7 +104457,7 @@ const PackageManagerSchema = {
102471
104457
  label: () => modern_locale_i18n.t(modern_locale_localeKeys.packageManager.self),
102472
104458
  mutualExclusion: true,
102473
104459
  when: (_values, extra) => !(extra !== null && extra !== void 0 && extra.isMonorepoSubProject),
102474
- 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 => ({
102475
104461
  key: packageManager,
102476
104462
  label: PackageManagerName[packageManager]
102477
104463
  }))
@@ -102615,7 +104601,7 @@ const SubSolutionSchema = {
102615
104601
  }));
102616
104602
 
102617
104603
  if (data.solution && data.solution !== 'custom') {
102618
- items.push({
104604
+ items.unshift({
102619
104605
  key: data.solution,
102620
104606
  label: `${SubSolutionText[data.solution]()}(${modern_locale_i18n.t(modern_locale_localeKeys.solution["default"])})`
102621
104607
  });
@@ -103038,6 +105024,9 @@ class JsonAPI {
103038
105024
  // EXTERNAL MODULE: ../../../../node_modules/.pnpm/glob-promise@4.2.2_glob@7.2.0/node_modules/glob-promise/lib/index.js
103039
105025
  var glob_promise_lib = __webpack_require__(39646);
103040
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);
103041
105030
  ;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith@1.0.8/node_modules/@modern-js/codesmith/dist/js/modern/materials/constants.js
103042
105031
  const IMAGE_EXT_LIST = ['.jpg', '.jpeg', '.png', '.gif', '.bmp', '.ico', '.icon', '.mpt', '.psd', '.wmf'];
103043
105032
  ;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith@1.0.8/node_modules/@modern-js/codesmith/dist/js/modern/materials/FsResource.js
@@ -103058,12 +105047,12 @@ class FsResource {
103058
105047
  const resourceFileExt = external_path_default().extname(this.filePath);
103059
105048
 
103060
105049
  if (IMAGE_EXT_LIST.includes(resourceFileExt)) {
103061
- const buffer = await lib_default().readFile(external_path_default().resolve(this.filePath));
105050
+ const buffer = await fs_extra_lib_default().readFile(external_path_default().resolve(this.filePath));
103062
105051
  return {
103063
105052
  content: buffer
103064
105053
  };
103065
105054
  } else {
103066
- const text = await lib_default().readFile(external_path_default().resolve(this.filePath), 'utf8');
105055
+ const text = await fs_extra_lib_default().readFile(external_path_default().resolve(this.filePath), 'utf8');
103067
105056
  return {
103068
105057
  content: text
103069
105058
  };
@@ -103595,13 +105584,14 @@ var PluginFileAPI = /*#__PURE__*/function () {
103595
105584
  while (1) {
103596
105585
  switch (_context4.prev = _context4.next) {
103597
105586
  case 0:
103598
- update = Object.keys(updateInfo).map(function (key) {
103599
- return context_file_defineProperty({}, "modernConfig.".concat(key), updateInfo[key]);
105587
+ update = {};
105588
+ Object.keys(updateInfo).forEach(function (key) {
105589
+ update["modernConfig.".concat(key)] = updateInfo[key];
103600
105590
  });
103601
- _context4.next = 3;
105591
+ _context4.next = 4;
103602
105592
  return this.updateJSONFile('package.json', update);
103603
105593
 
103604
- case 3:
105594
+ case 4:
103605
105595
  case "end":
103606
105596
  return _context4.stop();
103607
105597
  }
@@ -104694,6 +106684,7 @@ let ActionFunction;
104694
106684
  ActionFunction["SSG"] = "ssg";
104695
106685
  ActionFunction["Polyfill"] = "polyfill";
104696
106686
  ActionFunction["Deploy"] = "deploy";
106687
+ ActionFunction["Proxy"] = "proxy";
104697
106688
  })(ActionFunction || (ActionFunction = {}));
104698
106689
 
104699
106690
  let ActionRefactor;
@@ -104727,7 +106718,8 @@ const ActionFunctionText = {
104727
106718
  [ActionFunction.RuntimeApi]: () => modern_locale_i18n.t(modern_locale_localeKeys.action["function"].runtime_api),
104728
106719
  [ActionFunction.SSG]: () => modern_locale_i18n.t(modern_locale_localeKeys.action["function"].ssg),
104729
106720
  [ActionFunction.Polyfill]: () => modern_locale_i18n.t(modern_locale_localeKeys.action["function"].polyfill),
104730
- [ActionFunction.Deploy]: () => modern_locale_i18n.t(modern_locale_localeKeys.action["function"].deploy)
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)
104731
106723
  };
104732
106724
  const ActionRefactorText = {
104733
106725
  [ActionRefactor.BFFToApp]: () => modern_locale_i18n.t(modern_locale_localeKeys.action.refactor.bff_to_app)
@@ -104745,7 +106737,7 @@ const MWAActionTypes = [ActionType.Element, ActionType.Function // ActionType.Re
104745
106737
  const MWAActionFunctions = [ActionFunction.UnBundle, ActionFunction.TailwindCSS, ActionFunction.Less, ActionFunction.Sass, ActionFunction.BFF, ActionFunction.SSG, ActionFunction.MicroFrontend, ActionFunction.Electron, // ActionFunction.I18n,
104746
106738
  ActionFunction.Test, ActionFunction.Storybook, // ActionFunction.E2ETest,
104747
106739
  // ActionFunction.Doc,
104748
- ActionFunction.Polyfill, ActionFunction.Deploy];
106740
+ ActionFunction.Polyfill, ActionFunction.Deploy, ActionFunction.Proxy];
104749
106741
  const MWAActionElements = [ActionElement.Entry, ActionElement.Server];
104750
106742
  const MWAActionReactors = [ActionRefactor.BFFToApp];
104751
106743
  const MWAActionTypesMap = {
@@ -104786,20 +106778,21 @@ const MWAActionFunctionsDevDependencies = {
104786
106778
  [ActionFunction.E2ETest]: '@modern-js/plugin-e2e',
104787
106779
  [ActionFunction.Doc]: '@modern-js/plugin-docsite',
104788
106780
  [ActionFunction.Electron]: '@modern-js/plugin-electron',
104789
- [ActionFunction.Storybook]: '@modern-js/plugin-storybook'
106781
+ [ActionFunction.Storybook]: '@modern-js/plugin-storybook',
106782
+ [ActionFunction.Proxy]: '@modern-js/plugin-proxy'
104790
106783
  };
104791
106784
  const MWAActionFunctionsDependencies = {
104792
106785
  [ActionFunction.Less]: '@modern-js/plugin-less',
104793
106786
  [ActionFunction.Sass]: '@modern-js/plugin-sass',
104794
106787
  [ActionFunction.BFF]: '@modern-js/plugin-bff',
104795
- [ActionFunction.MicroFrontend]: '@modern-js/plugin-micro-frontend',
106788
+ [ActionFunction.MicroFrontend]: '@modern-js/plugin-garfish',
104796
106789
  [ActionFunction.I18n]: '@modern-js/plugin-i18n',
104797
106790
  [ActionFunction.SSG]: '@modern-js/plugin-ssg',
104798
106791
  [ActionFunction.Polyfill]: '@modern-js/plugin-polyfill'
104799
106792
  };
104800
106793
  const MWAActionFunctionsAppendTypeContent = {
104801
106794
  [ActionFunction.Test]: `/// <reference types='@modern-js/plugin-testing/type' />`,
104802
- [ActionFunction.MicroFrontend]: `/// <reference types='@modern-js/plugin-micro-frontend/type' />`
106795
+ [ActionFunction.MicroFrontend]: `/// <reference types='@modern-js/plugin-garfish/type' />`
104803
106796
  };
104804
106797
  const MWANewActionGenerators = {
104805
106798
  [ActionType.Element]: {
@@ -104821,7 +106814,8 @@ const MWANewActionGenerators = {
104821
106814
  [ActionFunction.Storybook]: '@modern-js/dependence-generator',
104822
106815
  [ActionFunction.SSG]: '@modern-js/ssg-generator',
104823
106816
  [ActionFunction.Polyfill]: '@modern-js/dependence-generator',
104824
- [ActionFunction.Deploy]: '@modern-js/cloud-deploy-generator'
106817
+ [ActionFunction.Deploy]: '@modern-js/cloud-deploy-generator',
106818
+ [ActionFunction.Proxy]: '@modern-js/dependence-generator'
104825
106819
  },
104826
106820
  [ActionType.Refactor]: {
104827
106821
  [ActionRefactor.BFFToApp]: '@modern-js/bff-refactor-generator'
@@ -104929,7 +106923,7 @@ const nodeRequire = path => {
104929
106923
 
104930
106924
  async function fsExists(path) {
104931
106925
  try {
104932
- await lib_default().access(path);
106926
+ await fs_extra_lib_default().access(path);
104933
106927
  return true;
104934
106928
  } catch (e) {
104935
106929
  return false;
@@ -104942,7 +106936,7 @@ async function fsExists(path) {
104942
106936
  const MaxTimes = 5;
104943
106937
  async function getGeneratorDir(generator) {
104944
106938
  let result = generator;
104945
- const isDirectory = (await lib_default().stat(generator)).isDirectory();
106939
+ const isDirectory = (await fs_extra_lib_default().stat(generator)).isDirectory();
104946
106940
 
104947
106941
  if (!isDirectory) {
104948
106942
  result = external_path_default().dirname(generator);
@@ -104989,8 +106983,8 @@ class GeneratorCore {
104989
106983
  this.output = {
104990
106984
  fs: async (file, content, options) => {
104991
106985
  const filePath = external_path_default().resolve(this.outputPath, file.toString());
104992
- await lib_default().mkdirp(external_path_default().dirname(filePath));
104993
- await lib_default().writeFile(filePath, content, options);
106986
+ await fs_extra_lib_default().mkdirp(external_path_default().dirname(filePath));
106987
+ await fs_extra_lib_default().writeFile(filePath, content, options);
104994
106988
  }
104995
106989
  };
104996
106990
  this._context = void 0;
@@ -105389,11 +107383,11 @@ async function runInstall(targetDir, registryUrl) {
105389
107383
 
105390
107384
  try {
105391
107385
  const pkgPath = external_path_default().join(targetDir, 'package.json');
105392
- const pkgJSON = JSON.parse(lib_default().readFileSync(pkgPath, {
107386
+ const pkgJSON = JSON.parse(fs_extra_lib_default().readFileSync(pkgPath, {
105393
107387
  encoding: 'utf-8'
105394
107388
  }));
105395
107389
  delete pkgJSON.devDependencies;
105396
- lib_default().writeFileSync(pkgPath, JSON.stringify(pkgJSON, null, 2), {
107390
+ fs_extra_lib_default().writeFileSync(pkgPath, JSON.stringify(pkgJSON, null, 2), {
105397
107391
  encoding: 'utf-8'
105398
107392
  });
105399
107393
  } catch (e) {
@@ -105445,7 +107439,7 @@ async function isValidCache(cacheDir) {
105445
107439
  * 2. cache time is within the validity period
105446
107440
  */
105447
107441
  if (await fsExists(`${cacheDir}/.codesmith.completed`)) {
105448
- const preCacheTimeStr = await lib_default().readFile(`${cacheDir}/.codesmith.completed`, {
107442
+ const preCacheTimeStr = await fs_extra_lib_default().readFile(`${cacheDir}/.codesmith.completed`, {
105449
107443
  encoding: 'utf-8'
105450
107444
  });
105451
107445
  const preCacheTime = preCacheTimeStr ? new Date(preCacheTimeStr) : new Date(0);
@@ -105475,7 +107469,7 @@ async function downloadAndDecompressTargz(tarballPkg, targetDir) {
105475
107469
 
105476
107470
  const randomId = Math.floor(Math.random() * 10000);
105477
107471
  const tempTgzFilePath = `${external_os_default().tmpdir()}/temp-${randomId}.tgz`;
105478
- const dest = lib_default().createWriteStream(tempTgzFilePath);
107472
+ const dest = fs_extra_lib_default().createWriteStream(tempTgzFilePath);
105479
107473
  await new Promise((resolve, reject) => {
105480
107474
  response.data.pipe(dest);
105481
107475
  response.data.on('error', err => {
@@ -105486,12 +107480,12 @@ async function downloadAndDecompressTargz(tarballPkg, targetDir) {
105486
107480
  });
105487
107481
  });
105488
107482
 
105489
- if ((await lib_default().stat(tempTgzFilePath)).size !== contentLength) {
107483
+ if ((await fs_extra_lib_default().stat(tempTgzFilePath)).size !== contentLength) {
105490
107484
  throw new Error('download tar package get bad content length');
105491
107485
  }
105492
107486
 
105493
107487
  await new Promise((resolve, reject) => {
105494
- lib_default().createReadStream(tempTgzFilePath).pipe(tar.x({
107488
+ fs_extra_lib_default().createReadStream(tempTgzFilePath).pipe(tar.x({
105495
107489
  strip: 1,
105496
107490
  C: `${targetDir}`
105497
107491
  })).on('finish', () => {
@@ -105531,8 +107525,8 @@ async function downloadPackage(pkgName, pkgVersion = 'latest', options = {}) {
105531
107525
  return targetDir;
105532
107526
  }
105533
107527
 
105534
- await lib_default().remove(targetDir);
105535
- await lib_default().mkdirp(targetDir); // get package tarball
107528
+ await fs_extra_lib_default().remove(targetDir);
107529
+ await fs_extra_lib_default().mkdirp(targetDir); // get package tarball
105536
107530
 
105537
107531
  const tarballPkg = await getNpmTarballUrl(pkgName, version, {
105538
107532
  registryUrl
@@ -105545,7 +107539,7 @@ async function downloadPackage(pkgName, pkgVersion = 'latest', options = {}) {
105545
107539
  } // write completed flag
105546
107540
 
105547
107541
 
105548
- await lib_default().writeFile(`${targetDir}/.codesmith.completed`, new Date().toISOString(), {
107542
+ await fs_extra_lib_default().writeFile(`${targetDir}/.codesmith.completed`, new Date().toISOString(), {
105549
107543
  encoding: 'utf-8'
105550
107544
  });
105551
107545
  return targetDir;
@@ -107338,7 +109332,7 @@ setCliQuestionsHandlers(handlers_namespaceObject);
107338
109332
  // EXTERNAL MODULE: ../../../../node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isUndefined.js
107339
109333
  var isUndefined = __webpack_require__(88066);
107340
109334
  var isUndefined_default = /*#__PURE__*/__webpack_require__.n(isUndefined);
107341
- ;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.7/node_modules/@modern-js/codesmith-api-app/dist/js/modern/utils/transformSchema.js
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
107342
109336
 
107343
109337
 
107344
109338
  function transformSchema(schema, configValue = {}, validateMap = {}) {
@@ -107605,7 +109599,7 @@ class List extends (base_default()) {
107605
109599
  }
107606
109600
 
107607
109601
  }
107608
- ;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.7/node_modules/@modern-js/codesmith-api-app/dist/js/modern/handlers/constant.js
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
107609
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; }
107610
109604
 
107611
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; }
@@ -107614,7 +109608,7 @@ function constant_defineProperty(obj, key, value) { if (key in obj) { Object.def
107614
109608
 
107615
109609
 
107616
109610
  const constant_CLI_TYPE = constant_objectSpread({}, CLI_TYPE);
107617
- ;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.7/node_modules/@modern-js/codesmith-api-app/dist/js/modern/handlers/ListNode.js
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
107618
109612
 
107619
109613
 
107620
109614
 
@@ -107696,9 +109690,9 @@ const ListNode_listNode = options => {
107696
109690
  return true;
107697
109691
  };
107698
109692
  };
107699
- ;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.7/node_modules/@modern-js/codesmith-api-app/dist/js/modern/handlers/index.js
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
107700
109694
 
107701
- ;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+plugin-i18n@1.1.2/node_modules/@modern-js/plugin-i18n/dist/js/modern/utils/index.js
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
107702
109696
 
107703
109697
 
107704
109698
  function utils_getObjKeyMap(obj, prefix = '') {
@@ -107712,7 +109706,7 @@ function utils_getObjKeyMap(obj, prefix = '') {
107712
109706
  });
107713
109707
  return result;
107714
109708
  }
107715
- ;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+plugin-i18n@1.1.2/node_modules/@modern-js/plugin-i18n/dist/js/modern/index.js
109709
+ ;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+plugin-i18n@1.2.2/node_modules/@modern-js/plugin-i18n/dist/js/modern/index.js
107716
109710
 
107717
109711
 
107718
109712
 
@@ -107779,12 +109773,12 @@ class modern_I18n {
107779
109773
  }
107780
109774
 
107781
109775
 
107782
- ;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.7/node_modules/@modern-js/codesmith-api-app/dist/js/modern/locale/zh.js
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
107783
109777
  const locale_zh_ZH_LOCALE = {
107784
109778
  environment: {
107785
109779
  node_version: '请升级 Node 版本至 LIS',
107786
109780
  nvm_install: '检测到环境中未安装 nvm,请先安装 nvm',
107787
- yarn_pnpm: '检测到环境中未安装 yarn 或者 pnpm,请先安装 yarn pnpm'
109781
+ yarn_pnpm_npm: '检测到环境中未安装包管理工具,请先安装 yarn pnpm 或 npm'
107788
109782
  },
107789
109783
  install: {
107790
109784
  failed: '依赖自动安装失败,请手动执行 `{command}` 命令进行安装',
@@ -107805,12 +109799,12 @@ const locale_zh_ZH_LOCALE = {
107805
109799
  info: '成功!'
107806
109800
  }
107807
109801
  };
107808
- ;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.7/node_modules/@modern-js/codesmith-api-app/dist/js/modern/locale/en.js
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
107809
109803
  const locale_en_EN_LOCALE = {
107810
109804
  environment: {
107811
109805
  node_version: 'please upgrade node to lts version',
107812
109806
  nvm_install: 'please install nvm first',
107813
- yarn_pnpm: 'please install yarn or pnpm first'
109807
+ yarn_pnpm_npm: 'please install yarn or pnpm or npm first'
107814
109808
  },
107815
109809
  install: {
107816
109810
  failed: 'dependencies install failed, please execute `{command}` to install the dependencies ',
@@ -107831,7 +109825,7 @@ const locale_en_EN_LOCALE = {
107831
109825
  info: 'Success!'
107832
109826
  }
107833
109827
  };
107834
- ;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.7/node_modules/@modern-js/codesmith-api-app/dist/js/modern/locale/index.js
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
107835
109829
 
107836
109830
 
107837
109831
 
@@ -107841,7 +109835,7 @@ const js_modern_locale_localeKeys = js_modern_locale_i18n.init('zh', {
107841
109835
  en: locale_en_EN_LOCALE
107842
109836
  });
107843
109837
 
107844
- ;// CONCATENATED MODULE: ../../../../node_modules/.pnpm/@modern-js+codesmith-api-app@1.0.7/node_modules/@modern-js/codesmith-api-app/dist/js/modern/index.js
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
107845
109839
 
107846
109840
 
107847
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; }
@@ -107886,9 +109880,9 @@ class AppAPI {
107886
109880
  return false;
107887
109881
  }
107888
109882
 
107889
- if (!(await canUseYarn()) && !(await canUsePnpm())) {
107890
- this.generatorCore.logger.debug("can't use yarn or pnpm");
107891
- this.generatorCore.logger.warn(js_modern_locale_i18n.t(js_modern_locale_localeKeys.environment.yarn_pnpm));
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));
107892
109886
  return false;
107893
109887
  }
107894
109888
 
@@ -108002,15 +109996,15 @@ class AppAPI {
108002
109996
  filePath
108003
109997
  } = this.generatorContext.materials.default.get(workspaceName);
108004
109998
 
108005
- if (!lib_default().existsSync(filePath)) {
109999
+ if (!fs_extra_lib_default().existsSync(filePath)) {
108006
110000
  return;
108007
110001
  }
108008
110002
 
108009
- const content = await lib_default().readFile(filePath);
110003
+ const content = await fs_extra_lib_default().readFile(filePath);
108010
110004
  const workspace = (0,src.parse)(content.toString());
108011
110005
  workspace.folders = [folder, ...(workspace.folders || [])];
108012
110006
  const indent = 2;
108013
- await lib_default().writeFile(filePath, (0,src.stringify)(workspace, null, indent), {
110007
+ await fs_extra_lib_default().writeFile(filePath, (0,src.stringify)(workspace, null, indent), {
108014
110008
  encoding: 'utf-8'
108015
110009
  });
108016
110010
  }
@@ -111277,11 +113271,11 @@ var _merge2 = _interopRequireDefault(__webpack_require__(13904));
111277
113271
 
111278
113272
  var _path = _interopRequireDefault(__webpack_require__(71017));
111279
113273
 
111280
- var _codesmithApiApp = __webpack_require__(83028);
113274
+ var _codesmithApiApp = __webpack_require__(80355);
111281
113275
 
111282
113276
  var _generatorCommon = __webpack_require__(50828);
111283
113277
 
111284
- var _generatorPlugin = __webpack_require__(99457);
113278
+ var _generatorPlugin = __webpack_require__(82022);
111285
113279
 
111286
113280
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
111287
113281