vercel 28.18.4 → 28.19.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +1192 -1006
- package/package.json +13 -29
package/dist/index.js
CHANGED
@@ -3,6 +3,22 @@ module.exports =
|
|
3
3
|
/******/ (() => { // webpackBootstrap
|
4
4
|
/******/ var __webpack_modules__ = ({
|
5
5
|
|
6
|
+
/***/ 98551:
|
7
|
+
/***/ ((__unused_webpack_module, exports) => {
|
8
|
+
|
9
|
+
"use strict";
|
10
|
+
|
11
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
12
|
+
exports.PROJECT_ENV_TARGET = void 0;
|
13
|
+
exports.PROJECT_ENV_TARGET = [
|
14
|
+
'production',
|
15
|
+
'preview',
|
16
|
+
'development',
|
17
|
+
];
|
18
|
+
//# sourceMappingURL=index.js.map
|
19
|
+
|
20
|
+
/***/ }),
|
21
|
+
|
6
22
|
/***/ 20077:
|
7
23
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
8
24
|
|
@@ -64,31 +80,6 @@ exports.getPackageJSON = getPackageJSON;
|
|
64
80
|
|
65
81
|
/***/ }),
|
66
82
|
|
67
|
-
/***/ 76210:
|
68
|
-
/***/ ((__unused_webpack_module, exports) => {
|
69
|
-
|
70
|
-
"use strict";
|
71
|
-
|
72
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
73
|
-
exports.ProjectEnvType = exports.ProjectEnvTarget = void 0;
|
74
|
-
// TODO (Ethan-Arrowood) - Replace enums
|
75
|
-
var ProjectEnvTarget;
|
76
|
-
(function (ProjectEnvTarget) {
|
77
|
-
ProjectEnvTarget["Production"] = "production";
|
78
|
-
ProjectEnvTarget["Preview"] = "preview";
|
79
|
-
ProjectEnvTarget["Development"] = "development";
|
80
|
-
})(ProjectEnvTarget = exports.ProjectEnvTarget || (exports.ProjectEnvTarget = {}));
|
81
|
-
var ProjectEnvType;
|
82
|
-
(function (ProjectEnvType) {
|
83
|
-
ProjectEnvType["Plaintext"] = "plain";
|
84
|
-
ProjectEnvType["Secret"] = "secret";
|
85
|
-
ProjectEnvType["Encrypted"] = "encrypted";
|
86
|
-
ProjectEnvType["System"] = "system";
|
87
|
-
})(ProjectEnvType = exports.ProjectEnvType || (exports.ProjectEnvType = {}));
|
88
|
-
//# sourceMappingURL=index.js.map
|
89
|
-
|
90
|
-
/***/ }),
|
91
|
-
|
92
83
|
/***/ 33105:
|
93
84
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
94
85
|
|
@@ -10347,7 +10338,7 @@ function setup(fetch) {
|
|
10347
10338
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
10348
10339
|
|
10349
10340
|
const retry = __webpack_require__(69420);
|
10350
|
-
const debug = __webpack_require__(
|
10341
|
+
const debug = __webpack_require__(94219)('fetch-retry');
|
10351
10342
|
|
10352
10343
|
// retry settings
|
10353
10344
|
const MIN_TIMEOUT = 10;
|
@@ -41203,656 +41194,6 @@ function init (debug) {
|
|
41203
41194
|
exports.enable(load());
|
41204
41195
|
|
41205
41196
|
|
41206
|
-
/***/ }),
|
41207
|
-
|
41208
|
-
/***/ 12308:
|
41209
|
-
/***/ ((module, exports, __webpack_require__) => {
|
41210
|
-
|
41211
|
-
"use strict";
|
41212
|
-
|
41213
|
-
|
41214
|
-
function _typeof(obj) { if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
41215
|
-
|
41216
|
-
/* eslint-env browser */
|
41217
|
-
|
41218
|
-
/**
|
41219
|
-
* This is the web browser implementation of `debug()`.
|
41220
|
-
*/
|
41221
|
-
exports.log = log;
|
41222
|
-
exports.formatArgs = formatArgs;
|
41223
|
-
exports.save = save;
|
41224
|
-
exports.load = load;
|
41225
|
-
exports.useColors = useColors;
|
41226
|
-
exports.storage = localstorage();
|
41227
|
-
/**
|
41228
|
-
* Colors.
|
41229
|
-
*/
|
41230
|
-
|
41231
|
-
exports.colors = ['#0000CC', '#0000FF', '#0033CC', '#0033FF', '#0066CC', '#0066FF', '#0099CC', '#0099FF', '#00CC00', '#00CC33', '#00CC66', '#00CC99', '#00CCCC', '#00CCFF', '#3300CC', '#3300FF', '#3333CC', '#3333FF', '#3366CC', '#3366FF', '#3399CC', '#3399FF', '#33CC00', '#33CC33', '#33CC66', '#33CC99', '#33CCCC', '#33CCFF', '#6600CC', '#6600FF', '#6633CC', '#6633FF', '#66CC00', '#66CC33', '#9900CC', '#9900FF', '#9933CC', '#9933FF', '#99CC00', '#99CC33', '#CC0000', '#CC0033', '#CC0066', '#CC0099', '#CC00CC', '#CC00FF', '#CC3300', '#CC3333', '#CC3366', '#CC3399', '#CC33CC', '#CC33FF', '#CC6600', '#CC6633', '#CC9900', '#CC9933', '#CCCC00', '#CCCC33', '#FF0000', '#FF0033', '#FF0066', '#FF0099', '#FF00CC', '#FF00FF', '#FF3300', '#FF3333', '#FF3366', '#FF3399', '#FF33CC', '#FF33FF', '#FF6600', '#FF6633', '#FF9900', '#FF9933', '#FFCC00', '#FFCC33'];
|
41232
|
-
/**
|
41233
|
-
* Currently only WebKit-based Web Inspectors, Firefox >= v31,
|
41234
|
-
* and the Firebug extension (any Firefox version) are known
|
41235
|
-
* to support "%c" CSS customizations.
|
41236
|
-
*
|
41237
|
-
* TODO: add a `localStorage` variable to explicitly enable/disable colors
|
41238
|
-
*/
|
41239
|
-
// eslint-disable-next-line complexity
|
41240
|
-
|
41241
|
-
function useColors() {
|
41242
|
-
// NB: In an Electron preload script, document will be defined but not fully
|
41243
|
-
// initialized. Since we know we're in Chrome, we'll just detect this case
|
41244
|
-
// explicitly
|
41245
|
-
if (typeof window !== 'undefined' && window.process && (window.process.type === 'renderer' || window.process.__nwjs)) {
|
41246
|
-
return true;
|
41247
|
-
} // Internet Explorer and Edge do not support colors.
|
41248
|
-
|
41249
|
-
|
41250
|
-
if (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)) {
|
41251
|
-
return false;
|
41252
|
-
} // Is webkit? http://stackoverflow.com/a/16459606/376773
|
41253
|
-
// document is undefined in react-native: https://github.com/facebook/react-native/pull/1632
|
41254
|
-
|
41255
|
-
|
41256
|
-
return typeof document !== 'undefined' && document.documentElement && document.documentElement.style && document.documentElement.style.WebkitAppearance || // Is firebug? http://stackoverflow.com/a/398120/376773
|
41257
|
-
typeof window !== 'undefined' && window.console && (window.console.firebug || window.console.exception && window.console.table) || // Is firefox >= v31?
|
41258
|
-
// https://developer.mozilla.org/en-US/docs/Tools/Web_Console#Styling_messages
|
41259
|
-
typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/) && parseInt(RegExp.$1, 10) >= 31 || // Double check webkit in userAgent just in case we are in a worker
|
41260
|
-
typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/);
|
41261
|
-
}
|
41262
|
-
/**
|
41263
|
-
* Colorize log arguments if enabled.
|
41264
|
-
*
|
41265
|
-
* @api public
|
41266
|
-
*/
|
41267
|
-
|
41268
|
-
|
41269
|
-
function formatArgs(args) {
|
41270
|
-
args[0] = (this.useColors ? '%c' : '') + this.namespace + (this.useColors ? ' %c' : ' ') + args[0] + (this.useColors ? '%c ' : ' ') + '+' + module.exports.humanize(this.diff);
|
41271
|
-
|
41272
|
-
if (!this.useColors) {
|
41273
|
-
return;
|
41274
|
-
}
|
41275
|
-
|
41276
|
-
var c = 'color: ' + this.color;
|
41277
|
-
args.splice(1, 0, c, 'color: inherit'); // The final "%c" is somewhat tricky, because there could be other
|
41278
|
-
// arguments passed either before or after the %c, so we need to
|
41279
|
-
// figure out the correct index to insert the CSS into
|
41280
|
-
|
41281
|
-
var index = 0;
|
41282
|
-
var lastC = 0;
|
41283
|
-
args[0].replace(/%[a-zA-Z%]/g, function (match) {
|
41284
|
-
if (match === '%%') {
|
41285
|
-
return;
|
41286
|
-
}
|
41287
|
-
|
41288
|
-
index++;
|
41289
|
-
|
41290
|
-
if (match === '%c') {
|
41291
|
-
// We only are interested in the *last* %c
|
41292
|
-
// (the user may have provided their own)
|
41293
|
-
lastC = index;
|
41294
|
-
}
|
41295
|
-
});
|
41296
|
-
args.splice(lastC, 0, c);
|
41297
|
-
}
|
41298
|
-
/**
|
41299
|
-
* Invokes `console.log()` when available.
|
41300
|
-
* No-op when `console.log` is not a "function".
|
41301
|
-
*
|
41302
|
-
* @api public
|
41303
|
-
*/
|
41304
|
-
|
41305
|
-
|
41306
|
-
function log() {
|
41307
|
-
var _console;
|
41308
|
-
|
41309
|
-
// This hackery is required for IE8/9, where
|
41310
|
-
// the `console.log` function doesn't have 'apply'
|
41311
|
-
return (typeof console === "undefined" ? "undefined" : _typeof(console)) === 'object' && console.log && (_console = console).log.apply(_console, arguments);
|
41312
|
-
}
|
41313
|
-
/**
|
41314
|
-
* Save `namespaces`.
|
41315
|
-
*
|
41316
|
-
* @param {String} namespaces
|
41317
|
-
* @api private
|
41318
|
-
*/
|
41319
|
-
|
41320
|
-
|
41321
|
-
function save(namespaces) {
|
41322
|
-
try {
|
41323
|
-
if (namespaces) {
|
41324
|
-
exports.storage.setItem('debug', namespaces);
|
41325
|
-
} else {
|
41326
|
-
exports.storage.removeItem('debug');
|
41327
|
-
}
|
41328
|
-
} catch (error) {// Swallow
|
41329
|
-
// XXX (@Qix-) should we be logging these?
|
41330
|
-
}
|
41331
|
-
}
|
41332
|
-
/**
|
41333
|
-
* Load `namespaces`.
|
41334
|
-
*
|
41335
|
-
* @return {String} returns the previously persisted debug modes
|
41336
|
-
* @api private
|
41337
|
-
*/
|
41338
|
-
|
41339
|
-
|
41340
|
-
function load() {
|
41341
|
-
var r;
|
41342
|
-
|
41343
|
-
try {
|
41344
|
-
r = exports.storage.getItem('debug');
|
41345
|
-
} catch (error) {} // Swallow
|
41346
|
-
// XXX (@Qix-) should we be logging these?
|
41347
|
-
// If debug isn't set in LS, and we're in Electron, try to load $DEBUG
|
41348
|
-
|
41349
|
-
|
41350
|
-
if (!r && typeof process !== 'undefined' && 'env' in process) {
|
41351
|
-
r = process.env.DEBUG;
|
41352
|
-
}
|
41353
|
-
|
41354
|
-
return r;
|
41355
|
-
}
|
41356
|
-
/**
|
41357
|
-
* Localstorage attempts to return the localstorage.
|
41358
|
-
*
|
41359
|
-
* This is necessary because safari throws
|
41360
|
-
* when a user disables cookies/localstorage
|
41361
|
-
* and you attempt to access it.
|
41362
|
-
*
|
41363
|
-
* @return {LocalStorage}
|
41364
|
-
* @api private
|
41365
|
-
*/
|
41366
|
-
|
41367
|
-
|
41368
|
-
function localstorage() {
|
41369
|
-
try {
|
41370
|
-
// TVMLKit (Apple TV JS Runtime) does not have a window object, just localStorage in the global context
|
41371
|
-
// The Browser also has localStorage in the global context.
|
41372
|
-
return localStorage;
|
41373
|
-
} catch (error) {// Swallow
|
41374
|
-
// XXX (@Qix-) should we be logging these?
|
41375
|
-
}
|
41376
|
-
}
|
41377
|
-
|
41378
|
-
module.exports = __webpack_require__(14878)(exports);
|
41379
|
-
var formatters = module.exports.formatters;
|
41380
|
-
/**
|
41381
|
-
* Map %j to `JSON.stringify()`, since no Web Inspectors do that by default.
|
41382
|
-
*/
|
41383
|
-
|
41384
|
-
formatters.j = function (v) {
|
41385
|
-
try {
|
41386
|
-
return JSON.stringify(v);
|
41387
|
-
} catch (error) {
|
41388
|
-
return '[UnexpectedJSONParseError]: ' + error.message;
|
41389
|
-
}
|
41390
|
-
};
|
41391
|
-
|
41392
|
-
|
41393
|
-
|
41394
|
-
/***/ }),
|
41395
|
-
|
41396
|
-
/***/ 14878:
|
41397
|
-
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
41398
|
-
|
41399
|
-
"use strict";
|
41400
|
-
|
41401
|
-
|
41402
|
-
/**
|
41403
|
-
* This is the common logic for both the Node.js and web browser
|
41404
|
-
* implementations of `debug()`.
|
41405
|
-
*/
|
41406
|
-
function setup(env) {
|
41407
|
-
createDebug.debug = createDebug;
|
41408
|
-
createDebug.default = createDebug;
|
41409
|
-
createDebug.coerce = coerce;
|
41410
|
-
createDebug.disable = disable;
|
41411
|
-
createDebug.enable = enable;
|
41412
|
-
createDebug.enabled = enabled;
|
41413
|
-
createDebug.humanize = __webpack_require__(82801);
|
41414
|
-
Object.keys(env).forEach(function (key) {
|
41415
|
-
createDebug[key] = env[key];
|
41416
|
-
});
|
41417
|
-
/**
|
41418
|
-
* Active `debug` instances.
|
41419
|
-
*/
|
41420
|
-
|
41421
|
-
createDebug.instances = [];
|
41422
|
-
/**
|
41423
|
-
* The currently active debug mode names, and names to skip.
|
41424
|
-
*/
|
41425
|
-
|
41426
|
-
createDebug.names = [];
|
41427
|
-
createDebug.skips = [];
|
41428
|
-
/**
|
41429
|
-
* Map of special "%n" handling functions, for the debug "format" argument.
|
41430
|
-
*
|
41431
|
-
* Valid key names are a single, lower or upper-case letter, i.e. "n" and "N".
|
41432
|
-
*/
|
41433
|
-
|
41434
|
-
createDebug.formatters = {};
|
41435
|
-
/**
|
41436
|
-
* Selects a color for a debug namespace
|
41437
|
-
* @param {String} namespace The namespace string for the for the debug instance to be colored
|
41438
|
-
* @return {Number|String} An ANSI color code for the given namespace
|
41439
|
-
* @api private
|
41440
|
-
*/
|
41441
|
-
|
41442
|
-
function selectColor(namespace) {
|
41443
|
-
var hash = 0;
|
41444
|
-
|
41445
|
-
for (var i = 0; i < namespace.length; i++) {
|
41446
|
-
hash = (hash << 5) - hash + namespace.charCodeAt(i);
|
41447
|
-
hash |= 0; // Convert to 32bit integer
|
41448
|
-
}
|
41449
|
-
|
41450
|
-
return createDebug.colors[Math.abs(hash) % createDebug.colors.length];
|
41451
|
-
}
|
41452
|
-
|
41453
|
-
createDebug.selectColor = selectColor;
|
41454
|
-
/**
|
41455
|
-
* Create a debugger with the given `namespace`.
|
41456
|
-
*
|
41457
|
-
* @param {String} namespace
|
41458
|
-
* @return {Function}
|
41459
|
-
* @api public
|
41460
|
-
*/
|
41461
|
-
|
41462
|
-
function createDebug(namespace) {
|
41463
|
-
var prevTime;
|
41464
|
-
|
41465
|
-
function debug() {
|
41466
|
-
// Disabled?
|
41467
|
-
if (!debug.enabled) {
|
41468
|
-
return;
|
41469
|
-
}
|
41470
|
-
|
41471
|
-
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
41472
|
-
args[_key] = arguments[_key];
|
41473
|
-
}
|
41474
|
-
|
41475
|
-
var self = debug; // Set `diff` timestamp
|
41476
|
-
|
41477
|
-
var curr = Number(new Date());
|
41478
|
-
var ms = curr - (prevTime || curr);
|
41479
|
-
self.diff = ms;
|
41480
|
-
self.prev = prevTime;
|
41481
|
-
self.curr = curr;
|
41482
|
-
prevTime = curr;
|
41483
|
-
args[0] = createDebug.coerce(args[0]);
|
41484
|
-
|
41485
|
-
if (typeof args[0] !== 'string') {
|
41486
|
-
// Anything else let's inspect with %O
|
41487
|
-
args.unshift('%O');
|
41488
|
-
} // Apply any `formatters` transformations
|
41489
|
-
|
41490
|
-
|
41491
|
-
var index = 0;
|
41492
|
-
args[0] = args[0].replace(/%([a-zA-Z%])/g, function (match, format) {
|
41493
|
-
// If we encounter an escaped % then don't increase the array index
|
41494
|
-
if (match === '%%') {
|
41495
|
-
return match;
|
41496
|
-
}
|
41497
|
-
|
41498
|
-
index++;
|
41499
|
-
var formatter = createDebug.formatters[format];
|
41500
|
-
|
41501
|
-
if (typeof formatter === 'function') {
|
41502
|
-
var val = args[index];
|
41503
|
-
match = formatter.call(self, val); // Now we need to remove `args[index]` since it's inlined in the `format`
|
41504
|
-
|
41505
|
-
args.splice(index, 1);
|
41506
|
-
index--;
|
41507
|
-
}
|
41508
|
-
|
41509
|
-
return match;
|
41510
|
-
}); // Apply env-specific formatting (colors, etc.)
|
41511
|
-
|
41512
|
-
createDebug.formatArgs.call(self, args);
|
41513
|
-
var logFn = self.log || createDebug.log;
|
41514
|
-
logFn.apply(self, args);
|
41515
|
-
}
|
41516
|
-
|
41517
|
-
debug.namespace = namespace;
|
41518
|
-
debug.enabled = createDebug.enabled(namespace);
|
41519
|
-
debug.useColors = createDebug.useColors();
|
41520
|
-
debug.color = selectColor(namespace);
|
41521
|
-
debug.destroy = destroy;
|
41522
|
-
debug.extend = extend; // Debug.formatArgs = formatArgs;
|
41523
|
-
// debug.rawLog = rawLog;
|
41524
|
-
// env-specific initialization logic for debug instances
|
41525
|
-
|
41526
|
-
if (typeof createDebug.init === 'function') {
|
41527
|
-
createDebug.init(debug);
|
41528
|
-
}
|
41529
|
-
|
41530
|
-
createDebug.instances.push(debug);
|
41531
|
-
return debug;
|
41532
|
-
}
|
41533
|
-
|
41534
|
-
function destroy() {
|
41535
|
-
var index = createDebug.instances.indexOf(this);
|
41536
|
-
|
41537
|
-
if (index !== -1) {
|
41538
|
-
createDebug.instances.splice(index, 1);
|
41539
|
-
return true;
|
41540
|
-
}
|
41541
|
-
|
41542
|
-
return false;
|
41543
|
-
}
|
41544
|
-
|
41545
|
-
function extend(namespace, delimiter) {
|
41546
|
-
return createDebug(this.namespace + (typeof delimiter === 'undefined' ? ':' : delimiter) + namespace);
|
41547
|
-
}
|
41548
|
-
/**
|
41549
|
-
* Enables a debug mode by namespaces. This can include modes
|
41550
|
-
* separated by a colon and wildcards.
|
41551
|
-
*
|
41552
|
-
* @param {String} namespaces
|
41553
|
-
* @api public
|
41554
|
-
*/
|
41555
|
-
|
41556
|
-
|
41557
|
-
function enable(namespaces) {
|
41558
|
-
createDebug.save(namespaces);
|
41559
|
-
createDebug.names = [];
|
41560
|
-
createDebug.skips = [];
|
41561
|
-
var i;
|
41562
|
-
var split = (typeof namespaces === 'string' ? namespaces : '').split(/[\s,]+/);
|
41563
|
-
var len = split.length;
|
41564
|
-
|
41565
|
-
for (i = 0; i < len; i++) {
|
41566
|
-
if (!split[i]) {
|
41567
|
-
// ignore empty strings
|
41568
|
-
continue;
|
41569
|
-
}
|
41570
|
-
|
41571
|
-
namespaces = split[i].replace(/\*/g, '.*?');
|
41572
|
-
|
41573
|
-
if (namespaces[0] === '-') {
|
41574
|
-
createDebug.skips.push(new RegExp('^' + namespaces.substr(1) + '$'));
|
41575
|
-
} else {
|
41576
|
-
createDebug.names.push(new RegExp('^' + namespaces + '$'));
|
41577
|
-
}
|
41578
|
-
}
|
41579
|
-
|
41580
|
-
for (i = 0; i < createDebug.instances.length; i++) {
|
41581
|
-
var instance = createDebug.instances[i];
|
41582
|
-
instance.enabled = createDebug.enabled(instance.namespace);
|
41583
|
-
}
|
41584
|
-
}
|
41585
|
-
/**
|
41586
|
-
* Disable debug output.
|
41587
|
-
*
|
41588
|
-
* @api public
|
41589
|
-
*/
|
41590
|
-
|
41591
|
-
|
41592
|
-
function disable() {
|
41593
|
-
createDebug.enable('');
|
41594
|
-
}
|
41595
|
-
/**
|
41596
|
-
* Returns true if the given mode name is enabled, false otherwise.
|
41597
|
-
*
|
41598
|
-
* @param {String} name
|
41599
|
-
* @return {Boolean}
|
41600
|
-
* @api public
|
41601
|
-
*/
|
41602
|
-
|
41603
|
-
|
41604
|
-
function enabled(name) {
|
41605
|
-
if (name[name.length - 1] === '*') {
|
41606
|
-
return true;
|
41607
|
-
}
|
41608
|
-
|
41609
|
-
var i;
|
41610
|
-
var len;
|
41611
|
-
|
41612
|
-
for (i = 0, len = createDebug.skips.length; i < len; i++) {
|
41613
|
-
if (createDebug.skips[i].test(name)) {
|
41614
|
-
return false;
|
41615
|
-
}
|
41616
|
-
}
|
41617
|
-
|
41618
|
-
for (i = 0, len = createDebug.names.length; i < len; i++) {
|
41619
|
-
if (createDebug.names[i].test(name)) {
|
41620
|
-
return true;
|
41621
|
-
}
|
41622
|
-
}
|
41623
|
-
|
41624
|
-
return false;
|
41625
|
-
}
|
41626
|
-
/**
|
41627
|
-
* Coerce `val`.
|
41628
|
-
*
|
41629
|
-
* @param {Mixed} val
|
41630
|
-
* @return {Mixed}
|
41631
|
-
* @api private
|
41632
|
-
*/
|
41633
|
-
|
41634
|
-
|
41635
|
-
function coerce(val) {
|
41636
|
-
if (val instanceof Error) {
|
41637
|
-
return val.stack || val.message;
|
41638
|
-
}
|
41639
|
-
|
41640
|
-
return val;
|
41641
|
-
}
|
41642
|
-
|
41643
|
-
createDebug.enable(createDebug.load());
|
41644
|
-
return createDebug;
|
41645
|
-
}
|
41646
|
-
|
41647
|
-
module.exports = setup;
|
41648
|
-
|
41649
|
-
|
41650
|
-
|
41651
|
-
/***/ }),
|
41652
|
-
|
41653
|
-
/***/ 49064:
|
41654
|
-
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
41655
|
-
|
41656
|
-
"use strict";
|
41657
|
-
|
41658
|
-
|
41659
|
-
/**
|
41660
|
-
* Detect Electron renderer / nwjs process, which is node, but we should
|
41661
|
-
* treat as a browser.
|
41662
|
-
*/
|
41663
|
-
if (typeof process === 'undefined' || process.type === 'renderer' || process.browser === true || process.__nwjs) {
|
41664
|
-
module.exports = __webpack_require__(12308);
|
41665
|
-
} else {
|
41666
|
-
module.exports = __webpack_require__(39227);
|
41667
|
-
}
|
41668
|
-
|
41669
|
-
|
41670
|
-
|
41671
|
-
/***/ }),
|
41672
|
-
|
41673
|
-
/***/ 39227:
|
41674
|
-
/***/ ((module, exports, __webpack_require__) => {
|
41675
|
-
|
41676
|
-
"use strict";
|
41677
|
-
|
41678
|
-
|
41679
|
-
/**
|
41680
|
-
* Module dependencies.
|
41681
|
-
*/
|
41682
|
-
var tty = __webpack_require__(33867);
|
41683
|
-
|
41684
|
-
var util = __webpack_require__(31669);
|
41685
|
-
/**
|
41686
|
-
* This is the Node.js implementation of `debug()`.
|
41687
|
-
*/
|
41688
|
-
|
41689
|
-
|
41690
|
-
exports.init = init;
|
41691
|
-
exports.log = log;
|
41692
|
-
exports.formatArgs = formatArgs;
|
41693
|
-
exports.save = save;
|
41694
|
-
exports.load = load;
|
41695
|
-
exports.useColors = useColors;
|
41696
|
-
/**
|
41697
|
-
* Colors.
|
41698
|
-
*/
|
41699
|
-
|
41700
|
-
exports.colors = [6, 2, 3, 4, 5, 1];
|
41701
|
-
|
41702
|
-
try {
|
41703
|
-
// Optional dependency (as in, doesn't need to be installed, NOT like optionalDependencies in package.json)
|
41704
|
-
// eslint-disable-next-line import/no-extraneous-dependencies
|
41705
|
-
var supportsColor = __webpack_require__(96328);
|
41706
|
-
|
41707
|
-
if (supportsColor && (supportsColor.stderr || supportsColor).level >= 2) {
|
41708
|
-
exports.colors = [20, 21, 26, 27, 32, 33, 38, 39, 40, 41, 42, 43, 44, 45, 56, 57, 62, 63, 68, 69, 74, 75, 76, 77, 78, 79, 80, 81, 92, 93, 98, 99, 112, 113, 128, 129, 134, 135, 148, 149, 160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, 178, 179, 184, 185, 196, 197, 198, 199, 200, 201, 202, 203, 204, 205, 206, 207, 208, 209, 214, 215, 220, 221];
|
41709
|
-
}
|
41710
|
-
} catch (error) {} // Swallow - we only care if `supports-color` is available; it doesn't have to be.
|
41711
|
-
|
41712
|
-
/**
|
41713
|
-
* Build up the default `inspectOpts` object from the environment variables.
|
41714
|
-
*
|
41715
|
-
* $ DEBUG_COLORS=no DEBUG_DEPTH=10 DEBUG_SHOW_HIDDEN=enabled node script.js
|
41716
|
-
*/
|
41717
|
-
|
41718
|
-
|
41719
|
-
exports.inspectOpts = Object.keys(process.env).filter(function (key) {
|
41720
|
-
return /^debug_/i.test(key);
|
41721
|
-
}).reduce(function (obj, key) {
|
41722
|
-
// Camel-case
|
41723
|
-
var prop = key.substring(6).toLowerCase().replace(/_([a-z])/g, function (_, k) {
|
41724
|
-
return k.toUpperCase();
|
41725
|
-
}); // Coerce string value into JS value
|
41726
|
-
|
41727
|
-
var val = process.env[key];
|
41728
|
-
|
41729
|
-
if (/^(yes|on|true|enabled)$/i.test(val)) {
|
41730
|
-
val = true;
|
41731
|
-
} else if (/^(no|off|false|disabled)$/i.test(val)) {
|
41732
|
-
val = false;
|
41733
|
-
} else if (val === 'null') {
|
41734
|
-
val = null;
|
41735
|
-
} else {
|
41736
|
-
val = Number(val);
|
41737
|
-
}
|
41738
|
-
|
41739
|
-
obj[prop] = val;
|
41740
|
-
return obj;
|
41741
|
-
}, {});
|
41742
|
-
/**
|
41743
|
-
* Is stdout a TTY? Colored output is enabled when `true`.
|
41744
|
-
*/
|
41745
|
-
|
41746
|
-
function useColors() {
|
41747
|
-
return 'colors' in exports.inspectOpts ? Boolean(exports.inspectOpts.colors) : tty.isatty(process.stderr.fd);
|
41748
|
-
}
|
41749
|
-
/**
|
41750
|
-
* Adds ANSI color escape codes if enabled.
|
41751
|
-
*
|
41752
|
-
* @api public
|
41753
|
-
*/
|
41754
|
-
|
41755
|
-
|
41756
|
-
function formatArgs(args) {
|
41757
|
-
var name = this.namespace,
|
41758
|
-
useColors = this.useColors;
|
41759
|
-
|
41760
|
-
if (useColors) {
|
41761
|
-
var c = this.color;
|
41762
|
-
var colorCode = "\x1B[3" + (c < 8 ? c : '8;5;' + c);
|
41763
|
-
var prefix = " ".concat(colorCode, ";1m").concat(name, " \x1B[0m");
|
41764
|
-
args[0] = prefix + args[0].split('\n').join('\n' + prefix);
|
41765
|
-
args.push(colorCode + 'm+' + module.exports.humanize(this.diff) + "\x1B[0m");
|
41766
|
-
} else {
|
41767
|
-
args[0] = getDate() + name + ' ' + args[0];
|
41768
|
-
}
|
41769
|
-
}
|
41770
|
-
|
41771
|
-
function getDate() {
|
41772
|
-
if (exports.inspectOpts.hideDate) {
|
41773
|
-
return '';
|
41774
|
-
}
|
41775
|
-
|
41776
|
-
return new Date().toISOString() + ' ';
|
41777
|
-
}
|
41778
|
-
/**
|
41779
|
-
* Invokes `util.format()` with the specified arguments and writes to stderr.
|
41780
|
-
*/
|
41781
|
-
|
41782
|
-
|
41783
|
-
function log() {
|
41784
|
-
return process.stderr.write(util.format.apply(util, arguments) + '\n');
|
41785
|
-
}
|
41786
|
-
/**
|
41787
|
-
* Save `namespaces`.
|
41788
|
-
*
|
41789
|
-
* @param {String} namespaces
|
41790
|
-
* @api private
|
41791
|
-
*/
|
41792
|
-
|
41793
|
-
|
41794
|
-
function save(namespaces) {
|
41795
|
-
if (namespaces) {
|
41796
|
-
process.env.DEBUG = namespaces;
|
41797
|
-
} else {
|
41798
|
-
// If you set a process.env field to null or undefined, it gets cast to the
|
41799
|
-
// string 'null' or 'undefined'. Just delete instead.
|
41800
|
-
delete process.env.DEBUG;
|
41801
|
-
}
|
41802
|
-
}
|
41803
|
-
/**
|
41804
|
-
* Load `namespaces`.
|
41805
|
-
*
|
41806
|
-
* @return {String} returns the previously persisted debug modes
|
41807
|
-
* @api private
|
41808
|
-
*/
|
41809
|
-
|
41810
|
-
|
41811
|
-
function load() {
|
41812
|
-
return process.env.DEBUG;
|
41813
|
-
}
|
41814
|
-
/**
|
41815
|
-
* Init logic for `debug` instances.
|
41816
|
-
*
|
41817
|
-
* Create a new `inspectOpts` object in case `useColors` is set
|
41818
|
-
* differently for a particular `debug` instance.
|
41819
|
-
*/
|
41820
|
-
|
41821
|
-
|
41822
|
-
function init(debug) {
|
41823
|
-
debug.inspectOpts = {};
|
41824
|
-
var keys = Object.keys(exports.inspectOpts);
|
41825
|
-
|
41826
|
-
for (var i = 0; i < keys.length; i++) {
|
41827
|
-
debug.inspectOpts[keys[i]] = exports.inspectOpts[keys[i]];
|
41828
|
-
}
|
41829
|
-
}
|
41830
|
-
|
41831
|
-
module.exports = __webpack_require__(14878)(exports);
|
41832
|
-
var formatters = module.exports.formatters;
|
41833
|
-
/**
|
41834
|
-
* Map %o to `util.inspect()`, all on a single line.
|
41835
|
-
*/
|
41836
|
-
|
41837
|
-
formatters.o = function (v) {
|
41838
|
-
this.inspectOpts.colors = this.useColors;
|
41839
|
-
return util.inspect(v, this.inspectOpts)
|
41840
|
-
.split('\n')
|
41841
|
-
.map(function (str) { return str.trim(); })
|
41842
|
-
.join(' ');
|
41843
|
-
};
|
41844
|
-
/**
|
41845
|
-
* Map %O to `util.inspect()`, allowing multiple lines if needed.
|
41846
|
-
*/
|
41847
|
-
|
41848
|
-
|
41849
|
-
formatters.O = function (v) {
|
41850
|
-
this.inspectOpts.colors = this.useColors;
|
41851
|
-
return util.inspect(v, this.inspectOpts);
|
41852
|
-
};
|
41853
|
-
|
41854
|
-
|
41855
|
-
|
41856
41197
|
/***/ }),
|
41857
41198
|
|
41858
41199
|
/***/ 80279:
|
@@ -42142,7 +41483,7 @@ function setup(env) {
|
|
42142
41483
|
createDebug.disable = disable;
|
42143
41484
|
createDebug.enable = enable;
|
42144
41485
|
createDebug.enabled = enabled;
|
42145
|
-
createDebug.humanize = __webpack_require__(
|
41486
|
+
createDebug.humanize = __webpack_require__(21378);
|
42146
41487
|
|
42147
41488
|
Object.keys(env).forEach(key => {
|
42148
41489
|
createDebug[key] = env[key];
|
@@ -63590,6 +62931,979 @@ function patch (fs) {
|
|
63590
62931
|
}
|
63591
62932
|
|
63592
62933
|
|
62934
|
+
/***/ }),
|
62935
|
+
|
62936
|
+
/***/ 23016:
|
62937
|
+
/***/ ((module) => {
|
62938
|
+
|
62939
|
+
"use strict";
|
62940
|
+
|
62941
|
+
|
62942
|
+
module.exports = clone
|
62943
|
+
|
62944
|
+
var getPrototypeOf = Object.getPrototypeOf || function (obj) {
|
62945
|
+
return obj.__proto__
|
62946
|
+
}
|
62947
|
+
|
62948
|
+
function clone (obj) {
|
62949
|
+
if (obj === null || typeof obj !== 'object')
|
62950
|
+
return obj
|
62951
|
+
|
62952
|
+
if (obj instanceof Object)
|
62953
|
+
var copy = { __proto__: getPrototypeOf(obj) }
|
62954
|
+
else
|
62955
|
+
var copy = Object.create(null)
|
62956
|
+
|
62957
|
+
Object.getOwnPropertyNames(obj).forEach(function (key) {
|
62958
|
+
Object.defineProperty(copy, key, Object.getOwnPropertyDescriptor(obj, key))
|
62959
|
+
})
|
62960
|
+
|
62961
|
+
return copy
|
62962
|
+
}
|
62963
|
+
|
62964
|
+
|
62965
|
+
/***/ }),
|
62966
|
+
|
62967
|
+
/***/ 57156:
|
62968
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
62969
|
+
|
62970
|
+
var fs = __webpack_require__(35747)
|
62971
|
+
var polyfills = __webpack_require__(54692)
|
62972
|
+
var legacy = __webpack_require__(36465)
|
62973
|
+
var clone = __webpack_require__(23016)
|
62974
|
+
|
62975
|
+
var util = __webpack_require__(31669)
|
62976
|
+
|
62977
|
+
/* istanbul ignore next - node 0.x polyfill */
|
62978
|
+
var gracefulQueue
|
62979
|
+
var previousSymbol
|
62980
|
+
|
62981
|
+
/* istanbul ignore else - node 0.x polyfill */
|
62982
|
+
if (typeof Symbol === 'function' && typeof Symbol.for === 'function') {
|
62983
|
+
gracefulQueue = Symbol.for('graceful-fs.queue')
|
62984
|
+
// This is used in testing by future versions
|
62985
|
+
previousSymbol = Symbol.for('graceful-fs.previous')
|
62986
|
+
} else {
|
62987
|
+
gracefulQueue = '___graceful-fs.queue'
|
62988
|
+
previousSymbol = '___graceful-fs.previous'
|
62989
|
+
}
|
62990
|
+
|
62991
|
+
function noop () {}
|
62992
|
+
|
62993
|
+
function publishQueue(context, queue) {
|
62994
|
+
Object.defineProperty(context, gracefulQueue, {
|
62995
|
+
get: function() {
|
62996
|
+
return queue
|
62997
|
+
}
|
62998
|
+
})
|
62999
|
+
}
|
63000
|
+
|
63001
|
+
var debug = noop
|
63002
|
+
if (util.debuglog)
|
63003
|
+
debug = util.debuglog('gfs4')
|
63004
|
+
else if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || ''))
|
63005
|
+
debug = function() {
|
63006
|
+
var m = util.format.apply(util, arguments)
|
63007
|
+
m = 'GFS4: ' + m.split(/\n/).join('\nGFS4: ')
|
63008
|
+
console.error(m)
|
63009
|
+
}
|
63010
|
+
|
63011
|
+
// Once time initialization
|
63012
|
+
if (!fs[gracefulQueue]) {
|
63013
|
+
// This queue can be shared by multiple loaded instances
|
63014
|
+
var queue = global[gracefulQueue] || []
|
63015
|
+
publishQueue(fs, queue)
|
63016
|
+
|
63017
|
+
// Patch fs.close/closeSync to shared queue version, because we need
|
63018
|
+
// to retry() whenever a close happens *anywhere* in the program.
|
63019
|
+
// This is essential when multiple graceful-fs instances are
|
63020
|
+
// in play at the same time.
|
63021
|
+
fs.close = (function (fs$close) {
|
63022
|
+
function close (fd, cb) {
|
63023
|
+
return fs$close.call(fs, fd, function (err) {
|
63024
|
+
// This function uses the graceful-fs shared queue
|
63025
|
+
if (!err) {
|
63026
|
+
resetQueue()
|
63027
|
+
}
|
63028
|
+
|
63029
|
+
if (typeof cb === 'function')
|
63030
|
+
cb.apply(this, arguments)
|
63031
|
+
})
|
63032
|
+
}
|
63033
|
+
|
63034
|
+
Object.defineProperty(close, previousSymbol, {
|
63035
|
+
value: fs$close
|
63036
|
+
})
|
63037
|
+
return close
|
63038
|
+
})(fs.close)
|
63039
|
+
|
63040
|
+
fs.closeSync = (function (fs$closeSync) {
|
63041
|
+
function closeSync (fd) {
|
63042
|
+
// This function uses the graceful-fs shared queue
|
63043
|
+
fs$closeSync.apply(fs, arguments)
|
63044
|
+
resetQueue()
|
63045
|
+
}
|
63046
|
+
|
63047
|
+
Object.defineProperty(closeSync, previousSymbol, {
|
63048
|
+
value: fs$closeSync
|
63049
|
+
})
|
63050
|
+
return closeSync
|
63051
|
+
})(fs.closeSync)
|
63052
|
+
|
63053
|
+
if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || '')) {
|
63054
|
+
process.on('exit', function() {
|
63055
|
+
debug(fs[gracefulQueue])
|
63056
|
+
__webpack_require__(42357).equal(fs[gracefulQueue].length, 0)
|
63057
|
+
})
|
63058
|
+
}
|
63059
|
+
}
|
63060
|
+
|
63061
|
+
if (!global[gracefulQueue]) {
|
63062
|
+
publishQueue(global, fs[gracefulQueue]);
|
63063
|
+
}
|
63064
|
+
|
63065
|
+
module.exports = patch(clone(fs))
|
63066
|
+
if (process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH && !fs.__patched) {
|
63067
|
+
module.exports = patch(fs)
|
63068
|
+
fs.__patched = true;
|
63069
|
+
}
|
63070
|
+
|
63071
|
+
function patch (fs) {
|
63072
|
+
// Everything that references the open() function needs to be in here
|
63073
|
+
polyfills(fs)
|
63074
|
+
fs.gracefulify = patch
|
63075
|
+
|
63076
|
+
fs.createReadStream = createReadStream
|
63077
|
+
fs.createWriteStream = createWriteStream
|
63078
|
+
var fs$readFile = fs.readFile
|
63079
|
+
fs.readFile = readFile
|
63080
|
+
function readFile (path, options, cb) {
|
63081
|
+
if (typeof options === 'function')
|
63082
|
+
cb = options, options = null
|
63083
|
+
|
63084
|
+
return go$readFile(path, options, cb)
|
63085
|
+
|
63086
|
+
function go$readFile (path, options, cb, startTime) {
|
63087
|
+
return fs$readFile(path, options, function (err) {
|
63088
|
+
if (err && (err.code === 'EMFILE' || err.code === 'ENFILE'))
|
63089
|
+
enqueue([go$readFile, [path, options, cb], err, startTime || Date.now(), Date.now()])
|
63090
|
+
else {
|
63091
|
+
if (typeof cb === 'function')
|
63092
|
+
cb.apply(this, arguments)
|
63093
|
+
}
|
63094
|
+
})
|
63095
|
+
}
|
63096
|
+
}
|
63097
|
+
|
63098
|
+
var fs$writeFile = fs.writeFile
|
63099
|
+
fs.writeFile = writeFile
|
63100
|
+
function writeFile (path, data, options, cb) {
|
63101
|
+
if (typeof options === 'function')
|
63102
|
+
cb = options, options = null
|
63103
|
+
|
63104
|
+
return go$writeFile(path, data, options, cb)
|
63105
|
+
|
63106
|
+
function go$writeFile (path, data, options, cb, startTime) {
|
63107
|
+
return fs$writeFile(path, data, options, function (err) {
|
63108
|
+
if (err && (err.code === 'EMFILE' || err.code === 'ENFILE'))
|
63109
|
+
enqueue([go$writeFile, [path, data, options, cb], err, startTime || Date.now(), Date.now()])
|
63110
|
+
else {
|
63111
|
+
if (typeof cb === 'function')
|
63112
|
+
cb.apply(this, arguments)
|
63113
|
+
}
|
63114
|
+
})
|
63115
|
+
}
|
63116
|
+
}
|
63117
|
+
|
63118
|
+
var fs$appendFile = fs.appendFile
|
63119
|
+
if (fs$appendFile)
|
63120
|
+
fs.appendFile = appendFile
|
63121
|
+
function appendFile (path, data, options, cb) {
|
63122
|
+
if (typeof options === 'function')
|
63123
|
+
cb = options, options = null
|
63124
|
+
|
63125
|
+
return go$appendFile(path, data, options, cb)
|
63126
|
+
|
63127
|
+
function go$appendFile (path, data, options, cb, startTime) {
|
63128
|
+
return fs$appendFile(path, data, options, function (err) {
|
63129
|
+
if (err && (err.code === 'EMFILE' || err.code === 'ENFILE'))
|
63130
|
+
enqueue([go$appendFile, [path, data, options, cb], err, startTime || Date.now(), Date.now()])
|
63131
|
+
else {
|
63132
|
+
if (typeof cb === 'function')
|
63133
|
+
cb.apply(this, arguments)
|
63134
|
+
}
|
63135
|
+
})
|
63136
|
+
}
|
63137
|
+
}
|
63138
|
+
|
63139
|
+
var fs$copyFile = fs.copyFile
|
63140
|
+
if (fs$copyFile)
|
63141
|
+
fs.copyFile = copyFile
|
63142
|
+
function copyFile (src, dest, flags, cb) {
|
63143
|
+
if (typeof flags === 'function') {
|
63144
|
+
cb = flags
|
63145
|
+
flags = 0
|
63146
|
+
}
|
63147
|
+
return go$copyFile(src, dest, flags, cb)
|
63148
|
+
|
63149
|
+
function go$copyFile (src, dest, flags, cb, startTime) {
|
63150
|
+
return fs$copyFile(src, dest, flags, function (err) {
|
63151
|
+
if (err && (err.code === 'EMFILE' || err.code === 'ENFILE'))
|
63152
|
+
enqueue([go$copyFile, [src, dest, flags, cb], err, startTime || Date.now(), Date.now()])
|
63153
|
+
else {
|
63154
|
+
if (typeof cb === 'function')
|
63155
|
+
cb.apply(this, arguments)
|
63156
|
+
}
|
63157
|
+
})
|
63158
|
+
}
|
63159
|
+
}
|
63160
|
+
|
63161
|
+
var fs$readdir = fs.readdir
|
63162
|
+
fs.readdir = readdir
|
63163
|
+
var noReaddirOptionVersions = /^v[0-5]\./
|
63164
|
+
function readdir (path, options, cb) {
|
63165
|
+
if (typeof options === 'function')
|
63166
|
+
cb = options, options = null
|
63167
|
+
|
63168
|
+
var go$readdir = noReaddirOptionVersions.test(process.version)
|
63169
|
+
? function go$readdir (path, options, cb, startTime) {
|
63170
|
+
return fs$readdir(path, fs$readdirCallback(
|
63171
|
+
path, options, cb, startTime
|
63172
|
+
))
|
63173
|
+
}
|
63174
|
+
: function go$readdir (path, options, cb, startTime) {
|
63175
|
+
return fs$readdir(path, options, fs$readdirCallback(
|
63176
|
+
path, options, cb, startTime
|
63177
|
+
))
|
63178
|
+
}
|
63179
|
+
|
63180
|
+
return go$readdir(path, options, cb)
|
63181
|
+
|
63182
|
+
function fs$readdirCallback (path, options, cb, startTime) {
|
63183
|
+
return function (err, files) {
|
63184
|
+
if (err && (err.code === 'EMFILE' || err.code === 'ENFILE'))
|
63185
|
+
enqueue([
|
63186
|
+
go$readdir,
|
63187
|
+
[path, options, cb],
|
63188
|
+
err,
|
63189
|
+
startTime || Date.now(),
|
63190
|
+
Date.now()
|
63191
|
+
])
|
63192
|
+
else {
|
63193
|
+
if (files && files.sort)
|
63194
|
+
files.sort()
|
63195
|
+
|
63196
|
+
if (typeof cb === 'function')
|
63197
|
+
cb.call(this, err, files)
|
63198
|
+
}
|
63199
|
+
}
|
63200
|
+
}
|
63201
|
+
}
|
63202
|
+
|
63203
|
+
if (process.version.substr(0, 4) === 'v0.8') {
|
63204
|
+
var legStreams = legacy(fs)
|
63205
|
+
ReadStream = legStreams.ReadStream
|
63206
|
+
WriteStream = legStreams.WriteStream
|
63207
|
+
}
|
63208
|
+
|
63209
|
+
var fs$ReadStream = fs.ReadStream
|
63210
|
+
if (fs$ReadStream) {
|
63211
|
+
ReadStream.prototype = Object.create(fs$ReadStream.prototype)
|
63212
|
+
ReadStream.prototype.open = ReadStream$open
|
63213
|
+
}
|
63214
|
+
|
63215
|
+
var fs$WriteStream = fs.WriteStream
|
63216
|
+
if (fs$WriteStream) {
|
63217
|
+
WriteStream.prototype = Object.create(fs$WriteStream.prototype)
|
63218
|
+
WriteStream.prototype.open = WriteStream$open
|
63219
|
+
}
|
63220
|
+
|
63221
|
+
Object.defineProperty(fs, 'ReadStream', {
|
63222
|
+
get: function () {
|
63223
|
+
return ReadStream
|
63224
|
+
},
|
63225
|
+
set: function (val) {
|
63226
|
+
ReadStream = val
|
63227
|
+
},
|
63228
|
+
enumerable: true,
|
63229
|
+
configurable: true
|
63230
|
+
})
|
63231
|
+
Object.defineProperty(fs, 'WriteStream', {
|
63232
|
+
get: function () {
|
63233
|
+
return WriteStream
|
63234
|
+
},
|
63235
|
+
set: function (val) {
|
63236
|
+
WriteStream = val
|
63237
|
+
},
|
63238
|
+
enumerable: true,
|
63239
|
+
configurable: true
|
63240
|
+
})
|
63241
|
+
|
63242
|
+
// legacy names
|
63243
|
+
var FileReadStream = ReadStream
|
63244
|
+
Object.defineProperty(fs, 'FileReadStream', {
|
63245
|
+
get: function () {
|
63246
|
+
return FileReadStream
|
63247
|
+
},
|
63248
|
+
set: function (val) {
|
63249
|
+
FileReadStream = val
|
63250
|
+
},
|
63251
|
+
enumerable: true,
|
63252
|
+
configurable: true
|
63253
|
+
})
|
63254
|
+
var FileWriteStream = WriteStream
|
63255
|
+
Object.defineProperty(fs, 'FileWriteStream', {
|
63256
|
+
get: function () {
|
63257
|
+
return FileWriteStream
|
63258
|
+
},
|
63259
|
+
set: function (val) {
|
63260
|
+
FileWriteStream = val
|
63261
|
+
},
|
63262
|
+
enumerable: true,
|
63263
|
+
configurable: true
|
63264
|
+
})
|
63265
|
+
|
63266
|
+
function ReadStream (path, options) {
|
63267
|
+
if (this instanceof ReadStream)
|
63268
|
+
return fs$ReadStream.apply(this, arguments), this
|
63269
|
+
else
|
63270
|
+
return ReadStream.apply(Object.create(ReadStream.prototype), arguments)
|
63271
|
+
}
|
63272
|
+
|
63273
|
+
function ReadStream$open () {
|
63274
|
+
var that = this
|
63275
|
+
open(that.path, that.flags, that.mode, function (err, fd) {
|
63276
|
+
if (err) {
|
63277
|
+
if (that.autoClose)
|
63278
|
+
that.destroy()
|
63279
|
+
|
63280
|
+
that.emit('error', err)
|
63281
|
+
} else {
|
63282
|
+
that.fd = fd
|
63283
|
+
that.emit('open', fd)
|
63284
|
+
that.read()
|
63285
|
+
}
|
63286
|
+
})
|
63287
|
+
}
|
63288
|
+
|
63289
|
+
function WriteStream (path, options) {
|
63290
|
+
if (this instanceof WriteStream)
|
63291
|
+
return fs$WriteStream.apply(this, arguments), this
|
63292
|
+
else
|
63293
|
+
return WriteStream.apply(Object.create(WriteStream.prototype), arguments)
|
63294
|
+
}
|
63295
|
+
|
63296
|
+
function WriteStream$open () {
|
63297
|
+
var that = this
|
63298
|
+
open(that.path, that.flags, that.mode, function (err, fd) {
|
63299
|
+
if (err) {
|
63300
|
+
that.destroy()
|
63301
|
+
that.emit('error', err)
|
63302
|
+
} else {
|
63303
|
+
that.fd = fd
|
63304
|
+
that.emit('open', fd)
|
63305
|
+
}
|
63306
|
+
})
|
63307
|
+
}
|
63308
|
+
|
63309
|
+
function createReadStream (path, options) {
|
63310
|
+
return new fs.ReadStream(path, options)
|
63311
|
+
}
|
63312
|
+
|
63313
|
+
function createWriteStream (path, options) {
|
63314
|
+
return new fs.WriteStream(path, options)
|
63315
|
+
}
|
63316
|
+
|
63317
|
+
var fs$open = fs.open
|
63318
|
+
fs.open = open
|
63319
|
+
function open (path, flags, mode, cb) {
|
63320
|
+
if (typeof mode === 'function')
|
63321
|
+
cb = mode, mode = null
|
63322
|
+
|
63323
|
+
return go$open(path, flags, mode, cb)
|
63324
|
+
|
63325
|
+
function go$open (path, flags, mode, cb, startTime) {
|
63326
|
+
return fs$open(path, flags, mode, function (err, fd) {
|
63327
|
+
if (err && (err.code === 'EMFILE' || err.code === 'ENFILE'))
|
63328
|
+
enqueue([go$open, [path, flags, mode, cb], err, startTime || Date.now(), Date.now()])
|
63329
|
+
else {
|
63330
|
+
if (typeof cb === 'function')
|
63331
|
+
cb.apply(this, arguments)
|
63332
|
+
}
|
63333
|
+
})
|
63334
|
+
}
|
63335
|
+
}
|
63336
|
+
|
63337
|
+
return fs
|
63338
|
+
}
|
63339
|
+
|
63340
|
+
function enqueue (elem) {
|
63341
|
+
debug('ENQUEUE', elem[0].name, elem[1])
|
63342
|
+
fs[gracefulQueue].push(elem)
|
63343
|
+
retry()
|
63344
|
+
}
|
63345
|
+
|
63346
|
+
// keep track of the timeout between retry() calls
|
63347
|
+
var retryTimer
|
63348
|
+
|
63349
|
+
// reset the startTime and lastTime to now
|
63350
|
+
// this resets the start of the 60 second overall timeout as well as the
|
63351
|
+
// delay between attempts so that we'll retry these jobs sooner
|
63352
|
+
function resetQueue () {
|
63353
|
+
var now = Date.now()
|
63354
|
+
for (var i = 0; i < fs[gracefulQueue].length; ++i) {
|
63355
|
+
// entries that are only a length of 2 are from an older version, don't
|
63356
|
+
// bother modifying those since they'll be retried anyway.
|
63357
|
+
if (fs[gracefulQueue][i].length > 2) {
|
63358
|
+
fs[gracefulQueue][i][3] = now // startTime
|
63359
|
+
fs[gracefulQueue][i][4] = now // lastTime
|
63360
|
+
}
|
63361
|
+
}
|
63362
|
+
// call retry to make sure we're actively processing the queue
|
63363
|
+
retry()
|
63364
|
+
}
|
63365
|
+
|
63366
|
+
function retry () {
|
63367
|
+
// clear the timer and remove it to help prevent unintended concurrency
|
63368
|
+
clearTimeout(retryTimer)
|
63369
|
+
retryTimer = undefined
|
63370
|
+
|
63371
|
+
if (fs[gracefulQueue].length === 0)
|
63372
|
+
return
|
63373
|
+
|
63374
|
+
var elem = fs[gracefulQueue].shift()
|
63375
|
+
var fn = elem[0]
|
63376
|
+
var args = elem[1]
|
63377
|
+
// these items may be unset if they were added by an older graceful-fs
|
63378
|
+
var err = elem[2]
|
63379
|
+
var startTime = elem[3]
|
63380
|
+
var lastTime = elem[4]
|
63381
|
+
|
63382
|
+
// if we don't have a startTime we have no way of knowing if we've waited
|
63383
|
+
// long enough, so go ahead and retry this item now
|
63384
|
+
if (startTime === undefined) {
|
63385
|
+
debug('RETRY', fn.name, args)
|
63386
|
+
fn.apply(null, args)
|
63387
|
+
} else if (Date.now() - startTime >= 60000) {
|
63388
|
+
// it's been more than 60 seconds total, bail now
|
63389
|
+
debug('TIMEOUT', fn.name, args)
|
63390
|
+
var cb = args.pop()
|
63391
|
+
if (typeof cb === 'function')
|
63392
|
+
cb.call(null, err)
|
63393
|
+
} else {
|
63394
|
+
// the amount of time between the last attempt and right now
|
63395
|
+
var sinceAttempt = Date.now() - lastTime
|
63396
|
+
// the amount of time between when we first tried, and when we last tried
|
63397
|
+
// rounded up to at least 1
|
63398
|
+
var sinceStart = Math.max(lastTime - startTime, 1)
|
63399
|
+
// backoff. wait longer than the total time we've been retrying, but only
|
63400
|
+
// up to a maximum of 100ms
|
63401
|
+
var desiredDelay = Math.min(sinceStart * 1.2, 100)
|
63402
|
+
// it's been long enough since the last retry, do it again
|
63403
|
+
if (sinceAttempt >= desiredDelay) {
|
63404
|
+
debug('RETRY', fn.name, args)
|
63405
|
+
fn.apply(null, args.concat([startTime]))
|
63406
|
+
} else {
|
63407
|
+
// if we can't do this job yet, push it to the end of the queue
|
63408
|
+
// and let the next iteration check again
|
63409
|
+
fs[gracefulQueue].push(elem)
|
63410
|
+
}
|
63411
|
+
}
|
63412
|
+
|
63413
|
+
// schedule our next run if one isn't already scheduled
|
63414
|
+
if (retryTimer === undefined) {
|
63415
|
+
retryTimer = setTimeout(retry, 0)
|
63416
|
+
}
|
63417
|
+
}
|
63418
|
+
|
63419
|
+
|
63420
|
+
/***/ }),
|
63421
|
+
|
63422
|
+
/***/ 36465:
|
63423
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
63424
|
+
|
63425
|
+
var Stream = __webpack_require__(92413).Stream
|
63426
|
+
|
63427
|
+
module.exports = legacy
|
63428
|
+
|
63429
|
+
function legacy (fs) {
|
63430
|
+
return {
|
63431
|
+
ReadStream: ReadStream,
|
63432
|
+
WriteStream: WriteStream
|
63433
|
+
}
|
63434
|
+
|
63435
|
+
function ReadStream (path, options) {
|
63436
|
+
if (!(this instanceof ReadStream)) return new ReadStream(path, options);
|
63437
|
+
|
63438
|
+
Stream.call(this);
|
63439
|
+
|
63440
|
+
var self = this;
|
63441
|
+
|
63442
|
+
this.path = path;
|
63443
|
+
this.fd = null;
|
63444
|
+
this.readable = true;
|
63445
|
+
this.paused = false;
|
63446
|
+
|
63447
|
+
this.flags = 'r';
|
63448
|
+
this.mode = 438; /*=0666*/
|
63449
|
+
this.bufferSize = 64 * 1024;
|
63450
|
+
|
63451
|
+
options = options || {};
|
63452
|
+
|
63453
|
+
// Mixin options into this
|
63454
|
+
var keys = Object.keys(options);
|
63455
|
+
for (var index = 0, length = keys.length; index < length; index++) {
|
63456
|
+
var key = keys[index];
|
63457
|
+
this[key] = options[key];
|
63458
|
+
}
|
63459
|
+
|
63460
|
+
if (this.encoding) this.setEncoding(this.encoding);
|
63461
|
+
|
63462
|
+
if (this.start !== undefined) {
|
63463
|
+
if ('number' !== typeof this.start) {
|
63464
|
+
throw TypeError('start must be a Number');
|
63465
|
+
}
|
63466
|
+
if (this.end === undefined) {
|
63467
|
+
this.end = Infinity;
|
63468
|
+
} else if ('number' !== typeof this.end) {
|
63469
|
+
throw TypeError('end must be a Number');
|
63470
|
+
}
|
63471
|
+
|
63472
|
+
if (this.start > this.end) {
|
63473
|
+
throw new Error('start must be <= end');
|
63474
|
+
}
|
63475
|
+
|
63476
|
+
this.pos = this.start;
|
63477
|
+
}
|
63478
|
+
|
63479
|
+
if (this.fd !== null) {
|
63480
|
+
process.nextTick(function() {
|
63481
|
+
self._read();
|
63482
|
+
});
|
63483
|
+
return;
|
63484
|
+
}
|
63485
|
+
|
63486
|
+
fs.open(this.path, this.flags, this.mode, function (err, fd) {
|
63487
|
+
if (err) {
|
63488
|
+
self.emit('error', err);
|
63489
|
+
self.readable = false;
|
63490
|
+
return;
|
63491
|
+
}
|
63492
|
+
|
63493
|
+
self.fd = fd;
|
63494
|
+
self.emit('open', fd);
|
63495
|
+
self._read();
|
63496
|
+
})
|
63497
|
+
}
|
63498
|
+
|
63499
|
+
function WriteStream (path, options) {
|
63500
|
+
if (!(this instanceof WriteStream)) return new WriteStream(path, options);
|
63501
|
+
|
63502
|
+
Stream.call(this);
|
63503
|
+
|
63504
|
+
this.path = path;
|
63505
|
+
this.fd = null;
|
63506
|
+
this.writable = true;
|
63507
|
+
|
63508
|
+
this.flags = 'w';
|
63509
|
+
this.encoding = 'binary';
|
63510
|
+
this.mode = 438; /*=0666*/
|
63511
|
+
this.bytesWritten = 0;
|
63512
|
+
|
63513
|
+
options = options || {};
|
63514
|
+
|
63515
|
+
// Mixin options into this
|
63516
|
+
var keys = Object.keys(options);
|
63517
|
+
for (var index = 0, length = keys.length; index < length; index++) {
|
63518
|
+
var key = keys[index];
|
63519
|
+
this[key] = options[key];
|
63520
|
+
}
|
63521
|
+
|
63522
|
+
if (this.start !== undefined) {
|
63523
|
+
if ('number' !== typeof this.start) {
|
63524
|
+
throw TypeError('start must be a Number');
|
63525
|
+
}
|
63526
|
+
if (this.start < 0) {
|
63527
|
+
throw new Error('start must be >= zero');
|
63528
|
+
}
|
63529
|
+
|
63530
|
+
this.pos = this.start;
|
63531
|
+
}
|
63532
|
+
|
63533
|
+
this.busy = false;
|
63534
|
+
this._queue = [];
|
63535
|
+
|
63536
|
+
if (this.fd === null) {
|
63537
|
+
this._open = fs.open;
|
63538
|
+
this._queue.push([this._open, this.path, this.flags, this.mode, undefined]);
|
63539
|
+
this.flush();
|
63540
|
+
}
|
63541
|
+
}
|
63542
|
+
}
|
63543
|
+
|
63544
|
+
|
63545
|
+
/***/ }),
|
63546
|
+
|
63547
|
+
/***/ 54692:
|
63548
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
63549
|
+
|
63550
|
+
var constants = __webpack_require__(27619)
|
63551
|
+
|
63552
|
+
var origCwd = process.cwd
|
63553
|
+
var cwd = null
|
63554
|
+
|
63555
|
+
var platform = process.env.GRACEFUL_FS_PLATFORM || process.platform
|
63556
|
+
|
63557
|
+
process.cwd = function() {
|
63558
|
+
if (!cwd)
|
63559
|
+
cwd = origCwd.call(process)
|
63560
|
+
return cwd
|
63561
|
+
}
|
63562
|
+
try {
|
63563
|
+
process.cwd()
|
63564
|
+
} catch (er) {}
|
63565
|
+
|
63566
|
+
// This check is needed until node.js 12 is required
|
63567
|
+
if (typeof process.chdir === 'function') {
|
63568
|
+
var chdir = process.chdir
|
63569
|
+
process.chdir = function (d) {
|
63570
|
+
cwd = null
|
63571
|
+
chdir.call(process, d)
|
63572
|
+
}
|
63573
|
+
if (Object.setPrototypeOf) Object.setPrototypeOf(process.chdir, chdir)
|
63574
|
+
}
|
63575
|
+
|
63576
|
+
module.exports = patch
|
63577
|
+
|
63578
|
+
function patch (fs) {
|
63579
|
+
// (re-)implement some things that are known busted or missing.
|
63580
|
+
|
63581
|
+
// lchmod, broken prior to 0.6.2
|
63582
|
+
// back-port the fix here.
|
63583
|
+
if (constants.hasOwnProperty('O_SYMLINK') &&
|
63584
|
+
process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)) {
|
63585
|
+
patchLchmod(fs)
|
63586
|
+
}
|
63587
|
+
|
63588
|
+
// lutimes implementation, or no-op
|
63589
|
+
if (!fs.lutimes) {
|
63590
|
+
patchLutimes(fs)
|
63591
|
+
}
|
63592
|
+
|
63593
|
+
// https://github.com/isaacs/node-graceful-fs/issues/4
|
63594
|
+
// Chown should not fail on einval or eperm if non-root.
|
63595
|
+
// It should not fail on enosys ever, as this just indicates
|
63596
|
+
// that a fs doesn't support the intended operation.
|
63597
|
+
|
63598
|
+
fs.chown = chownFix(fs.chown)
|
63599
|
+
fs.fchown = chownFix(fs.fchown)
|
63600
|
+
fs.lchown = chownFix(fs.lchown)
|
63601
|
+
|
63602
|
+
fs.chmod = chmodFix(fs.chmod)
|
63603
|
+
fs.fchmod = chmodFix(fs.fchmod)
|
63604
|
+
fs.lchmod = chmodFix(fs.lchmod)
|
63605
|
+
|
63606
|
+
fs.chownSync = chownFixSync(fs.chownSync)
|
63607
|
+
fs.fchownSync = chownFixSync(fs.fchownSync)
|
63608
|
+
fs.lchownSync = chownFixSync(fs.lchownSync)
|
63609
|
+
|
63610
|
+
fs.chmodSync = chmodFixSync(fs.chmodSync)
|
63611
|
+
fs.fchmodSync = chmodFixSync(fs.fchmodSync)
|
63612
|
+
fs.lchmodSync = chmodFixSync(fs.lchmodSync)
|
63613
|
+
|
63614
|
+
fs.stat = statFix(fs.stat)
|
63615
|
+
fs.fstat = statFix(fs.fstat)
|
63616
|
+
fs.lstat = statFix(fs.lstat)
|
63617
|
+
|
63618
|
+
fs.statSync = statFixSync(fs.statSync)
|
63619
|
+
fs.fstatSync = statFixSync(fs.fstatSync)
|
63620
|
+
fs.lstatSync = statFixSync(fs.lstatSync)
|
63621
|
+
|
63622
|
+
// if lchmod/lchown do not exist, then make them no-ops
|
63623
|
+
if (fs.chmod && !fs.lchmod) {
|
63624
|
+
fs.lchmod = function (path, mode, cb) {
|
63625
|
+
if (cb) process.nextTick(cb)
|
63626
|
+
}
|
63627
|
+
fs.lchmodSync = function () {}
|
63628
|
+
}
|
63629
|
+
if (fs.chown && !fs.lchown) {
|
63630
|
+
fs.lchown = function (path, uid, gid, cb) {
|
63631
|
+
if (cb) process.nextTick(cb)
|
63632
|
+
}
|
63633
|
+
fs.lchownSync = function () {}
|
63634
|
+
}
|
63635
|
+
|
63636
|
+
// on Windows, A/V software can lock the directory, causing this
|
63637
|
+
// to fail with an EACCES or EPERM if the directory contains newly
|
63638
|
+
// created files. Try again on failure, for up to 60 seconds.
|
63639
|
+
|
63640
|
+
// Set the timeout this long because some Windows Anti-Virus, such as Parity
|
63641
|
+
// bit9, may lock files for up to a minute, causing npm package install
|
63642
|
+
// failures. Also, take care to yield the scheduler. Windows scheduling gives
|
63643
|
+
// CPU to a busy looping process, which can cause the program causing the lock
|
63644
|
+
// contention to be starved of CPU by node, so the contention doesn't resolve.
|
63645
|
+
if (platform === "win32") {
|
63646
|
+
fs.rename = typeof fs.rename !== 'function' ? fs.rename
|
63647
|
+
: (function (fs$rename) {
|
63648
|
+
function rename (from, to, cb) {
|
63649
|
+
var start = Date.now()
|
63650
|
+
var backoff = 0;
|
63651
|
+
fs$rename(from, to, function CB (er) {
|
63652
|
+
if (er
|
63653
|
+
&& (er.code === "EACCES" || er.code === "EPERM" || er.code === "EBUSY")
|
63654
|
+
&& Date.now() - start < 60000) {
|
63655
|
+
setTimeout(function() {
|
63656
|
+
fs.stat(to, function (stater, st) {
|
63657
|
+
if (stater && stater.code === "ENOENT")
|
63658
|
+
fs$rename(from, to, CB);
|
63659
|
+
else
|
63660
|
+
cb(er)
|
63661
|
+
})
|
63662
|
+
}, backoff)
|
63663
|
+
if (backoff < 100)
|
63664
|
+
backoff += 10;
|
63665
|
+
return;
|
63666
|
+
}
|
63667
|
+
if (cb) cb(er)
|
63668
|
+
})
|
63669
|
+
}
|
63670
|
+
if (Object.setPrototypeOf) Object.setPrototypeOf(rename, fs$rename)
|
63671
|
+
return rename
|
63672
|
+
})(fs.rename)
|
63673
|
+
}
|
63674
|
+
|
63675
|
+
// if read() returns EAGAIN, then just try it again.
|
63676
|
+
fs.read = typeof fs.read !== 'function' ? fs.read
|
63677
|
+
: (function (fs$read) {
|
63678
|
+
function read (fd, buffer, offset, length, position, callback_) {
|
63679
|
+
var callback
|
63680
|
+
if (callback_ && typeof callback_ === 'function') {
|
63681
|
+
var eagCounter = 0
|
63682
|
+
callback = function (er, _, __) {
|
63683
|
+
if (er && er.code === 'EAGAIN' && eagCounter < 10) {
|
63684
|
+
eagCounter ++
|
63685
|
+
return fs$read.call(fs, fd, buffer, offset, length, position, callback)
|
63686
|
+
}
|
63687
|
+
callback_.apply(this, arguments)
|
63688
|
+
}
|
63689
|
+
}
|
63690
|
+
return fs$read.call(fs, fd, buffer, offset, length, position, callback)
|
63691
|
+
}
|
63692
|
+
|
63693
|
+
// This ensures `util.promisify` works as it does for native `fs.read`.
|
63694
|
+
if (Object.setPrototypeOf) Object.setPrototypeOf(read, fs$read)
|
63695
|
+
return read
|
63696
|
+
})(fs.read)
|
63697
|
+
|
63698
|
+
fs.readSync = typeof fs.readSync !== 'function' ? fs.readSync
|
63699
|
+
: (function (fs$readSync) { return function (fd, buffer, offset, length, position) {
|
63700
|
+
var eagCounter = 0
|
63701
|
+
while (true) {
|
63702
|
+
try {
|
63703
|
+
return fs$readSync.call(fs, fd, buffer, offset, length, position)
|
63704
|
+
} catch (er) {
|
63705
|
+
if (er.code === 'EAGAIN' && eagCounter < 10) {
|
63706
|
+
eagCounter ++
|
63707
|
+
continue
|
63708
|
+
}
|
63709
|
+
throw er
|
63710
|
+
}
|
63711
|
+
}
|
63712
|
+
}})(fs.readSync)
|
63713
|
+
|
63714
|
+
function patchLchmod (fs) {
|
63715
|
+
fs.lchmod = function (path, mode, callback) {
|
63716
|
+
fs.open( path
|
63717
|
+
, constants.O_WRONLY | constants.O_SYMLINK
|
63718
|
+
, mode
|
63719
|
+
, function (err, fd) {
|
63720
|
+
if (err) {
|
63721
|
+
if (callback) callback(err)
|
63722
|
+
return
|
63723
|
+
}
|
63724
|
+
// prefer to return the chmod error, if one occurs,
|
63725
|
+
// but still try to close, and report closing errors if they occur.
|
63726
|
+
fs.fchmod(fd, mode, function (err) {
|
63727
|
+
fs.close(fd, function(err2) {
|
63728
|
+
if (callback) callback(err || err2)
|
63729
|
+
})
|
63730
|
+
})
|
63731
|
+
})
|
63732
|
+
}
|
63733
|
+
|
63734
|
+
fs.lchmodSync = function (path, mode) {
|
63735
|
+
var fd = fs.openSync(path, constants.O_WRONLY | constants.O_SYMLINK, mode)
|
63736
|
+
|
63737
|
+
// prefer to return the chmod error, if one occurs,
|
63738
|
+
// but still try to close, and report closing errors if they occur.
|
63739
|
+
var threw = true
|
63740
|
+
var ret
|
63741
|
+
try {
|
63742
|
+
ret = fs.fchmodSync(fd, mode)
|
63743
|
+
threw = false
|
63744
|
+
} finally {
|
63745
|
+
if (threw) {
|
63746
|
+
try {
|
63747
|
+
fs.closeSync(fd)
|
63748
|
+
} catch (er) {}
|
63749
|
+
} else {
|
63750
|
+
fs.closeSync(fd)
|
63751
|
+
}
|
63752
|
+
}
|
63753
|
+
return ret
|
63754
|
+
}
|
63755
|
+
}
|
63756
|
+
|
63757
|
+
function patchLutimes (fs) {
|
63758
|
+
if (constants.hasOwnProperty("O_SYMLINK") && fs.futimes) {
|
63759
|
+
fs.lutimes = function (path, at, mt, cb) {
|
63760
|
+
fs.open(path, constants.O_SYMLINK, function (er, fd) {
|
63761
|
+
if (er) {
|
63762
|
+
if (cb) cb(er)
|
63763
|
+
return
|
63764
|
+
}
|
63765
|
+
fs.futimes(fd, at, mt, function (er) {
|
63766
|
+
fs.close(fd, function (er2) {
|
63767
|
+
if (cb) cb(er || er2)
|
63768
|
+
})
|
63769
|
+
})
|
63770
|
+
})
|
63771
|
+
}
|
63772
|
+
|
63773
|
+
fs.lutimesSync = function (path, at, mt) {
|
63774
|
+
var fd = fs.openSync(path, constants.O_SYMLINK)
|
63775
|
+
var ret
|
63776
|
+
var threw = true
|
63777
|
+
try {
|
63778
|
+
ret = fs.futimesSync(fd, at, mt)
|
63779
|
+
threw = false
|
63780
|
+
} finally {
|
63781
|
+
if (threw) {
|
63782
|
+
try {
|
63783
|
+
fs.closeSync(fd)
|
63784
|
+
} catch (er) {}
|
63785
|
+
} else {
|
63786
|
+
fs.closeSync(fd)
|
63787
|
+
}
|
63788
|
+
}
|
63789
|
+
return ret
|
63790
|
+
}
|
63791
|
+
|
63792
|
+
} else if (fs.futimes) {
|
63793
|
+
fs.lutimes = function (_a, _b, _c, cb) { if (cb) process.nextTick(cb) }
|
63794
|
+
fs.lutimesSync = function () {}
|
63795
|
+
}
|
63796
|
+
}
|
63797
|
+
|
63798
|
+
function chmodFix (orig) {
|
63799
|
+
if (!orig) return orig
|
63800
|
+
return function (target, mode, cb) {
|
63801
|
+
return orig.call(fs, target, mode, function (er) {
|
63802
|
+
if (chownErOk(er)) er = null
|
63803
|
+
if (cb) cb.apply(this, arguments)
|
63804
|
+
})
|
63805
|
+
}
|
63806
|
+
}
|
63807
|
+
|
63808
|
+
function chmodFixSync (orig) {
|
63809
|
+
if (!orig) return orig
|
63810
|
+
return function (target, mode) {
|
63811
|
+
try {
|
63812
|
+
return orig.call(fs, target, mode)
|
63813
|
+
} catch (er) {
|
63814
|
+
if (!chownErOk(er)) throw er
|
63815
|
+
}
|
63816
|
+
}
|
63817
|
+
}
|
63818
|
+
|
63819
|
+
|
63820
|
+
function chownFix (orig) {
|
63821
|
+
if (!orig) return orig
|
63822
|
+
return function (target, uid, gid, cb) {
|
63823
|
+
return orig.call(fs, target, uid, gid, function (er) {
|
63824
|
+
if (chownErOk(er)) er = null
|
63825
|
+
if (cb) cb.apply(this, arguments)
|
63826
|
+
})
|
63827
|
+
}
|
63828
|
+
}
|
63829
|
+
|
63830
|
+
function chownFixSync (orig) {
|
63831
|
+
if (!orig) return orig
|
63832
|
+
return function (target, uid, gid) {
|
63833
|
+
try {
|
63834
|
+
return orig.call(fs, target, uid, gid)
|
63835
|
+
} catch (er) {
|
63836
|
+
if (!chownErOk(er)) throw er
|
63837
|
+
}
|
63838
|
+
}
|
63839
|
+
}
|
63840
|
+
|
63841
|
+
function statFix (orig) {
|
63842
|
+
if (!orig) return orig
|
63843
|
+
// Older versions of Node erroneously returned signed integers for
|
63844
|
+
// uid + gid.
|
63845
|
+
return function (target, options, cb) {
|
63846
|
+
if (typeof options === 'function') {
|
63847
|
+
cb = options
|
63848
|
+
options = null
|
63849
|
+
}
|
63850
|
+
function callback (er, stats) {
|
63851
|
+
if (stats) {
|
63852
|
+
if (stats.uid < 0) stats.uid += 0x100000000
|
63853
|
+
if (stats.gid < 0) stats.gid += 0x100000000
|
63854
|
+
}
|
63855
|
+
if (cb) cb.apply(this, arguments)
|
63856
|
+
}
|
63857
|
+
return options ? orig.call(fs, target, options, callback)
|
63858
|
+
: orig.call(fs, target, callback)
|
63859
|
+
}
|
63860
|
+
}
|
63861
|
+
|
63862
|
+
function statFixSync (orig) {
|
63863
|
+
if (!orig) return orig
|
63864
|
+
// Older versions of Node erroneously returned signed integers for
|
63865
|
+
// uid + gid.
|
63866
|
+
return function (target, options) {
|
63867
|
+
var stats = options ? orig.call(fs, target, options)
|
63868
|
+
: orig.call(fs, target)
|
63869
|
+
if (stats) {
|
63870
|
+
if (stats.uid < 0) stats.uid += 0x100000000
|
63871
|
+
if (stats.gid < 0) stats.gid += 0x100000000
|
63872
|
+
}
|
63873
|
+
return stats;
|
63874
|
+
}
|
63875
|
+
}
|
63876
|
+
|
63877
|
+
// ENOSYS means that the fs doesn't support the op. Just ignore
|
63878
|
+
// that, because it doesn't matter.
|
63879
|
+
//
|
63880
|
+
// if there's no getuid, or if getuid() is something other
|
63881
|
+
// than 0, and the error is EINVAL or EPERM, then just ignore
|
63882
|
+
// it.
|
63883
|
+
//
|
63884
|
+
// This specific case is a silent failure in cp, install, tar,
|
63885
|
+
// and most other unix tools that manage permissions.
|
63886
|
+
//
|
63887
|
+
// When running as root, or if other types of errors are
|
63888
|
+
// encountered, then it's strict.
|
63889
|
+
function chownErOk (er) {
|
63890
|
+
if (!er)
|
63891
|
+
return true
|
63892
|
+
|
63893
|
+
if (er.code === "ENOSYS")
|
63894
|
+
return true
|
63895
|
+
|
63896
|
+
var nonroot = !process.getuid || process.getuid() !== 0
|
63897
|
+
if (nonroot) {
|
63898
|
+
if (er.code === "EINVAL" || er.code === "EPERM")
|
63899
|
+
return true
|
63900
|
+
}
|
63901
|
+
|
63902
|
+
return false
|
63903
|
+
}
|
63904
|
+
}
|
63905
|
+
|
63906
|
+
|
63593
63907
|
/***/ }),
|
63594
63908
|
|
63595
63909
|
/***/ 73661:
|
@@ -67323,7 +67637,7 @@ return{name,number,description,supported,action,forced,standard};
|
|
67323
67637
|
*/
|
67324
67638
|
|
67325
67639
|
var util = __webpack_require__(31669);
|
67326
|
-
var ms = __webpack_require__(
|
67640
|
+
var ms = __webpack_require__(21378);
|
67327
67641
|
|
67328
67642
|
module.exports = function (t) {
|
67329
67643
|
if (typeof t === 'number') return t;
|
@@ -88938,7 +89252,7 @@ module.exports = {
|
|
88938
89252
|
|
88939
89253
|
var _fs
|
88940
89254
|
try {
|
88941
|
-
_fs = __webpack_require__(
|
89255
|
+
_fs = __webpack_require__(57156)
|
88942
89256
|
} catch (_) {
|
88943
89257
|
_fs = __webpack_require__(35747)
|
88944
89258
|
}
|
@@ -89079,7 +89393,7 @@ module.exports = jsonfile
|
|
89079
89393
|
|
89080
89394
|
let _fs
|
89081
89395
|
try {
|
89082
|
-
_fs = __webpack_require__(
|
89396
|
+
_fs = __webpack_require__(57156)
|
89083
89397
|
} catch (_) {
|
89084
89398
|
_fs = __webpack_require__(35747)
|
89085
89399
|
}
|
@@ -114811,175 +115125,6 @@ function plural(ms, msAbs, n, name) {
|
|
114811
115125
|
}
|
114812
115126
|
|
114813
115127
|
|
114814
|
-
/***/ }),
|
114815
|
-
|
114816
|
-
/***/ 82801:
|
114817
|
-
/***/ ((module) => {
|
114818
|
-
|
114819
|
-
/**
|
114820
|
-
* Helpers.
|
114821
|
-
*/
|
114822
|
-
|
114823
|
-
var s = 1000;
|
114824
|
-
var m = s * 60;
|
114825
|
-
var h = m * 60;
|
114826
|
-
var d = h * 24;
|
114827
|
-
var w = d * 7;
|
114828
|
-
var y = d * 365.25;
|
114829
|
-
|
114830
|
-
/**
|
114831
|
-
* Parse or format the given `val`.
|
114832
|
-
*
|
114833
|
-
* Options:
|
114834
|
-
*
|
114835
|
-
* - `long` verbose formatting [false]
|
114836
|
-
*
|
114837
|
-
* @param {String|Number} val
|
114838
|
-
* @param {Object} [options]
|
114839
|
-
* @throws {Error} throw an error if val is not a non-empty string or a number
|
114840
|
-
* @return {String|Number}
|
114841
|
-
* @api public
|
114842
|
-
*/
|
114843
|
-
|
114844
|
-
module.exports = function (val, options) {
|
114845
|
-
options = options || {};
|
114846
|
-
var type = typeof val;
|
114847
|
-
if (type === 'string' && val.length > 0) {
|
114848
|
-
return parse(val);
|
114849
|
-
} else if (type === 'number' && isFinite(val)) {
|
114850
|
-
return options.long ? fmtLong(val) : fmtShort(val);
|
114851
|
-
}
|
114852
|
-
throw new Error(
|
114853
|
-
'val is not a non-empty string or a valid number. val=' +
|
114854
|
-
JSON.stringify(val)
|
114855
|
-
);
|
114856
|
-
};
|
114857
|
-
|
114858
|
-
/**
|
114859
|
-
* Parse the given `str` and return milliseconds.
|
114860
|
-
*
|
114861
|
-
* @param {String} str
|
114862
|
-
* @return {Number}
|
114863
|
-
* @api private
|
114864
|
-
*/
|
114865
|
-
|
114866
|
-
function parse(str) {
|
114867
|
-
str = String(str);
|
114868
|
-
if (str.length > 100) {
|
114869
|
-
return;
|
114870
|
-
}
|
114871
|
-
var match = /^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(
|
114872
|
-
str
|
114873
|
-
);
|
114874
|
-
if (!match) {
|
114875
|
-
return;
|
114876
|
-
}
|
114877
|
-
var n = parseFloat(match[1]);
|
114878
|
-
var type = (match[2] || 'ms').toLowerCase();
|
114879
|
-
switch (type) {
|
114880
|
-
case 'years':
|
114881
|
-
case 'year':
|
114882
|
-
case 'yrs':
|
114883
|
-
case 'yr':
|
114884
|
-
case 'y':
|
114885
|
-
return n * y;
|
114886
|
-
case 'weeks':
|
114887
|
-
case 'week':
|
114888
|
-
case 'w':
|
114889
|
-
return n * w;
|
114890
|
-
case 'days':
|
114891
|
-
case 'day':
|
114892
|
-
case 'd':
|
114893
|
-
return n * d;
|
114894
|
-
case 'hours':
|
114895
|
-
case 'hour':
|
114896
|
-
case 'hrs':
|
114897
|
-
case 'hr':
|
114898
|
-
case 'h':
|
114899
|
-
return n * h;
|
114900
|
-
case 'minutes':
|
114901
|
-
case 'minute':
|
114902
|
-
case 'mins':
|
114903
|
-
case 'min':
|
114904
|
-
case 'm':
|
114905
|
-
return n * m;
|
114906
|
-
case 'seconds':
|
114907
|
-
case 'second':
|
114908
|
-
case 'secs':
|
114909
|
-
case 'sec':
|
114910
|
-
case 's':
|
114911
|
-
return n * s;
|
114912
|
-
case 'milliseconds':
|
114913
|
-
case 'millisecond':
|
114914
|
-
case 'msecs':
|
114915
|
-
case 'msec':
|
114916
|
-
case 'ms':
|
114917
|
-
return n;
|
114918
|
-
default:
|
114919
|
-
return undefined;
|
114920
|
-
}
|
114921
|
-
}
|
114922
|
-
|
114923
|
-
/**
|
114924
|
-
* Short format for `ms`.
|
114925
|
-
*
|
114926
|
-
* @param {Number} ms
|
114927
|
-
* @return {String}
|
114928
|
-
* @api private
|
114929
|
-
*/
|
114930
|
-
|
114931
|
-
function fmtShort(ms) {
|
114932
|
-
var msAbs = Math.abs(ms);
|
114933
|
-
if (msAbs >= d) {
|
114934
|
-
return Math.round(ms / d) + 'd';
|
114935
|
-
}
|
114936
|
-
if (msAbs >= h) {
|
114937
|
-
return Math.round(ms / h) + 'h';
|
114938
|
-
}
|
114939
|
-
if (msAbs >= m) {
|
114940
|
-
return Math.round(ms / m) + 'm';
|
114941
|
-
}
|
114942
|
-
if (msAbs >= s) {
|
114943
|
-
return Math.round(ms / s) + 's';
|
114944
|
-
}
|
114945
|
-
return ms + 'ms';
|
114946
|
-
}
|
114947
|
-
|
114948
|
-
/**
|
114949
|
-
* Long format for `ms`.
|
114950
|
-
*
|
114951
|
-
* @param {Number} ms
|
114952
|
-
* @return {String}
|
114953
|
-
* @api private
|
114954
|
-
*/
|
114955
|
-
|
114956
|
-
function fmtLong(ms) {
|
114957
|
-
var msAbs = Math.abs(ms);
|
114958
|
-
if (msAbs >= d) {
|
114959
|
-
return plural(ms, msAbs, d, 'day');
|
114960
|
-
}
|
114961
|
-
if (msAbs >= h) {
|
114962
|
-
return plural(ms, msAbs, h, 'hour');
|
114963
|
-
}
|
114964
|
-
if (msAbs >= m) {
|
114965
|
-
return plural(ms, msAbs, m, 'minute');
|
114966
|
-
}
|
114967
|
-
if (msAbs >= s) {
|
114968
|
-
return plural(ms, msAbs, s, 'second');
|
114969
|
-
}
|
114970
|
-
return ms + ' ms';
|
114971
|
-
}
|
114972
|
-
|
114973
|
-
/**
|
114974
|
-
* Pluralization helper.
|
114975
|
-
*/
|
114976
|
-
|
114977
|
-
function plural(ms, msAbs, n, name) {
|
114978
|
-
var isPlural = msAbs >= n * 1.5;
|
114979
|
-
return Math.round(ms / n) + ' ' + name + (isPlural ? 's' : '');
|
114980
|
-
}
|
114981
|
-
|
114982
|
-
|
114983
115128
|
/***/ }),
|
114984
115129
|
|
114985
115130
|
/***/ 14666:
|
@@ -180969,7 +181114,7 @@ module.exports.sync = writeFileSync
|
|
180969
181114
|
module.exports._getTmpname = getTmpname // for testing
|
180970
181115
|
module.exports._cleanupOnExit = cleanupOnExit
|
180971
181116
|
|
180972
|
-
var fs = __webpack_require__(
|
181117
|
+
var fs = __webpack_require__(57156)
|
180973
181118
|
var MurmurHash3 = __webpack_require__(3502)
|
180974
181119
|
var onExit = __webpack_require__(7277)
|
180975
181120
|
var path = __webpack_require__(85622)
|
@@ -189294,6 +189439,15 @@ class MissingBuildTarget extends Error {
|
|
189294
189439
|
}
|
189295
189440
|
}
|
189296
189441
|
exports.MissingBuildTarget = MissingBuildTarget;
|
189442
|
+
function supportsRootCommand(turboSemVer) {
|
189443
|
+
if (!turboSemVer) {
|
189444
|
+
return false;
|
189445
|
+
}
|
189446
|
+
if (!semver_1.default.validRange(turboSemVer)) {
|
189447
|
+
return false;
|
189448
|
+
}
|
189449
|
+
return !semver_1.default.intersects(turboSemVer, '<1.8.0');
|
189450
|
+
}
|
189297
189451
|
async function getMonorepoDefaultSettings(projectName, projectPath, relativeToRoot, detectorFilesystem) {
|
189298
189452
|
const [monorepoManager, packageManager] = await Promise.all([
|
189299
189453
|
detect_framework_1.detectFramework({
|
@@ -189341,7 +189495,7 @@ async function getMonorepoDefaultSettings(projectName, projectPath, relativeToRo
|
|
189341
189495
|
}
|
189342
189496
|
let buildCommand = null;
|
189343
189497
|
if (projectPath) {
|
189344
|
-
if (
|
189498
|
+
if (supportsRootCommand(turboSemVer)) {
|
189345
189499
|
buildCommand = `turbo run build`;
|
189346
189500
|
}
|
189347
189501
|
else {
|
@@ -193070,6 +193224,7 @@ const help = () => `
|
|
193070
193224
|
-e, --env Include an env var during run time (e.g.: ${chalk_1.default.dim('`-e KEY=value`')}). Can appear many times.
|
193071
193225
|
-b, --build-env Similar to ${chalk_1.default.dim('`--env`')} but for build time only.
|
193072
193226
|
-m, --meta Add metadata for the deployment (e.g.: ${chalk_1.default.dim('`-m KEY=value`')}). Can appear many times.
|
193227
|
+
--no-wait Don't wait for the deployment to finish
|
193073
193228
|
-S, --scope Set a custom scope
|
193074
193229
|
--regions Set default regions to enable the deployment on
|
193075
193230
|
--prod Create a production deployment
|
@@ -193174,6 +193329,7 @@ const validate_archive_format_1 = __webpack_require__(86974);
|
|
193174
193329
|
const parse_env_1 = __webpack_require__(59818);
|
193175
193330
|
const error_utils_1 = __webpack_require__(39799);
|
193176
193331
|
const project_settings_1 = __webpack_require__(61440);
|
193332
|
+
const is_deploying_1 = __webpack_require__(25307);
|
193177
193333
|
exports.default = async (client) => {
|
193178
193334
|
const { output } = client;
|
193179
193335
|
let argv = null;
|
@@ -193191,6 +193347,7 @@ exports.default = async (client) => {
|
|
193191
193347
|
'--prebuilt': Boolean,
|
193192
193348
|
'--prod': Boolean,
|
193193
193349
|
'--archive': String,
|
193350
|
+
'--no-wait': Boolean,
|
193194
193351
|
'--yes': Boolean,
|
193195
193352
|
'-f': '--force',
|
193196
193353
|
'-p': '--public',
|
@@ -193453,10 +193610,15 @@ exports.default = async (client) => {
|
|
193453
193610
|
});
|
193454
193611
|
let deployStamp = (0, stamp_1.default)();
|
193455
193612
|
let deployment = null;
|
193613
|
+
const noWait = !!argv['--no-wait'];
|
193456
193614
|
const localConfigurationOverrides = (0, project_settings_1.pickOverrides)(localConfig);
|
193615
|
+
const name = project ? project.name : newProjectName;
|
193616
|
+
if (!name) {
|
193617
|
+
throw new Error('`name` not found on project or provided by existing project');
|
193618
|
+
}
|
193457
193619
|
try {
|
193458
193620
|
const createArgs = {
|
193459
|
-
name
|
193621
|
+
name,
|
193460
193622
|
env: deploymentEnv,
|
193461
193623
|
build: { env: deploymentBuildEnv },
|
193462
193624
|
forceNew: argv['--force'],
|
@@ -193464,8 +193626,7 @@ exports.default = async (client) => {
|
|
193464
193626
|
prebuilt: argv['--prebuilt'],
|
193465
193627
|
rootDirectory,
|
193466
193628
|
quiet,
|
193467
|
-
wantsPublic: argv['--public'] || localConfig.public,
|
193468
|
-
type: null,
|
193629
|
+
wantsPublic: Boolean(argv['--public'] || localConfig.public),
|
193469
193630
|
nowConfig: {
|
193470
193631
|
...localConfig,
|
193471
193632
|
// `images` is allowed in "vercel.json" and processed
|
@@ -193478,6 +193639,7 @@ exports.default = async (client) => {
|
|
193478
193639
|
deployStamp,
|
193479
193640
|
target,
|
193480
193641
|
skipAutoDetectionConfirmation: autoConfirm,
|
193642
|
+
noWait,
|
193481
193643
|
};
|
193482
193644
|
if (!localConfig.builds || localConfig.builds.length === 0) {
|
193483
193645
|
// Only add projectSettings for zero config deployments
|
@@ -193530,8 +193692,10 @@ exports.default = async (client) => {
|
|
193530
193692
|
output.error(`Running Checks: ${counterList}`);
|
193531
193693
|
return 1;
|
193532
193694
|
}
|
193533
|
-
|
193534
|
-
|
193695
|
+
if (!noWait) {
|
193696
|
+
// get the deployment just to double check that it actually deployed
|
193697
|
+
await (0, get_deployment_1.default)(client, contextName, deployment.id);
|
193698
|
+
}
|
193535
193699
|
if (deployment === null) {
|
193536
193700
|
error('Uploading failed. Please try again.');
|
193537
193701
|
return 1;
|
@@ -193592,7 +193756,7 @@ exports.default = async (client) => {
|
|
193592
193756
|
(0, error_1.handleError)(err);
|
193593
193757
|
return 1;
|
193594
193758
|
}
|
193595
|
-
return printDeploymentStatus(output, client, deployment, deployStamp);
|
193759
|
+
return printDeploymentStatus(output, client, deployment, deployStamp, noWait);
|
193596
193760
|
};
|
193597
193761
|
function handleCreateDeployError(output, error, localConfig) {
|
193598
193762
|
if (error instanceof errors_ts_1.InvalidDomain) {
|
@@ -193658,10 +193822,17 @@ const addProcessEnv = async (log, env) => {
|
|
193658
193822
|
}
|
193659
193823
|
}
|
193660
193824
|
};
|
193661
|
-
const printDeploymentStatus = async (output, client, { readyState, alias: aliasList, aliasError, target, indications, url: deploymentUrl, aliasWarning, }, deployStamp) => {
|
193825
|
+
const printDeploymentStatus = async (output, client, { readyState, alias: aliasList, aliasError, target, indications, url: deploymentUrl, aliasWarning, }, deployStamp, noWait) => {
|
193662
193826
|
indications = indications || [];
|
193663
193827
|
const isProdDeployment = target === 'production';
|
193664
|
-
|
193828
|
+
let isStillBuilding = false;
|
193829
|
+
if (noWait) {
|
193830
|
+
if ((0, is_deploying_1.isDeploying)(readyState)) {
|
193831
|
+
isStillBuilding = true;
|
193832
|
+
output.print((0, emoji_1.prependEmoji)('Note: Deployment is still processing...', (0, emoji_1.emoji)('notice')) + '\n');
|
193833
|
+
}
|
193834
|
+
}
|
193835
|
+
if (!isStillBuilding && readyState !== 'READY') {
|
193665
193836
|
output.error(`Your deployment failed. Please retry later. More: https://err.sh/vercel/deployment-error`);
|
193666
193837
|
return 1;
|
193667
193838
|
}
|
@@ -193671,7 +193842,8 @@ const printDeploymentStatus = async (output, client, { readyState, alias: aliasL
|
|
193671
193842
|
else {
|
193672
193843
|
// print preview/production url
|
193673
193844
|
let previewUrl;
|
193674
|
-
if
|
193845
|
+
// if `noWait` is true, then use the deployment url, not an alias
|
193846
|
+
if (!noWait && Array.isArray(aliasList) && aliasList.length > 0) {
|
193675
193847
|
const previewUrlInfo = await (0, get_preferred_preview_url_1.getPreferredPreviewURL)(client, aliasList);
|
193676
193848
|
if (previewUrlInfo) {
|
193677
193849
|
previewUrl = previewUrlInfo.previewUrl;
|
@@ -195362,7 +195534,6 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
195362
195534
|
};
|
195363
195535
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
195364
195536
|
const chalk_1 = __importDefault(__webpack_require__(90877));
|
195365
|
-
const types_1 = __webpack_require__(76210);
|
195366
195537
|
const stamp_1 = __importDefault(__webpack_require__(49079));
|
195367
195538
|
const add_env_record_1 = __importDefault(__webpack_require__(49196));
|
195368
195539
|
const get_env_records_1 = __importDefault(__webpack_require__(72913));
|
@@ -195407,7 +195578,7 @@ async function add(client, project, opts, args, output) {
|
|
195407
195578
|
}
|
195408
195579
|
const { envs } = await (0, get_env_records_1.default)(output, client, project.id, 'vercel-cli:env:add');
|
195409
195580
|
const existing = new Set(envs.filter(r => r.key === envName).map(r => r.target));
|
195410
|
-
const choices =
|
195581
|
+
const choices = env_target_1.envTargetChoices.filter(c => !existing.has(c.value));
|
195411
195582
|
if (choices.length === 0) {
|
195412
195583
|
output.error(`The variable ${(0, param_1.default)(envName)} has already been added to all Environments. To remove, run ${(0, pkg_name_1.getCommandName)(`env rm ${envName}`)}.`);
|
195413
195584
|
return 1;
|
@@ -195439,7 +195610,7 @@ async function add(client, project, opts, args, output) {
|
|
195439
195610
|
if (!stdInput &&
|
195440
195611
|
!envGitBranch &&
|
195441
195612
|
envTargets.length === 1 &&
|
195442
|
-
envTargets[0] ===
|
195613
|
+
envTargets[0] === 'preview') {
|
195443
195614
|
const { inputValue } = await client.prompt({
|
195444
195615
|
type: 'input',
|
195445
195616
|
name: 'inputValue',
|
@@ -195450,7 +195621,7 @@ async function add(client, project, opts, args, output) {
|
|
195450
195621
|
const addStamp = (0, stamp_1.default)();
|
195451
195622
|
try {
|
195452
195623
|
output.spinner('Saving');
|
195453
|
-
await (0, add_env_record_1.default)(output, client, project.id,
|
195624
|
+
await (0, add_env_record_1.default)(output, client, project.id, 'encrypted', envName, envValue, envTargets, envGitBranch);
|
195454
195625
|
}
|
195455
195626
|
catch (err) {
|
195456
195627
|
if ((0, errors_ts_1.isAPIError)(err) && (0, known_error_1.isKnownError)(err)) {
|
@@ -195633,7 +195804,6 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
195633
195804
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
195634
195805
|
const chalk_1 = __importDefault(__webpack_require__(90877));
|
195635
195806
|
const ms_1 = __importDefault(__webpack_require__(21378));
|
195636
|
-
const types_1 = __webpack_require__(76210);
|
195637
195807
|
const format_table_1 = __importDefault(__webpack_require__(11759));
|
195638
195808
|
const get_env_records_1 = __importDefault(__webpack_require__(72913));
|
195639
195809
|
const format_env_target_1 = __importDefault(__webpack_require__(17135));
|
@@ -195680,13 +195850,13 @@ function getTable(records) {
|
|
195680
195850
|
}
|
195681
195851
|
function getRow(env) {
|
195682
195852
|
let value;
|
195683
|
-
if (env.type ===
|
195853
|
+
if (env.type === 'plain') {
|
195684
195854
|
// replace space characters (line-break, etc.) with simple spaces
|
195685
195855
|
// to make sure the displayed value is a single line
|
195686
195856
|
const singleLineValue = env.value.replace(/\s/g, ' ');
|
195687
195857
|
value = chalk_1.default.gray((0, ellipsis_1.default)(singleLineValue, 19));
|
195688
195858
|
}
|
195689
|
-
else if (env.type ===
|
195859
|
+
else if (env.type === 'system') {
|
195690
195860
|
value = chalk_1.default.gray.italic(env.value);
|
195691
195861
|
}
|
195692
195862
|
else {
|
@@ -195717,7 +195887,6 @@ const chalk_1 = __importDefault(__webpack_require__(90877));
|
|
195717
195887
|
const fs_extra_1 = __webpack_require__(36365);
|
195718
195888
|
const fs_1 = __webpack_require__(35747);
|
195719
195889
|
const path_1 = __webpack_require__(85622);
|
195720
|
-
const types_1 = __webpack_require__(76210);
|
195721
195890
|
const emoji_1 = __webpack_require__(35172);
|
195722
195891
|
const confirm_1 = __importDefault(__webpack_require__(59320));
|
195723
195892
|
const param_1 = __importDefault(__webpack_require__(20668));
|
@@ -195773,7 +195942,7 @@ async function pull(client, project, environment, opts, args, output, cwd, sourc
|
|
195773
195942
|
const pullStamp = (0, stamp_1.default)();
|
195774
195943
|
output.spinner('Downloading');
|
195775
195944
|
const records = (await (0, get_env_records_1.pullEnvRecords)(output, client, project.id, source, {
|
195776
|
-
target: environment ||
|
195945
|
+
target: environment || 'development',
|
195777
195946
|
gitBranch,
|
195778
195947
|
})).env;
|
195779
195948
|
let deltaString = '';
|
@@ -196643,6 +196812,10 @@ const get_deployment_1 = __importDefault(__webpack_require__(84249));
|
|
196643
196812
|
const title_1 = __importDefault(__webpack_require__(16650));
|
196644
196813
|
const error_utils_1 = __webpack_require__(39799);
|
196645
196814
|
const url_1 = __webpack_require__(78835);
|
196815
|
+
const read_standard_input_1 = __importDefault(__webpack_require__(57317));
|
196816
|
+
const sleep_1 = __importDefault(__webpack_require__(89507));
|
196817
|
+
const ms_1 = __importDefault(__webpack_require__(21378));
|
196818
|
+
const is_deploying_1 = __webpack_require__(25307);
|
196646
196819
|
const help = () => {
|
196647
196820
|
console.log(`
|
196648
196821
|
${chalk_1.default.bold(`${logo_1.default} ${(0, pkg_name_1.getPkgName)()} inspect`)} <url>
|
@@ -196656,6 +196829,8 @@ const help = () => {
|
|
196656
196829
|
-d, --debug Debug mode [off]
|
196657
196830
|
--no-color No color mode [off]
|
196658
196831
|
-S, --scope Set a custom scope
|
196832
|
+
--timeout=${chalk_1.default.bold.underline('TIME')} Time to wait for deployment completion [3m]
|
196833
|
+
--wait Blocks until deployment completes
|
196659
196834
|
|
196660
196835
|
${chalk_1.default.dim('Examples:')}
|
196661
196836
|
|
@@ -196666,12 +196841,23 @@ const help = () => {
|
|
196666
196841
|
${chalk_1.default.gray('-')} Get information about the deployment an alias points to
|
196667
196842
|
|
196668
196843
|
${chalk_1.default.cyan(`$ ${(0, pkg_name_1.getPkgName)()} inspect my-deployment.vercel.app`)}
|
196844
|
+
|
196845
|
+
${chalk_1.default.gray('-')} Get information about a deployment by piping in the URL
|
196846
|
+
|
196847
|
+
${chalk_1.default.cyan(`$ echo my-deployment.vercel.app | ${(0, pkg_name_1.getPkgName)()} inspect`)}
|
196848
|
+
|
196849
|
+
${chalk_1.default.gray('-')} Wait up to 90 seconds for deployment to complete
|
196850
|
+
|
196851
|
+
${chalk_1.default.cyan(`$ ${(0, pkg_name_1.getPkgName)()} inspect my-deployment.vercel.app --wait --timeout 90s`)}
|
196669
196852
|
`);
|
196670
196853
|
};
|
196671
196854
|
async function main(client) {
|
196672
196855
|
let argv;
|
196673
196856
|
try {
|
196674
|
-
argv = (0, get_args_1.default)(client.argv.slice(2)
|
196857
|
+
argv = (0, get_args_1.default)(client.argv.slice(2), {
|
196858
|
+
'--timeout': String,
|
196859
|
+
'--wait': Boolean,
|
196860
|
+
});
|
196675
196861
|
}
|
196676
196862
|
catch (err) {
|
196677
196863
|
(0, error_1.handleError)(err);
|
@@ -196684,11 +196870,25 @@ async function main(client) {
|
|
196684
196870
|
const { print, log, error } = client.output;
|
196685
196871
|
// extract the first parameter
|
196686
196872
|
let [, deploymentIdOrHost] = argv._;
|
196687
|
-
if (
|
196873
|
+
if (!deploymentIdOrHost) {
|
196874
|
+
// if the URL is not passed in, check stdin
|
196875
|
+
// allows cool stuff like `echo my-deployment.vercel.app | vc inspect --wait`
|
196876
|
+
const stdInput = await (0, read_standard_input_1.default)(client.stdin);
|
196877
|
+
if (stdInput) {
|
196878
|
+
deploymentIdOrHost = stdInput;
|
196879
|
+
}
|
196880
|
+
}
|
196881
|
+
if (!deploymentIdOrHost) {
|
196688
196882
|
error(`${(0, pkg_name_1.getCommandName)('inspect <url>')} expects exactly one argument`);
|
196689
196883
|
help();
|
196690
196884
|
return 1;
|
196691
196885
|
}
|
196886
|
+
// validate the timeout
|
196887
|
+
const timeout = (0, ms_1.default)(argv['--timeout'] ?? '3m');
|
196888
|
+
if (timeout === undefined) {
|
196889
|
+
error(`Invalid timeout "${argv['--timeout']}"`);
|
196890
|
+
return 1;
|
196891
|
+
}
|
196692
196892
|
let contextName = null;
|
196693
196893
|
try {
|
196694
196894
|
({ contextName } = await (0, get_scope_1.default)(client));
|
@@ -196707,8 +196907,18 @@ async function main(client) {
|
|
196707
196907
|
}
|
196708
196908
|
catch { }
|
196709
196909
|
client.output.spinner(`Fetching deployment "${deploymentIdOrHost}" in ${chalk_1.default.bold(contextName)}`);
|
196910
|
+
const until = Date.now() + timeout;
|
196911
|
+
const wait = argv['--wait'];
|
196710
196912
|
// resolve the deployment, since we might have been given an alias
|
196711
|
-
|
196913
|
+
let deployment = await (0, get_deployment_1.default)(client, contextName, deploymentIdOrHost);
|
196914
|
+
while (Date.now() < until) {
|
196915
|
+
if (!wait || !(0, is_deploying_1.isDeploying)(deployment.readyState)) {
|
196916
|
+
break;
|
196917
|
+
}
|
196918
|
+
await (0, sleep_1.default)(250);
|
196919
|
+
// check the deployment state again
|
196920
|
+
deployment = await (0, get_deployment_1.default)(client, contextName, deploymentIdOrHost);
|
196921
|
+
}
|
196712
196922
|
const { id, name, url, createdAt, routes, readyState, alias: aliases, } = deployment;
|
196713
196923
|
const { builds } = deployment.version === 2
|
196714
196924
|
? await client.fetch(`/v11/deployments/${id}/builds`)
|
@@ -199160,7 +199370,6 @@ const metrics_1 = __webpack_require__(31113);
|
|
199160
199370
|
const pkg_name_1 = __webpack_require__(79000);
|
199161
199371
|
const prompt_1 = __importDefault(__webpack_require__(75964));
|
199162
199372
|
const box_1 = __importDefault(__webpack_require__(58587));
|
199163
|
-
const isCanary = pkg_1.default.version.includes('canary');
|
199164
199373
|
const VERCEL_DIR = (0, global_path_1.default)();
|
199165
199374
|
const VERCEL_CONFIG_PATH = configFiles.getConfigFilePath();
|
199166
199375
|
const VERCEL_AUTH_CONFIG_PATH = configFiles.getAuthConfigFilePath();
|
@@ -199171,7 +199380,7 @@ source_map_support_1.default.install();
|
|
199171
199380
|
Sentry.init({
|
199172
199381
|
dsn: constants_1.SENTRY_DSN,
|
199173
199382
|
release: `vercel-cli@${pkg_1.default.version}`,
|
199174
|
-
environment:
|
199383
|
+
environment: 'stable',
|
199175
199384
|
});
|
199176
199385
|
let client;
|
199177
199386
|
let output;
|
@@ -199238,7 +199447,7 @@ const main = async () => {
|
|
199238
199447
|
console.log(`${chalk_1.default.grey(`${(0, pkg_name_1.getTitleName)()} CLI ${pkg_1.default.version} ${targetOrSubcommand} (beta) — https://vercel.com/feedback`)}`);
|
199239
199448
|
}
|
199240
199449
|
else {
|
199241
|
-
output.print(`${chalk_1.default.grey(`${(0, pkg_name_1.getTitleName)()} CLI ${pkg_1.default.version}
|
199450
|
+
output.print(`${chalk_1.default.grey(`${(0, pkg_name_1.getTitleName)()} CLI ${pkg_1.default.version}`)}\n`);
|
199242
199451
|
}
|
199243
199452
|
// Handle `--version` directly
|
199244
199453
|
if (!targetOrSubcommand && argv['--version']) {
|
@@ -199681,7 +199890,6 @@ main()
|
|
199681
199890
|
// Check if an update is available. If so, `latest` will contain a string
|
199682
199891
|
// of the latest version, otherwise `undefined`.
|
199683
199892
|
const latest = (0, get_latest_version_1.default)({
|
199684
|
-
distTag: isCanary ? 'canary' : 'latest',
|
199685
199893
|
output,
|
199686
199894
|
pkg: pkg_1.default,
|
199687
199895
|
});
|
@@ -202627,6 +202835,37 @@ async function getPreferredPreviewURL(client, aliasList) {
|
|
202627
202835
|
exports.getPreferredPreviewURL = getPreferredPreviewURL;
|
202628
202836
|
|
202629
202837
|
|
202838
|
+
/***/ }),
|
202839
|
+
|
202840
|
+
/***/ 25307:
|
202841
|
+
/***/ ((__unused_webpack_module, exports) => {
|
202842
|
+
|
202843
|
+
"use strict";
|
202844
|
+
|
202845
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
202846
|
+
exports.isDeploying = exports.deploymentCompletedStates = exports.deploymentInProgressStates = void 0;
|
202847
|
+
exports.deploymentInProgressStates = [
|
202848
|
+
'QUEUED',
|
202849
|
+
'BUILDING',
|
202850
|
+
'INITIALIZING',
|
202851
|
+
];
|
202852
|
+
exports.deploymentCompletedStates = [
|
202853
|
+
'READY',
|
202854
|
+
'CANCELED',
|
202855
|
+
'ERROR',
|
202856
|
+
];
|
202857
|
+
/**
|
202858
|
+
* Checks if the deployments readyState is considered to be in progress.
|
202859
|
+
* @param readyState The deployment's readyState
|
202860
|
+
* @returns `true` if in a pending deployment state, otherwise `false` if it's
|
202861
|
+
* ready/canceled/errored
|
202862
|
+
*/
|
202863
|
+
function isDeploying(readyState) {
|
202864
|
+
return exports.deploymentInProgressStates.includes(readyState);
|
202865
|
+
}
|
202866
|
+
exports.isDeploying = isDeploying;
|
202867
|
+
|
202868
|
+
|
202630
202869
|
/***/ }),
|
202631
202870
|
|
202632
202871
|
/***/ 43667:
|
@@ -202686,7 +202925,7 @@ const emoji_1 = __webpack_require__(35172);
|
|
202686
202925
|
function printInspectUrl(output, inspectorUrl, deployStamp) {
|
202687
202926
|
output.print((0, emoji_1.prependEmoji)(`Inspect: ${chalk_1.default.bold(inspectorUrl)} ${deployStamp()}`, (0, emoji_1.emoji)('inspect')) + `\n`);
|
202688
202927
|
}
|
202689
|
-
async function processDeployment({ org, cwd, projectName, isSettingUpProject, archive, skipAutoDetectionConfirmation, ...args }) {
|
202928
|
+
async function processDeployment({ org, cwd, projectName, isSettingUpProject, archive, skipAutoDetectionConfirmation, noWait, ...args }) {
|
202690
202929
|
let { now, output, paths, requestBody, deployStamp, force, withCache, quiet, prebuilt, rootDirectory, } = args;
|
202691
202930
|
const { debug } = output;
|
202692
202931
|
const { env = {} } = requestBody;
|
@@ -202768,6 +203007,9 @@ async function processDeployment({ org, cwd, projectName, isSettingUpProject, ar
|
|
202768
203007
|
if (quiet) {
|
202769
203008
|
process.stdout.write(`https://${event.payload.url}`);
|
202770
203009
|
}
|
203010
|
+
if (noWait) {
|
203011
|
+
return event.payload;
|
203012
|
+
}
|
202771
203013
|
output.spinner(event.payload.readyState === 'QUEUED' ? 'Queued' : 'Building', 0);
|
202772
203014
|
}
|
202773
203015
|
if (event.type === 'building') {
|
@@ -203812,10 +204054,8 @@ const cmd_1 = __importDefault(__webpack_require__(62422));
|
|
203812
204054
|
const link_1 = __importDefault(__webpack_require__(39302));
|
203813
204055
|
const sleep_1 = __importDefault(__webpack_require__(89507));
|
203814
204056
|
const path_helpers_1 = __webpack_require__(5410);
|
203815
|
-
const get_dist_tag_1 = __webpack_require__(57112);
|
203816
204057
|
const local_path_1 = __importDefault(__webpack_require__(25723));
|
203817
204058
|
const errors_ts_1 = __webpack_require__(39240);
|
203818
|
-
const pkg_1 = __importDefault(__webpack_require__(42246));
|
203819
204059
|
const link_2 = __webpack_require__(49347);
|
203820
204060
|
const get_files_1 = __webpack_require__(20802);
|
203821
204061
|
const validate_config_1 = __webpack_require__(21144);
|
@@ -204744,7 +204984,7 @@ class DevServer {
|
|
204744
204984
|
const opts = { output: this.output };
|
204745
204985
|
const files = (await (0, get_files_1.staticFiles)(this.cwd, opts)).map(f => (0, path_helpers_1.relative)(this.cwd, f));
|
204746
204986
|
let { builders, warnings, errors, defaultRoutes, redirectRoutes, rewriteRoutes, errorRoutes, } = await (0, fs_detectors_1.detectBuilders)(files, pkg, {
|
204747
|
-
tag:
|
204987
|
+
tag: 'latest',
|
204748
204988
|
functions: vercelConfig.functions,
|
204749
204989
|
projectSettings: projectSettings || this.projectSettings,
|
204750
204990
|
featHandleMiss,
|
@@ -207135,29 +207375,29 @@ function addDeltaSection(prefix, arr, changed = false) {
|
|
207135
207375
|
/***/ }),
|
207136
207376
|
|
207137
207377
|
/***/ 20229:
|
207138
|
-
/***/ ((__unused_webpack_module, exports, __webpack_require__)
|
207378
|
+
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
207139
207379
|
|
207140
207380
|
"use strict";
|
207141
207381
|
|
207382
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
207383
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
207384
|
+
};
|
207142
207385
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
207143
|
-
exports.getEnvTargetPlaceholder = exports.isValidEnvTarget = exports.
|
207144
|
-
const
|
207145
|
-
|
207146
|
-
|
207147
|
-
|
207148
|
-
|
207149
|
-
|
207150
|
-
name: key,
|
207151
|
-
value: value,
|
207152
|
-
}));
|
207153
|
-
}
|
207154
|
-
exports.getEnvTargetChoices = getEnvTargetChoices;
|
207386
|
+
exports.getEnvTargetPlaceholder = exports.isValidEnvTarget = exports.envTargetChoices = void 0;
|
207387
|
+
const constants_1 = __webpack_require__(98551);
|
207388
|
+
const title_1 = __importDefault(__webpack_require__(16650));
|
207389
|
+
exports.envTargetChoices = constants_1.PROJECT_ENV_TARGET.map(t => ({
|
207390
|
+
name: (0, title_1.default)(t),
|
207391
|
+
value: t,
|
207392
|
+
}));
|
207155
207393
|
function isValidEnvTarget(target) {
|
207156
|
-
|
207394
|
+
// Specify `map` returns strings, instead of string constants so `.includes` works
|
207395
|
+
return (typeof target === 'undefined' ||
|
207396
|
+
exports.envTargetChoices.map(c => c.value).includes(target));
|
207157
207397
|
}
|
207158
207398
|
exports.isValidEnvTarget = isValidEnvTarget;
|
207159
207399
|
function getEnvTargetPlaceholder() {
|
207160
|
-
return `<${
|
207400
|
+
return `<${exports.envTargetChoices.map(c => c.value).join(' | ')}>`;
|
207161
207401
|
}
|
207162
207402
|
exports.getEnvTargetPlaceholder = getEnvTargetPlaceholder;
|
207163
207403
|
|
@@ -208749,29 +208989,6 @@ async function getDeployment(client, contextName, hostOrId) {
|
|
208749
208989
|
exports.default = getDeployment;
|
208750
208990
|
|
208751
208991
|
|
208752
|
-
/***/ }),
|
208753
|
-
|
208754
|
-
/***/ 57112:
|
208755
|
-
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
208756
|
-
|
208757
|
-
"use strict";
|
208758
|
-
|
208759
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
208760
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
208761
|
-
};
|
208762
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
208763
|
-
exports.getDistTag = void 0;
|
208764
|
-
const semver_1 = __importDefault(__webpack_require__(54373));
|
208765
|
-
function getDistTag(version) {
|
208766
|
-
const parsed = semver_1.default.parse(version);
|
208767
|
-
if (parsed && typeof parsed.prerelease[0] === 'string') {
|
208768
|
-
return parsed.prerelease[0];
|
208769
|
-
}
|
208770
|
-
return 'latest';
|
208771
|
-
}
|
208772
|
-
exports.getDistTag = getDistTag;
|
208773
|
-
|
208774
|
-
|
208775
208992
|
/***/ }),
|
208776
208993
|
|
208777
208994
|
/***/ 20802:
|
@@ -209189,31 +209406,10 @@ exports.default = getSubcommand;
|
|
209189
209406
|
"use strict";
|
209190
209407
|
|
209191
209408
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
209192
|
-
const path_1 = __webpack_require__(85622);
|
209193
209409
|
const fs_extra_1 = __webpack_require__(36365);
|
209194
|
-
const
|
209410
|
+
const path_1 = __webpack_require__(85622);
|
209411
|
+
const build_utils_1 = __webpack_require__(63445);
|
209195
209412
|
const pkg_name_1 = __webpack_require__(79000);
|
209196
|
-
async function isYarn() {
|
209197
|
-
let s;
|
209198
|
-
let binPath = process.argv[1];
|
209199
|
-
// eslint-disable-next-line no-constant-condition
|
209200
|
-
while (true) {
|
209201
|
-
s = await (0, fs_extra_1.lstat)(binPath);
|
209202
|
-
if (s.isSymbolicLink()) {
|
209203
|
-
binPath = (0, path_1.resolve)((0, path_1.dirname)(binPath), await (0, fs_extra_1.readlink)(binPath));
|
209204
|
-
}
|
209205
|
-
else {
|
209206
|
-
break;
|
209207
|
-
}
|
209208
|
-
}
|
209209
|
-
const pkgPath = (0, path_1.join)((0, path_1.dirname)(binPath), '..', 'package.json');
|
209210
|
-
/*
|
209211
|
-
* Generally, pkgPath looks like:
|
209212
|
-
* "/Users/username/.config/yarn/global/node_modules/vercel/package.json"
|
209213
|
-
* "/usr/local/share/.config/yarn/global/node_modules/vercel/package.json"
|
209214
|
-
*/
|
209215
|
-
return pkgPath.includes((0, path_1.join)('yarn', 'global'));
|
209216
|
-
}
|
209217
209413
|
async function getConfigPrefix() {
|
209218
209414
|
const paths = [
|
209219
209415
|
process.env.npm_config_userconfig || process.env.NPM_CONFIG_USERCONFIG,
|
@@ -209252,6 +209448,9 @@ async function isGlobal() {
|
|
209252
209448
|
if (installPath.includes(['', 'yarn', 'global', 'node_modules', ''].join(path_1.sep))) {
|
209253
209449
|
return true;
|
209254
209450
|
}
|
209451
|
+
if (installPath.includes(['', 'pnpm', 'global', ''].join(path_1.sep))) {
|
209452
|
+
return true;
|
209453
|
+
}
|
209255
209454
|
if (installPath.includes(['', 'fnm', 'node-versions', ''].join(path_1.sep))) {
|
209256
209455
|
return true;
|
209257
209456
|
}
|
@@ -209271,16 +209470,24 @@ async function isGlobal() {
|
|
209271
209470
|
}
|
209272
209471
|
}
|
209273
209472
|
async function getUpdateCommand() {
|
209274
|
-
const
|
209275
|
-
const
|
209473
|
+
const pkgAndVersion = `${(0, pkg_name_1.getPkgName)()}@latest`;
|
209474
|
+
const entrypoint = await (0, fs_extra_1.realpath)(process.argv[1]);
|
209475
|
+
let { cliType, lockfilePath } = await (0, build_utils_1.scanParentDirs)((0, path_1.dirname)((0, path_1.dirname)(entrypoint)));
|
209476
|
+
if (!lockfilePath) {
|
209477
|
+
// Global installs for npm do not have a lockfile
|
209478
|
+
cliType = 'npm';
|
209479
|
+
}
|
209480
|
+
const yarn = cliType === 'yarn';
|
209481
|
+
let install = yarn ? 'add' : 'i';
|
209276
209482
|
if (await isGlobal()) {
|
209277
|
-
|
209278
|
-
|
209279
|
-
|
209483
|
+
if (yarn) {
|
209484
|
+
install = 'global add';
|
209485
|
+
}
|
209486
|
+
else {
|
209487
|
+
install = 'i -g';
|
209488
|
+
}
|
209280
209489
|
}
|
209281
|
-
return
|
209282
|
-
? `yarn add ${pkgAndVersion}`
|
209283
|
-
: `npm i ${pkgAndVersion}`;
|
209490
|
+
return `${cliType} ${install} ${pkgAndVersion}`;
|
209284
209491
|
}
|
209285
209492
|
exports.default = getUpdateCommand;
|
209286
209493
|
|
@@ -209326,6 +209533,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
209326
209533
|
};
|
209327
209534
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
209328
209535
|
exports.printRemoteUrls = exports.parseRepoUrl = exports.formatProvider = exports.connectGitProvider = exports.disconnectGitProvider = void 0;
|
209536
|
+
const url_1 = __webpack_require__(78835);
|
209329
209537
|
const chalk_1 = __importDefault(__webpack_require__(90877));
|
209330
209538
|
const link_1 = __importDefault(__webpack_require__(39302));
|
209331
209539
|
const errors_ts_1 = __webpack_require__(39240);
|
@@ -209383,35 +209591,36 @@ function formatProvider(type) {
|
|
209383
209591
|
}
|
209384
209592
|
}
|
209385
209593
|
exports.formatProvider = formatProvider;
|
209386
|
-
function
|
209387
|
-
|
209388
|
-
|
209389
|
-
|
209390
|
-
const provider = /(?<=(\/\/|@)).*(?=(\.com|\.org))/.exec(originUrl)?.[0] ||
|
209391
|
-
originUrl.replace('www.', '').split('.')[0];
|
209392
|
-
if (!provider) {
|
209393
|
-
return null;
|
209394
|
-
}
|
209395
|
-
let org;
|
209396
|
-
let repo;
|
209397
|
-
if (isSSH) {
|
209398
|
-
org = originUrl.split(':')[1].split('/')[0];
|
209399
|
-
repo = originUrl.split('/')[1]?.replace('.git', '');
|
209594
|
+
function getURL(input) {
|
209595
|
+
let url = null;
|
209596
|
+
try {
|
209597
|
+
url = new url_1.URL(input);
|
209400
209598
|
}
|
209401
|
-
|
209402
|
-
|
209403
|
-
|
209404
|
-
|
209599
|
+
catch { }
|
209600
|
+
if (!url) {
|
209601
|
+
// Probably an SSH url, so mangle it into a
|
209602
|
+
// format that the URL constructor works with.
|
209603
|
+
try {
|
209604
|
+
url = new url_1.URL(`ssh://${input.replace(':', '/')}`);
|
209605
|
+
}
|
209606
|
+
catch { }
|
209405
209607
|
}
|
209406
|
-
|
209608
|
+
return url;
|
209609
|
+
}
|
209610
|
+
function parseRepoUrl(originUrl) {
|
209611
|
+
const url = getURL(originUrl);
|
209612
|
+
if (!url)
|
209407
209613
|
return null;
|
209408
|
-
|
209409
|
-
|
209410
|
-
|
209411
|
-
|
209412
|
-
|
209413
|
-
|
209414
|
-
|
209614
|
+
const hostParts = url.hostname.split('.');
|
209615
|
+
if (hostParts.length < 2)
|
209616
|
+
return null;
|
209617
|
+
const provider = hostParts[hostParts.length - 2];
|
209618
|
+
const pathParts = url.pathname.split('/').filter(Boolean);
|
209619
|
+
if (pathParts.length !== 2)
|
209620
|
+
return null;
|
209621
|
+
const org = pathParts[0];
|
209622
|
+
const repo = pathParts[1].replace(/\.git$/, '');
|
209623
|
+
return { url: originUrl, provider, org, repo };
|
209415
209624
|
}
|
209416
209625
|
exports.parseRepoUrl = parseRepoUrl;
|
209417
209626
|
function printRemoteUrls(output, remoteUrls) {
|
@@ -209572,7 +209781,7 @@ class Now extends events_1.default {
|
|
209572
209781
|
// Legacy
|
209573
209782
|
nowConfig: nowConfig = {},
|
209574
209783
|
// Latest
|
209575
|
-
name, project, prebuilt = false, rootDirectory, wantsPublic, meta, gitMetadata, regions, quiet = false, env, build, forceNew = false, withCache = false, target = null, deployStamp, projectSettings, skipAutoDetectionConfirmation, }, org, isSettingUpProject, archive, cwd) {
|
209784
|
+
name, project, prebuilt = false, rootDirectory, wantsPublic, meta, gitMetadata, regions, quiet = false, env, build, forceNew = false, withCache = false, target = null, deployStamp, projectSettings, skipAutoDetectionConfirmation, noWait, }, org, isSettingUpProject, archive, cwd) {
|
209576
209785
|
let hashes = {};
|
209577
209786
|
const uploadStamp = (0, stamp_1.default)();
|
209578
209787
|
let requestBody = {
|
@@ -209610,6 +209819,7 @@ class Now extends events_1.default {
|
|
209610
209819
|
cwd,
|
209611
209820
|
prebuilt,
|
209612
209821
|
rootDirectory,
|
209822
|
+
noWait,
|
209613
209823
|
});
|
209614
209824
|
if (deployment && deployment.warnings) {
|
209615
209825
|
let sizeExceeded = 0;
|
@@ -210967,25 +211177,6 @@ forceLowerCase = false, } = {}) {
|
|
210967
211177
|
exports.default = text;
|
210968
211178
|
|
210969
211179
|
|
210970
|
-
/***/ }),
|
210971
|
-
|
210972
|
-
/***/ 43617:
|
210973
|
-
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
210974
|
-
|
210975
|
-
"use strict";
|
210976
|
-
|
210977
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
210978
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
210979
|
-
};
|
210980
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
210981
|
-
exports.isCanary = void 0;
|
210982
|
-
const package_json_1 = __importDefault(__webpack_require__(60306));
|
210983
|
-
function isCanary() {
|
210984
|
-
return package_json_1.default.version.includes('canary');
|
210985
|
-
}
|
210986
|
-
exports.isCanary = isCanary;
|
210987
|
-
|
210988
|
-
|
210989
211180
|
/***/ }),
|
210990
211181
|
|
210991
211182
|
/***/ 82220:
|
@@ -212908,6 +213099,7 @@ const parseEnv = (env) => {
|
|
212908
213099
|
env = [env];
|
212909
213100
|
}
|
212910
213101
|
if (Array.isArray(env)) {
|
213102
|
+
const startingDict = {};
|
212911
213103
|
return env.reduce((o, e) => {
|
212912
213104
|
let key;
|
212913
213105
|
let value;
|
@@ -212919,9 +213111,11 @@ const parseEnv = (env) => {
|
|
212919
213111
|
key = e.slice(0, equalsSign);
|
212920
213112
|
value = e.slice(equalsSign + 1);
|
212921
213113
|
}
|
212922
|
-
|
213114
|
+
if (typeof value !== 'undefined') {
|
213115
|
+
o[key] = value;
|
213116
|
+
}
|
212923
213117
|
return o;
|
212924
|
-
},
|
213118
|
+
}, startingDict);
|
212925
213119
|
}
|
212926
213120
|
// assume it's already an Object
|
212927
213121
|
return env;
|
@@ -214946,19 +215140,11 @@ module.exports = JSON.parse("[[[0,44],\"disallowed_STD3_valid\"],[[45,46],\"vali
|
|
214946
215140
|
|
214947
215141
|
/***/ }),
|
214948
215142
|
|
214949
|
-
/***/ 60306:
|
214950
|
-
/***/ ((module) => {
|
214951
|
-
|
214952
|
-
"use strict";
|
214953
|
-
module.exports = JSON.parse("{\"name\":\"vercel\",\"version\":\"28.18.4\",\"preferGlobal\":true,\"license\":\"Apache-2.0\",\"description\":\"The command-line interface for Vercel\",\"homepage\":\"https://vercel.com\",\"repository\":{\"type\":\"git\",\"url\":\"https://github.com/vercel/vercel.git\",\"directory\":\"packages/cli\"},\"scripts\":{\"preinstall\":\"node ./scripts/preinstall.js\",\"test\":\"jest --env node --verbose --bail\",\"test-unit\":\"pnpm test test/unit/\",\"test-e2e\":\"rimraf test/fixtures/integration && pnpm test test/integration-1.test.ts test/integration-2.test.ts test/integration-3.test.ts\",\"test-dev\":\"pnpm test test/dev/\",\"coverage\":\"codecov\",\"build\":\"ts-node ./scripts/build.ts\",\"dev\":\"ts-node ./src/index.ts\"},\"bin\":{\"vc\":\"./dist/index.js\",\"vercel\":\"./dist/index.js\"},\"files\":[\"dist\",\"scripts/preinstall.js\"],\"engines\":{\"node\":\">= 14\"},\"dependencies\":{\"@vercel/build-utils\":\"6.7.1\",\"@vercel/go\":\"2.4.4\",\"@vercel/hydrogen\":\"0.0.62\",\"@vercel/next\":\"3.7.4\",\"@vercel/node\":\"2.10.3\",\"@vercel/python\":\"3.1.58\",\"@vercel/redwood\":\"1.1.14\",\"@vercel/remix-builder\":\"1.8.4\",\"@vercel/ruby\":\"1.3.75\",\"@vercel/static-build\":\"1.3.22\"},\"devDependencies\":{\"@alex_neo/jest-expect-message\":\"1.0.5\",\"@next/env\":\"11.1.2\",\"@sentry/node\":\"5.5.0\",\"@sindresorhus/slugify\":\"0.11.0\",\"@swc/core\":\"1.2.218\",\"@tootallnate/once\":\"1.1.2\",\"@types/async-retry\":\"1.2.1\",\"@types/bytes\":\"3.0.0\",\"@types/chance\":\"1.1.3\",\"@types/debug\":\"0.0.31\",\"@types/dotenv\":\"6.1.1\",\"@types/escape-html\":\"0.0.20\",\"@types/express\":\"4.17.13\",\"@types/fs-extra\":\"9.0.13\",\"@types/glob\":\"7.1.1\",\"@types/http-proxy\":\"1.16.2\",\"@types/ini\":\"1.3.31\",\"@types/inquirer\":\"7.3.1\",\"@types/jest\":\"27.4.1\",\"@types/jest-expect-message\":\"1.0.3\",\"@types/load-json-file\":\"2.0.7\",\"@types/mime-types\":\"2.1.0\",\"@types/minimatch\":\"3.0.3\",\"@types/mri\":\"1.1.0\",\"@types/ms\":\"0.7.30\",\"@types/node\":\"14.18.33\",\"@types/node-fetch\":\"2.5.10\",\"@types/npm-package-arg\":\"6.1.0\",\"@types/pluralize\":\"0.0.29\",\"@types/psl\":\"1.1.0\",\"@types/qs\":\"6.9.7\",\"@types/semver\":\"6.0.1\",\"@types/tar-fs\":\"1.16.1\",\"@types/text-table\":\"0.2.0\",\"@types/title\":\"3.4.1\",\"@types/universal-analytics\":\"0.4.2\",\"@types/update-notifier\":\"5.1.0\",\"@types/which\":\"1.3.2\",\"@types/write-json-file\":\"2.2.1\",\"@types/yauzl-promise\":\"2.1.0\",\"@vercel-internals/get-package-json\":\"*\",\"@vercel-internals/types\":\"*\",\"@vercel/client\":\"12.4.9\",\"@vercel/error-utils\":\"1.0.9\",\"@vercel/frameworks\":\"1.3.4\",\"@vercel/fs-detectors\":\"3.8.9\",\"@vercel/fun\":\"1.0.4\",\"@vercel/ncc\":\"0.24.0\",\"@vercel/routing-utils\":\"2.2.0\",\"@zeit/source-map-support\":\"0.6.2\",\"ajv\":\"6.12.2\",\"alpha-sort\":\"2.0.1\",\"ansi-escapes\":\"4.3.2\",\"ansi-regex\":\"5.0.1\",\"arg\":\"5.0.0\",\"async-listen\":\"1.2.0\",\"async-retry\":\"1.1.3\",\"async-sema\":\"2.1.4\",\"bytes\":\"3.0.0\",\"chalk\":\"4.1.0\",\"chance\":\"1.1.7\",\"chokidar\":\"3.3.1\",\"codecov\":\"3.8.2\",\"cpy\":\"7.2.0\",\"date-fns\":\"1.29.0\",\"debug\":\"3.1.0\",\"dot\":\"1.1.3\",\"dotenv\":\"4.0.0\",\"email-validator\":\"1.1.1\",\"epipebomb\":\"1.0.0\",\"escape-html\":\"1.0.3\",\"esm\":\"3.1.4\",\"execa\":\"3.2.0\",\"express\":\"4.17.1\",\"fast-deep-equal\":\"3.1.3\",\"find-up\":\"4.1.0\",\"fs-extra\":\"10.0.0\",\"get-port\":\"5.1.1\",\"git-last-commit\":\"1.0.1\",\"glob\":\"7.1.2\",\"http-proxy\":\"1.18.1\",\"ini\":\"3.0.0\",\"inquirer\":\"7.0.4\",\"is-docker\":\"2.2.1\",\"is-port-reachable\":\"3.1.0\",\"is-url\":\"1.2.2\",\"jaro-winkler\":\"0.2.8\",\"jest-matcher-utils\":\"29.3.1\",\"jsonlines\":\"0.1.1\",\"line-async-iterator\":\"3.0.0\",\"load-json-file\":\"3.0.0\",\"mime-types\":\"2.1.24\",\"minimatch\":\"3.1.2\",\"mri\":\"1.1.5\",\"ms\":\"2.1.2\",\"node-fetch\":\"2.6.7\",\"npm-package-arg\":\"6.1.0\",\"open\":\"8.4.0\",\"ora\":\"3.4.0\",\"pcre-to-regexp\":\"1.0.0\",\"pluralize\":\"7.0.0\",\"promisepipe\":\"3.0.0\",\"psl\":\"1.1.31\",\"qr-image\":\"3.2.0\",\"raw-body\":\"2.4.1\",\"rimraf\":\"3.0.2\",\"semver\":\"5.5.0\",\"serve-handler\":\"6.1.1\",\"strip-ansi\":\"6.0.1\",\"stripe\":\"5.1.0\",\"supports-hyperlinks\":\"2.2.0\",\"tar-fs\":\"1.16.3\",\"test-listen\":\"1.1.0\",\"text-table\":\"0.2.0\",\"title\":\"3.4.1\",\"tmp-promise\":\"1.0.3\",\"tree-kill\":\"1.2.2\",\"ts-node\":\"10.9.1\",\"typescript\":\"4.9.4\",\"universal-analytics\":\"0.4.20\",\"utility-types\":\"2.1.0\",\"write-json-file\":\"2.2.0\",\"xdg-app-paths\":\"5.1.0\",\"yauzl-promise\":\"2.1.3\"},\"jest\":{\"preset\":\"ts-jest\",\"globals\":{\"ts-jest\":{\"diagnostics\":false,\"isolatedModules\":true}},\"setupFilesAfterEnv\":[\"@alex_neo/jest-expect-message\"],\"verbose\":false,\"testEnvironment\":\"node\",\"testMatch\":[\"<rootDir>/test/**/*.test.ts\"]}}");
|
214954
|
-
|
214955
|
-
/***/ }),
|
214956
|
-
|
214957
215143
|
/***/ 10391:
|
214958
215144
|
/***/ ((module) => {
|
214959
215145
|
|
214960
215146
|
"use strict";
|
214961
|
-
module.exports = JSON.parse("{\"name\":\"@vercel/client\",\"version\":\"12.4.
|
215147
|
+
module.exports = JSON.parse("{\"name\":\"@vercel/client\",\"version\":\"12.4.10\",\"main\":\"dist/index.js\",\"typings\":\"dist/index.d.ts\",\"homepage\":\"https://vercel.com\",\"license\":\"Apache-2.0\",\"files\":[\"dist\"],\"repository\":{\"type\":\"git\",\"url\":\"https://github.com/vercel/vercel.git\",\"directory\":\"packages/client\"},\"scripts\":{\"build\":\"tsc\",\"test-e2e\":\"pnpm test tests/create-deployment.test.ts tests/create-legacy-deployment.test.ts tests/paths.test.ts\",\"test\":\"jest --env node --verbose --runInBand --bail\",\"test-unit\":\"pnpm test tests/unit.*test.*\"},\"engines\":{\"node\":\">= 14\"},\"devDependencies\":{\"@types/async-retry\":\"1.4.5\",\"@types/fs-extra\":\"7.0.0\",\"@types/jest\":\"27.4.1\",\"@types/minimatch\":\"3.0.5\",\"@types/ms\":\"0.7.30\",\"@types/node\":\"14.18.33\",\"@types/node-fetch\":\"2.5.4\",\"@types/recursive-readdir\":\"2.2.0\",\"@types/tar-fs\":\"1.16.1\",\"typescript\":\"4.3.4\"},\"dependencies\":{\"@vercel/build-utils\":\"6.7.1\",\"@vercel/routing-utils\":\"2.2.0\",\"@zeit/fetch\":\"5.2.0\",\"async-retry\":\"1.2.3\",\"async-sema\":\"3.0.0\",\"fs-extra\":\"8.0.1\",\"ignore\":\"4.0.6\",\"minimatch\":\"5.0.1\",\"ms\":\"2.1.2\",\"node-fetch\":\"2.6.7\",\"querystring\":\"^0.2.0\",\"sleep-promise\":\"8.0.1\",\"tar-fs\":\"1.16.3\"}}");
|
214962
215148
|
|
214963
215149
|
/***/ }),
|
214964
215150
|
|