vercel 27.3.3 → 27.3.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +180 -250
- package/package.json +15 -16
package/dist/index.js
CHANGED
@@ -201002,7 +201002,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
201002
201002
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
201003
201003
|
};
|
201004
201004
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
201005
|
-
exports.isSymbolicLink = void 0;
|
201005
|
+
exports.downloadFile = exports.isSymbolicLink = void 0;
|
201006
201006
|
const path_1 = __importDefault(__nested_webpack_require_845236__(5622));
|
201007
201007
|
const debug_1 = __importDefault(__nested_webpack_require_845236__(1868));
|
201008
201008
|
const file_fs_ref_1 = __importDefault(__nested_webpack_require_845236__(9331));
|
@@ -201021,7 +201021,7 @@ async function prepareSymlinkTarget(file, fsPath) {
|
|
201021
201021
|
return target;
|
201022
201022
|
}
|
201023
201023
|
if (file.type === 'FileRef' || file.type === 'FileBlob') {
|
201024
|
-
const targetPathBufferPromise =
|
201024
|
+
const targetPathBufferPromise = stream_to_buffer_1.default(await file.toStreamAsync());
|
201025
201025
|
const [targetPathBuffer] = await Promise.all([
|
201026
201026
|
targetPathBufferPromise,
|
201027
201027
|
mkdirPromise,
|
@@ -201032,6 +201032,9 @@ async function prepareSymlinkTarget(file, fsPath) {
|
|
201032
201032
|
}
|
201033
201033
|
async function downloadFile(file, fsPath) {
|
201034
201034
|
const { mode } = file;
|
201035
|
+
// If the source is a symlink, try to create it instead of copying the file.
|
201036
|
+
// Note: creating symlinks on Windows requires admin priviliges or symlinks
|
201037
|
+
// enabled in the group policy. We may want to improve the error message.
|
201035
201038
|
if (isSymbolicLink(mode)) {
|
201036
201039
|
const target = await prepareSymlinkTarget(file, fsPath);
|
201037
201040
|
await fs_extra_1.symlink(target, fsPath);
|
@@ -201040,6 +201043,7 @@ async function downloadFile(file, fsPath) {
|
|
201040
201043
|
const stream = file.toStream();
|
201041
201044
|
return file_fs_ref_1.default.fromStream({ mode, stream, fsPath });
|
201042
201045
|
}
|
201046
|
+
exports.downloadFile = downloadFile;
|
201043
201047
|
async function removeFile(basePath, fileMatched) {
|
201044
201048
|
const file = path_1.default.join(basePath, fileMatched);
|
201045
201049
|
await fs_extra_1.remove(file);
|
@@ -201066,6 +201070,20 @@ async function download(files, basePath, meta) {
|
|
201066
201070
|
if (Array.isArray(filesChanged) && !filesChanged.includes(name)) {
|
201067
201071
|
return;
|
201068
201072
|
}
|
201073
|
+
// Some builders resolve symlinks and return both
|
201074
|
+
// a file, node_modules/<symlink>/package.json, and
|
201075
|
+
// node_modules/<symlink>, a symlink.
|
201076
|
+
// Removing the file matches how the yazl lambda zip
|
201077
|
+
// behaves so we can use download() with `vercel build`.
|
201078
|
+
const parts = name.split('/');
|
201079
|
+
for (let i = 1; i < parts.length; i++) {
|
201080
|
+
const dir = parts.slice(0, i).join('/');
|
201081
|
+
const parent = files[dir];
|
201082
|
+
if (parent && isSymbolicLink(parent.mode)) {
|
201083
|
+
console.warn(`Warning: file "${name}" is within a symlinked directory "${dir}" and will be ignored`);
|
201084
|
+
return;
|
201085
|
+
}
|
201086
|
+
}
|
201069
201087
|
const file = files[name];
|
201070
201088
|
const fsPath = path_1.default.join(basePath, name);
|
201071
201089
|
files2[name] = await downloadFile(file, fsPath);
|
@@ -201080,14 +201098,14 @@ exports.default = download;
|
|
201080
201098
|
/***/ }),
|
201081
201099
|
|
201082
201100
|
/***/ 3838:
|
201083
|
-
/***/ ((__unused_webpack_module, exports,
|
201101
|
+
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_849671__) => {
|
201084
201102
|
|
201085
201103
|
"use strict";
|
201086
201104
|
|
201087
201105
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
201088
|
-
const path_1 =
|
201089
|
-
const os_1 =
|
201090
|
-
const fs_extra_1 =
|
201106
|
+
const path_1 = __nested_webpack_require_849671__(5622);
|
201107
|
+
const os_1 = __nested_webpack_require_849671__(2087);
|
201108
|
+
const fs_extra_1 = __nested_webpack_require_849671__(5392);
|
201091
201109
|
async function getWritableDirectory() {
|
201092
201110
|
const name = Math.floor(Math.random() * 0x7fffffff).toString(16);
|
201093
201111
|
const directory = path_1.join(os_1.tmpdir(), name);
|
@@ -201100,7 +201118,7 @@ exports.default = getWritableDirectory;
|
|
201100
201118
|
/***/ }),
|
201101
201119
|
|
201102
201120
|
/***/ 4240:
|
201103
|
-
/***/ (function(__unused_webpack_module, exports,
|
201121
|
+
/***/ (function(__unused_webpack_module, exports, __nested_webpack_require_850251__) {
|
201104
201122
|
|
201105
201123
|
"use strict";
|
201106
201124
|
|
@@ -201108,13 +201126,13 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
201108
201126
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
201109
201127
|
};
|
201110
201128
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
201111
|
-
const path_1 = __importDefault(
|
201112
|
-
const assert_1 = __importDefault(
|
201113
|
-
const glob_1 = __importDefault(
|
201114
|
-
const util_1 =
|
201115
|
-
const fs_extra_1 =
|
201116
|
-
const normalize_path_1 =
|
201117
|
-
const file_fs_ref_1 = __importDefault(
|
201129
|
+
const path_1 = __importDefault(__nested_webpack_require_850251__(5622));
|
201130
|
+
const assert_1 = __importDefault(__nested_webpack_require_850251__(2357));
|
201131
|
+
const glob_1 = __importDefault(__nested_webpack_require_850251__(1104));
|
201132
|
+
const util_1 = __nested_webpack_require_850251__(1669);
|
201133
|
+
const fs_extra_1 = __nested_webpack_require_850251__(5392);
|
201134
|
+
const normalize_path_1 = __nested_webpack_require_850251__(6261);
|
201135
|
+
const file_fs_ref_1 = __importDefault(__nested_webpack_require_850251__(9331));
|
201118
201136
|
const vanillaGlob = util_1.promisify(glob_1.default);
|
201119
201137
|
async function glob(pattern, opts, mountpoint) {
|
201120
201138
|
let options;
|
@@ -201160,7 +201178,7 @@ exports.default = glob;
|
|
201160
201178
|
/***/ }),
|
201161
201179
|
|
201162
201180
|
/***/ 7903:
|
201163
|
-
/***/ (function(__unused_webpack_module, exports,
|
201181
|
+
/***/ (function(__unused_webpack_module, exports, __nested_webpack_require_852447__) {
|
201164
201182
|
|
201165
201183
|
"use strict";
|
201166
201184
|
|
@@ -201169,9 +201187,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
201169
201187
|
};
|
201170
201188
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
201171
201189
|
exports.getSupportedNodeVersion = exports.getDiscontinuedNodeVersions = exports.getLatestNodeVersion = void 0;
|
201172
|
-
const semver_1 =
|
201173
|
-
const errors_1 =
|
201174
|
-
const debug_1 = __importDefault(
|
201190
|
+
const semver_1 = __nested_webpack_require_852447__(2879);
|
201191
|
+
const errors_1 = __nested_webpack_require_852447__(3983);
|
201192
|
+
const debug_1 = __importDefault(__nested_webpack_require_852447__(1868));
|
201175
201193
|
const allOptions = [
|
201176
201194
|
{ major: 16, range: '16.x', runtime: 'nodejs16.x' },
|
201177
201195
|
{ major: 14, range: '14.x', runtime: 'nodejs14.x' },
|
@@ -201270,7 +201288,7 @@ exports.normalizePath = normalizePath;
|
|
201270
201288
|
/***/ }),
|
201271
201289
|
|
201272
201290
|
/***/ 7792:
|
201273
|
-
/***/ (function(__unused_webpack_module, exports,
|
201291
|
+
/***/ (function(__unused_webpack_module, exports, __nested_webpack_require_856301__) {
|
201274
201292
|
|
201275
201293
|
"use strict";
|
201276
201294
|
|
@@ -201279,9 +201297,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
201279
201297
|
};
|
201280
201298
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
201281
201299
|
exports.readConfigFile = void 0;
|
201282
|
-
const js_yaml_1 = __importDefault(
|
201283
|
-
const toml_1 = __importDefault(
|
201284
|
-
const fs_extra_1 =
|
201300
|
+
const js_yaml_1 = __importDefault(__nested_webpack_require_856301__(6540));
|
201301
|
+
const toml_1 = __importDefault(__nested_webpack_require_856301__(9434));
|
201302
|
+
const fs_extra_1 = __nested_webpack_require_856301__(5392);
|
201285
201303
|
async function readFileOrNull(file) {
|
201286
201304
|
try {
|
201287
201305
|
const data = await fs_extra_1.readFile(file);
|
@@ -201336,7 +201354,7 @@ exports.default = rename;
|
|
201336
201354
|
/***/ }),
|
201337
201355
|
|
201338
201356
|
/***/ 1442:
|
201339
|
-
/***/ (function(__unused_webpack_module, exports,
|
201357
|
+
/***/ (function(__unused_webpack_module, exports, __nested_webpack_require_858094__) {
|
201340
201358
|
|
201341
201359
|
"use strict";
|
201342
201360
|
|
@@ -201345,17 +201363,17 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
201345
201363
|
};
|
201346
201364
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
201347
201365
|
exports.installDependencies = exports.getScriptName = exports.runPipInstall = exports.runBundleInstall = exports.runPackageJsonScript = exports.runCustomInstallCommand = exports.getEnvForPackageManager = exports.runNpmInstall = exports.walkParentDirs = exports.scanParentDirs = exports.getNodeVersion = exports.getSpawnOptions = exports.runShellScript = exports.getNodeBinPath = exports.execCommand = exports.spawnCommand = exports.execAsync = exports.spawnAsync = void 0;
|
201348
|
-
const assert_1 = __importDefault(
|
201349
|
-
const fs_extra_1 = __importDefault(
|
201350
|
-
const path_1 = __importDefault(
|
201351
|
-
const async_sema_1 = __importDefault(
|
201352
|
-
const cross_spawn_1 = __importDefault(
|
201353
|
-
const semver_1 =
|
201354
|
-
const util_1 =
|
201355
|
-
const debug_1 = __importDefault(
|
201356
|
-
const errors_1 =
|
201357
|
-
const node_version_1 =
|
201358
|
-
const read_config_file_1 =
|
201366
|
+
const assert_1 = __importDefault(__nested_webpack_require_858094__(2357));
|
201367
|
+
const fs_extra_1 = __importDefault(__nested_webpack_require_858094__(5392));
|
201368
|
+
const path_1 = __importDefault(__nested_webpack_require_858094__(5622));
|
201369
|
+
const async_sema_1 = __importDefault(__nested_webpack_require_858094__(5758));
|
201370
|
+
const cross_spawn_1 = __importDefault(__nested_webpack_require_858094__(7618));
|
201371
|
+
const semver_1 = __nested_webpack_require_858094__(2879);
|
201372
|
+
const util_1 = __nested_webpack_require_858094__(1669);
|
201373
|
+
const debug_1 = __importDefault(__nested_webpack_require_858094__(1868));
|
201374
|
+
const errors_1 = __nested_webpack_require_858094__(3983);
|
201375
|
+
const node_version_1 = __nested_webpack_require_858094__(7903);
|
201376
|
+
const read_config_file_1 = __nested_webpack_require_858094__(7792);
|
201359
201377
|
// Only allow one `runNpmInstall()` invocation to run concurrently
|
201360
201378
|
const runNpmInstallSema = new async_sema_1.default(1);
|
201361
201379
|
function spawnAsync(command, args, opts = {}) {
|
@@ -201807,7 +201825,7 @@ exports.installDependencies = util_1.deprecate(runNpmInstall, 'installDependenci
|
|
201807
201825
|
/***/ }),
|
201808
201826
|
|
201809
201827
|
/***/ 2560:
|
201810
|
-
/***/ (function(__unused_webpack_module, exports,
|
201828
|
+
/***/ (function(__unused_webpack_module, exports, __nested_webpack_require_877201__) {
|
201811
201829
|
|
201812
201830
|
"use strict";
|
201813
201831
|
|
@@ -201815,7 +201833,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
201815
201833
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
201816
201834
|
};
|
201817
201835
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
201818
|
-
const end_of_stream_1 = __importDefault(
|
201836
|
+
const end_of_stream_1 = __importDefault(__nested_webpack_require_877201__(687));
|
201819
201837
|
function streamToBuffer(stream) {
|
201820
201838
|
return new Promise((resolve, reject) => {
|
201821
201839
|
const buffers = [];
|
@@ -201844,7 +201862,7 @@ exports.default = streamToBuffer;
|
|
201844
201862
|
/***/ }),
|
201845
201863
|
|
201846
201864
|
/***/ 1148:
|
201847
|
-
/***/ (function(__unused_webpack_module, exports,
|
201865
|
+
/***/ (function(__unused_webpack_module, exports, __nested_webpack_require_878269__) {
|
201848
201866
|
|
201849
201867
|
"use strict";
|
201850
201868
|
|
@@ -201852,9 +201870,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
201852
201870
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
201853
201871
|
};
|
201854
201872
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
201855
|
-
const path_1 = __importDefault(
|
201856
|
-
const fs_extra_1 = __importDefault(
|
201857
|
-
const ignore_1 = __importDefault(
|
201873
|
+
const path_1 = __importDefault(__nested_webpack_require_878269__(5622));
|
201874
|
+
const fs_extra_1 = __importDefault(__nested_webpack_require_878269__(5392));
|
201875
|
+
const ignore_1 = __importDefault(__nested_webpack_require_878269__(3556));
|
201858
201876
|
function isCodedError(error) {
|
201859
201877
|
return (error !== null &&
|
201860
201878
|
error !== undefined &&
|
@@ -201911,13 +201929,13 @@ exports.default = default_1;
|
|
201911
201929
|
/***/ }),
|
201912
201930
|
|
201913
201931
|
/***/ 4678:
|
201914
|
-
/***/ ((__unused_webpack_module, exports,
|
201932
|
+
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_880643__) => {
|
201915
201933
|
|
201916
201934
|
"use strict";
|
201917
201935
|
|
201918
201936
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
201919
201937
|
exports.getPlatformEnv = void 0;
|
201920
|
-
const errors_1 =
|
201938
|
+
const errors_1 = __nested_webpack_require_880643__(3983);
|
201921
201939
|
/**
|
201922
201940
|
* Helper function to support both `VERCEL_` and legacy `NOW_` env vars.
|
201923
201941
|
* Throws an error if *both* env vars are defined.
|
@@ -201945,7 +201963,7 @@ exports.getPlatformEnv = getPlatformEnv;
|
|
201945
201963
|
/***/ }),
|
201946
201964
|
|
201947
201965
|
/***/ 2855:
|
201948
|
-
/***/ (function(__unused_webpack_module, exports,
|
201966
|
+
/***/ (function(__unused_webpack_module, exports, __nested_webpack_require_881680__) {
|
201949
201967
|
|
201950
201968
|
"use strict";
|
201951
201969
|
|
@@ -201975,31 +201993,32 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
201975
201993
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
201976
201994
|
};
|
201977
201995
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
201978
|
-
exports.normalizePath = exports.readConfigFile = exports.EdgeFunction = exports.getIgnoreFilter = exports.scanParentDirs = exports.getLambdaOptionsFromFunction = exports.isSymbolicLink = exports.debug = exports.streamToBuffer = exports.getPlatformEnv = exports.getSpawnOptions = exports.getDiscontinuedNodeVersions = exports.getLatestNodeVersion = exports.getNodeVersion = exports.getEnvForPackageManager = exports.runCustomInstallCommand = exports.runShellScript = exports.runPipInstall = exports.runBundleInstall = exports.runNpmInstall = exports.getNodeBinPath = exports.walkParentDirs = exports.spawnCommand = exports.execCommand = exports.runPackageJsonScript = exports.installDependencies = exports.getScriptName = exports.spawnAsync = exports.execAsync = exports.rename = exports.glob = exports.getWriteableDirectory = exports.download = exports.Prerender = exports.createLambda = exports.NodejsLambda = exports.Lambda = exports.FileRef = exports.FileFsRef = exports.FileBlob = void 0;
|
201979
|
-
const file_blob_1 = __importDefault(
|
201996
|
+
exports.normalizePath = exports.readConfigFile = exports.EdgeFunction = exports.getIgnoreFilter = exports.scanParentDirs = exports.getLambdaOptionsFromFunction = exports.isSymbolicLink = exports.debug = exports.streamToBuffer = exports.getPlatformEnv = exports.getSpawnOptions = exports.getDiscontinuedNodeVersions = exports.getLatestNodeVersion = exports.getNodeVersion = exports.getEnvForPackageManager = exports.runCustomInstallCommand = exports.runShellScript = exports.runPipInstall = exports.runBundleInstall = exports.runNpmInstall = exports.getNodeBinPath = exports.walkParentDirs = exports.spawnCommand = exports.execCommand = exports.runPackageJsonScript = exports.installDependencies = exports.getScriptName = exports.spawnAsync = exports.execAsync = exports.rename = exports.glob = exports.getWriteableDirectory = exports.downloadFile = exports.download = exports.Prerender = exports.createLambda = exports.NodejsLambda = exports.Lambda = exports.FileRef = exports.FileFsRef = exports.FileBlob = void 0;
|
201997
|
+
const file_blob_1 = __importDefault(__nested_webpack_require_881680__(2397));
|
201980
201998
|
exports.FileBlob = file_blob_1.default;
|
201981
|
-
const file_fs_ref_1 = __importDefault(
|
201999
|
+
const file_fs_ref_1 = __importDefault(__nested_webpack_require_881680__(9331));
|
201982
202000
|
exports.FileFsRef = file_fs_ref_1.default;
|
201983
|
-
const file_ref_1 = __importDefault(
|
202001
|
+
const file_ref_1 = __importDefault(__nested_webpack_require_881680__(5187));
|
201984
202002
|
exports.FileRef = file_ref_1.default;
|
201985
|
-
const lambda_1 =
|
202003
|
+
const lambda_1 = __nested_webpack_require_881680__(6721);
|
201986
202004
|
Object.defineProperty(exports, "Lambda", ({ enumerable: true, get: function () { return lambda_1.Lambda; } }));
|
201987
202005
|
Object.defineProperty(exports, "createLambda", ({ enumerable: true, get: function () { return lambda_1.createLambda; } }));
|
201988
202006
|
Object.defineProperty(exports, "getLambdaOptionsFromFunction", ({ enumerable: true, get: function () { return lambda_1.getLambdaOptionsFromFunction; } }));
|
201989
|
-
const nodejs_lambda_1 =
|
202007
|
+
const nodejs_lambda_1 = __nested_webpack_require_881680__(7049);
|
201990
202008
|
Object.defineProperty(exports, "NodejsLambda", ({ enumerable: true, get: function () { return nodejs_lambda_1.NodejsLambda; } }));
|
201991
|
-
const prerender_1 =
|
202009
|
+
const prerender_1 = __nested_webpack_require_881680__(2850);
|
201992
202010
|
Object.defineProperty(exports, "Prerender", ({ enumerable: true, get: function () { return prerender_1.Prerender; } }));
|
201993
|
-
const download_1 = __importStar(
|
202011
|
+
const download_1 = __importStar(__nested_webpack_require_881680__(1611));
|
201994
202012
|
exports.download = download_1.default;
|
202013
|
+
Object.defineProperty(exports, "downloadFile", ({ enumerable: true, get: function () { return download_1.downloadFile; } }));
|
201995
202014
|
Object.defineProperty(exports, "isSymbolicLink", ({ enumerable: true, get: function () { return download_1.isSymbolicLink; } }));
|
201996
|
-
const get_writable_directory_1 = __importDefault(
|
202015
|
+
const get_writable_directory_1 = __importDefault(__nested_webpack_require_881680__(3838));
|
201997
202016
|
exports.getWriteableDirectory = get_writable_directory_1.default;
|
201998
|
-
const glob_1 = __importDefault(
|
202017
|
+
const glob_1 = __importDefault(__nested_webpack_require_881680__(4240));
|
201999
202018
|
exports.glob = glob_1.default;
|
202000
|
-
const rename_1 = __importDefault(
|
202019
|
+
const rename_1 = __importDefault(__nested_webpack_require_881680__(6718));
|
202001
202020
|
exports.rename = rename_1.default;
|
202002
|
-
const run_user_scripts_1 =
|
202021
|
+
const run_user_scripts_1 = __nested_webpack_require_881680__(1442);
|
202003
202022
|
Object.defineProperty(exports, "execAsync", ({ enumerable: true, get: function () { return run_user_scripts_1.execAsync; } }));
|
202004
202023
|
Object.defineProperty(exports, "spawnAsync", ({ enumerable: true, get: function () { return run_user_scripts_1.spawnAsync; } }));
|
202005
202024
|
Object.defineProperty(exports, "execCommand", ({ enumerable: true, get: function () { return run_user_scripts_1.execCommand; } }));
|
@@ -202018,33 +202037,33 @@ Object.defineProperty(exports, "getNodeVersion", ({ enumerable: true, get: funct
|
|
202018
202037
|
Object.defineProperty(exports, "getSpawnOptions", ({ enumerable: true, get: function () { return run_user_scripts_1.getSpawnOptions; } }));
|
202019
202038
|
Object.defineProperty(exports, "getNodeBinPath", ({ enumerable: true, get: function () { return run_user_scripts_1.getNodeBinPath; } }));
|
202020
202039
|
Object.defineProperty(exports, "scanParentDirs", ({ enumerable: true, get: function () { return run_user_scripts_1.scanParentDirs; } }));
|
202021
|
-
const node_version_1 =
|
202040
|
+
const node_version_1 = __nested_webpack_require_881680__(7903);
|
202022
202041
|
Object.defineProperty(exports, "getLatestNodeVersion", ({ enumerable: true, get: function () { return node_version_1.getLatestNodeVersion; } }));
|
202023
202042
|
Object.defineProperty(exports, "getDiscontinuedNodeVersions", ({ enumerable: true, get: function () { return node_version_1.getDiscontinuedNodeVersions; } }));
|
202024
|
-
const stream_to_buffer_1 = __importDefault(
|
202043
|
+
const stream_to_buffer_1 = __importDefault(__nested_webpack_require_881680__(2560));
|
202025
202044
|
exports.streamToBuffer = stream_to_buffer_1.default;
|
202026
|
-
const debug_1 = __importDefault(
|
202045
|
+
const debug_1 = __importDefault(__nested_webpack_require_881680__(1868));
|
202027
202046
|
exports.debug = debug_1.default;
|
202028
|
-
const get_ignore_filter_1 = __importDefault(
|
202047
|
+
const get_ignore_filter_1 = __importDefault(__nested_webpack_require_881680__(1148));
|
202029
202048
|
exports.getIgnoreFilter = get_ignore_filter_1.default;
|
202030
|
-
const get_platform_env_1 =
|
202049
|
+
const get_platform_env_1 = __nested_webpack_require_881680__(4678);
|
202031
202050
|
Object.defineProperty(exports, "getPlatformEnv", ({ enumerable: true, get: function () { return get_platform_env_1.getPlatformEnv; } }));
|
202032
|
-
var edge_function_1 =
|
202051
|
+
var edge_function_1 = __nested_webpack_require_881680__(8038);
|
202033
202052
|
Object.defineProperty(exports, "EdgeFunction", ({ enumerable: true, get: function () { return edge_function_1.EdgeFunction; } }));
|
202034
|
-
var read_config_file_1 =
|
202053
|
+
var read_config_file_1 = __nested_webpack_require_881680__(7792);
|
202035
202054
|
Object.defineProperty(exports, "readConfigFile", ({ enumerable: true, get: function () { return read_config_file_1.readConfigFile; } }));
|
202036
|
-
var normalize_path_1 =
|
202055
|
+
var normalize_path_1 = __nested_webpack_require_881680__(6261);
|
202037
202056
|
Object.defineProperty(exports, "normalizePath", ({ enumerable: true, get: function () { return normalize_path_1.normalizePath; } }));
|
202038
|
-
__exportStar(
|
202039
|
-
__exportStar(
|
202040
|
-
__exportStar(
|
202041
|
-
__exportStar(
|
202057
|
+
__exportStar(__nested_webpack_require_881680__(2564), exports);
|
202058
|
+
__exportStar(__nested_webpack_require_881680__(2416), exports);
|
202059
|
+
__exportStar(__nested_webpack_require_881680__(5748), exports);
|
202060
|
+
__exportStar(__nested_webpack_require_881680__(3983), exports);
|
202042
202061
|
|
202043
202062
|
|
202044
202063
|
/***/ }),
|
202045
202064
|
|
202046
202065
|
/***/ 6721:
|
202047
|
-
/***/ (function(__unused_webpack_module, exports,
|
202066
|
+
/***/ (function(__unused_webpack_module, exports, __nested_webpack_require_890074__) {
|
202048
202067
|
|
202049
202068
|
"use strict";
|
202050
202069
|
|
@@ -202053,13 +202072,13 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
202053
202072
|
};
|
202054
202073
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
202055
202074
|
exports.getLambdaOptionsFromFunction = exports.createZip = exports.createLambda = exports.Lambda = void 0;
|
202056
|
-
const assert_1 = __importDefault(
|
202057
|
-
const async_sema_1 = __importDefault(
|
202058
|
-
const yazl_1 =
|
202059
|
-
const minimatch_1 = __importDefault(
|
202060
|
-
const fs_extra_1 =
|
202061
|
-
const download_1 =
|
202062
|
-
const stream_to_buffer_1 = __importDefault(
|
202075
|
+
const assert_1 = __importDefault(__nested_webpack_require_890074__(2357));
|
202076
|
+
const async_sema_1 = __importDefault(__nested_webpack_require_890074__(5758));
|
202077
|
+
const yazl_1 = __nested_webpack_require_890074__(1223);
|
202078
|
+
const minimatch_1 = __importDefault(__nested_webpack_require_890074__(9566));
|
202079
|
+
const fs_extra_1 = __nested_webpack_require_890074__(5392);
|
202080
|
+
const download_1 = __nested_webpack_require_890074__(1611);
|
202081
|
+
const stream_to_buffer_1 = __importDefault(__nested_webpack_require_890074__(2560));
|
202063
202082
|
class Lambda {
|
202064
202083
|
constructor(opts) {
|
202065
202084
|
const { handler, runtime, maxDuration, memory, environment = {}, allowQuery, regions, supportsMultiPayloads, } = opts;
|
@@ -202181,13 +202200,13 @@ exports.getLambdaOptionsFromFunction = getLambdaOptionsFromFunction;
|
|
202181
202200
|
/***/ }),
|
202182
202201
|
|
202183
202202
|
/***/ 7049:
|
202184
|
-
/***/ ((__unused_webpack_module, exports,
|
202203
|
+
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_895531__) => {
|
202185
202204
|
|
202186
202205
|
"use strict";
|
202187
202206
|
|
202188
202207
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
202189
202208
|
exports.NodejsLambda = void 0;
|
202190
|
-
const lambda_1 =
|
202209
|
+
const lambda_1 = __nested_webpack_require_895531__(6721);
|
202191
202210
|
class NodejsLambda extends lambda_1.Lambda {
|
202192
202211
|
constructor({ shouldAddHelpers, shouldAddSourcemapSupport, awsLambdaHandler, ...opts }) {
|
202193
202212
|
super(opts);
|
@@ -202324,13 +202343,13 @@ exports.buildsSchema = {
|
|
202324
202343
|
/***/ }),
|
202325
202344
|
|
202326
202345
|
/***/ 2564:
|
202327
|
-
/***/ ((__unused_webpack_module, exports,
|
202346
|
+
/***/ ((__unused_webpack_module, exports, __nested_webpack_require_899876__) => {
|
202328
202347
|
|
202329
202348
|
"use strict";
|
202330
202349
|
|
202331
202350
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
202332
202351
|
exports.shouldServe = void 0;
|
202333
|
-
const path_1 =
|
202352
|
+
const path_1 = __nested_webpack_require_899876__(5622);
|
202334
202353
|
const shouldServe = ({ entrypoint, files, requestPath, }) => {
|
202335
202354
|
requestPath = requestPath.replace(/\/$/, ''); // sanitize trailing '/'
|
202336
202355
|
entrypoint = entrypoint.replace(/\\/, '/'); // windows compatibility
|
@@ -202575,7 +202594,7 @@ module.exports = __webpack_require__(78761);
|
|
202575
202594
|
/******/ var __webpack_module_cache__ = {};
|
202576
202595
|
/******/
|
202577
202596
|
/******/ // The require function
|
202578
|
-
/******/ function
|
202597
|
+
/******/ function __nested_webpack_require_1277241__(moduleId) {
|
202579
202598
|
/******/ // Check if module is in cache
|
202580
202599
|
/******/ if(__webpack_module_cache__[moduleId]) {
|
202581
202600
|
/******/ return __webpack_module_cache__[moduleId].exports;
|
@@ -202590,7 +202609,7 @@ module.exports = __webpack_require__(78761);
|
|
202590
202609
|
/******/ // Execute the module function
|
202591
202610
|
/******/ var threw = true;
|
202592
202611
|
/******/ try {
|
202593
|
-
/******/ __webpack_modules__[moduleId].call(module.exports, module, module.exports,
|
202612
|
+
/******/ __webpack_modules__[moduleId].call(module.exports, module, module.exports, __nested_webpack_require_1277241__);
|
202594
202613
|
/******/ threw = false;
|
202595
202614
|
/******/ } finally {
|
202596
202615
|
/******/ if(threw) delete __webpack_module_cache__[moduleId];
|
@@ -202603,11 +202622,11 @@ module.exports = __webpack_require__(78761);
|
|
202603
202622
|
/************************************************************************/
|
202604
202623
|
/******/ /* webpack/runtime/compat */
|
202605
202624
|
/******/
|
202606
|
-
/******/
|
202625
|
+
/******/ __nested_webpack_require_1277241__.ab = __dirname + "/";/************************************************************************/
|
202607
202626
|
/******/ // module exports must be returned from runtime so entry inlining is disabled
|
202608
202627
|
/******/ // startup
|
202609
202628
|
/******/ // Load entry module and return exports
|
202610
|
-
/******/ return
|
202629
|
+
/******/ return __nested_webpack_require_1277241__(2855);
|
202611
202630
|
/******/ })()
|
202612
202631
|
;
|
202613
202632
|
|
@@ -227212,7 +227231,7 @@ exports.detectOutputDirectory = detectOutputDirectory;
|
|
227212
227231
|
async function detectBuilders(files, pkg, options = {}) {
|
227213
227232
|
const errors = [];
|
227214
227233
|
const warnings = [];
|
227215
|
-
|
227234
|
+
let apiBuilders = [];
|
227216
227235
|
let frontendBuilder = null;
|
227217
227236
|
const functionError = validateFunctions(options);
|
227218
227237
|
if (functionError) {
|
@@ -227367,6 +227386,20 @@ async function detectBuilders(files, pkg, options = {}) {
|
|
227367
227386
|
limitedRoutes: null,
|
227368
227387
|
};
|
227369
227388
|
}
|
227389
|
+
// Exclude the middleware builder for Next.js apps since @vercel/next
|
227390
|
+
// will build middlewares.
|
227391
|
+
//
|
227392
|
+
// While maybeGetApiBuilder() excludes the middleware builder, however,
|
227393
|
+
// we need to check if it's a Next.js app here again for the case where
|
227394
|
+
// `projectSettings.framework == null`.
|
227395
|
+
if (framework === null &&
|
227396
|
+
frontendBuilder?.use === '@vercel/next' &&
|
227397
|
+
apiBuilders.length > 0) {
|
227398
|
+
apiBuilders = apiBuilders.filter(builder => {
|
227399
|
+
const isMiddlewareBuilder = builder.use === '@vercel/node' && builder.config?.middleware;
|
227400
|
+
return !isMiddlewareBuilder;
|
227401
|
+
});
|
227402
|
+
}
|
227370
227403
|
const builders = [];
|
227371
227404
|
if (apiBuilders.length) {
|
227372
227405
|
builders.push(...apiBuilders);
|
@@ -239138,6 +239171,7 @@ async function doBuild(client, project, buildsJson, cwd, outputDir) {
|
|
239138
239171
|
}, err => err));
|
239139
239172
|
}
|
239140
239173
|
catch (err) {
|
239174
|
+
output.prettyError(err);
|
239141
239175
|
const writeConfigJsonPromise = fs_extra_1.default.writeJSON((0, path_1.join)(outputDir, 'config.json'), { version: 3 }, { spaces: 2 });
|
239142
239176
|
await Promise.all([writeBuildsJsonPromise, writeConfigJsonPromise]);
|
239143
239177
|
const buildJsonBuild = buildsJsonBuilds.get(build);
|
@@ -242590,14 +242624,13 @@ async function pull(client, project, environment, opts, args, output, cwd, sourc
|
|
242590
242624
|
.join('\n') +
|
242591
242625
|
'\n';
|
242592
242626
|
await (0, fs_extra_1.outputFile)(fullPath, contents, 'utf8');
|
242593
|
-
output.print(`${(0, emoji_1.prependEmoji)(`${exists ? 'Updated' : 'Created'} ${chalk_1.default.bold(filename)} file ${chalk_1.default.gray(pullStamp())}`, (0, emoji_1.emoji)('success'))}\n`);
|
242594
|
-
output.print('\n');
|
242595
242627
|
if (deltaString) {
|
242596
|
-
output.print(deltaString);
|
242628
|
+
output.print('\n' + deltaString);
|
242597
242629
|
}
|
242598
242630
|
else if (oldEnv && exists) {
|
242599
242631
|
output.log('No changes found.');
|
242600
242632
|
}
|
242633
|
+
output.print(`${(0, emoji_1.prependEmoji)(`${exists ? 'Updated' : 'Created'} ${chalk_1.default.bold(filename)} file ${chalk_1.default.gray(pullStamp())}`, (0, emoji_1.emoji)('success'))}\n`);
|
242601
242634
|
return 0;
|
242602
242635
|
}
|
242603
242636
|
exports.default = pull;
|
@@ -243300,6 +243333,7 @@ const get_deployment_1 = __webpack_require__(34518);
|
|
243300
243333
|
const title_1 = __importDefault(__webpack_require__(45676));
|
243301
243334
|
const is_error_1 = __webpack_require__(11026);
|
243302
243335
|
const errors_ts_1 = __webpack_require__(60156);
|
243336
|
+
const url_1 = __webpack_require__(78835);
|
243303
243337
|
const help = () => {
|
243304
243338
|
console.log(`
|
243305
243339
|
${chalk_1.default.bold(`${logo_1.default} ${(0, pkg_name_1.getPkgName)()} inspect`)} <url>
|
@@ -243340,7 +243374,7 @@ async function main(client) {
|
|
243340
243374
|
}
|
243341
243375
|
const { print, log, error } = client.output;
|
243342
243376
|
// extract the first parameter
|
243343
|
-
|
243377
|
+
let [, deploymentIdOrHost] = argv._;
|
243344
243378
|
if (argv._.length !== 2) {
|
243345
243379
|
error(`${(0, pkg_name_1.getCommandName)('inspect <url>')} expects exactly one argument`);
|
243346
243380
|
help();
|
@@ -243358,9 +243392,13 @@ async function main(client) {
|
|
243358
243392
|
}
|
243359
243393
|
throw err;
|
243360
243394
|
}
|
243361
|
-
// resolve the deployment, since we might have been given an alias
|
243362
243395
|
const depFetchStart = Date.now();
|
243396
|
+
try {
|
243397
|
+
deploymentIdOrHost = new url_1.URL(deploymentIdOrHost).hostname;
|
243398
|
+
}
|
243399
|
+
catch { }
|
243363
243400
|
client.output.spinner(`Fetching deployment "${deploymentIdOrHost}" in ${chalk_1.default.bold(contextName)}`);
|
243401
|
+
// resolve the deployment, since we might have been given an alias
|
243364
243402
|
try {
|
243365
243403
|
deployment = await (0, get_deployment_1.getDeployment)(client, deploymentIdOrHost);
|
243366
243404
|
}
|
@@ -245851,107 +245889,48 @@ const main = async () => {
|
|
245851
245889
|
}
|
245852
245890
|
catch (err) {
|
245853
245891
|
output.error(`An unexpected error occurred while trying to create the global directory "${(0, humanize_path_1.default)(VERCEL_DIR)}" ${(0, is_error_1.errorToString)(err)}`);
|
245892
|
+
return 1;
|
245854
245893
|
}
|
245855
|
-
let
|
245856
|
-
let configExists;
|
245894
|
+
let config;
|
245857
245895
|
try {
|
245858
|
-
|
245896
|
+
config = configFiles.readConfigFile();
|
245859
245897
|
}
|
245860
245898
|
catch (err) {
|
245861
|
-
|
245862
|
-
|
245863
|
-
|
245864
|
-
|
245865
|
-
|
245866
|
-
|
245867
|
-
|
245868
|
-
|
245869
|
-
|
245870
|
-
catch (err) {
|
245871
|
-
console.error((0, error_1.default)(`${'An unexpected error occurred while trying to read the ' +
|
245872
|
-
`config in "${(0, humanize_path_1.default)(VERCEL_CONFIG_PATH)}" `}${(0, is_error_1.errorToString)(err)}`));
|
245873
|
-
return 1;
|
245874
|
-
}
|
245875
|
-
// This is from when Vercel CLI supported
|
245876
|
-
// multiple providers. In that case, we really
|
245877
|
-
// need to migrate.
|
245878
|
-
if (
|
245879
|
-
// @ts-ignore
|
245880
|
-
config.sh ||
|
245881
|
-
// @ts-ignore
|
245882
|
-
config.user ||
|
245883
|
-
// @ts-ignore
|
245884
|
-
typeof config.user === 'object' ||
|
245885
|
-
typeof config.currentTeam === 'object') {
|
245886
|
-
configExists = false;
|
245887
|
-
}
|
245888
|
-
}
|
245889
|
-
if (!configExists) {
|
245890
|
-
const results = await (0, get_default_1.getDefaultConfig)(config);
|
245891
|
-
config = results.config;
|
245892
|
-
migrated = results.migrated;
|
245893
|
-
try {
|
245894
|
-
configFiles.writeToConfigFile(config);
|
245899
|
+
if ((0, is_error_1.isErrnoException)(err) && err.code === 'ENOENT') {
|
245900
|
+
config = get_default_1.defaultGlobalConfig;
|
245901
|
+
try {
|
245902
|
+
configFiles.writeToConfigFile(config);
|
245903
|
+
}
|
245904
|
+
catch (err) {
|
245905
|
+
output.error(`An unexpected error occurred while trying to save the config to "${(0, humanize_path_1.default)(VERCEL_CONFIG_PATH)}" ${(0, is_error_1.errorToString)(err)}`);
|
245906
|
+
return 1;
|
245907
|
+
}
|
245895
245908
|
}
|
245896
|
-
|
245897
|
-
|
245898
|
-
`default config to "${(0, humanize_path_1.default)(VERCEL_CONFIG_PATH)}" `}${(0, is_error_1.errorToString)(err)}`));
|
245909
|
+
else {
|
245910
|
+
output.error(`An unexpected error occurred while trying to read the config in "${(0, humanize_path_1.default)(VERCEL_CONFIG_PATH)}" ${(0, is_error_1.errorToString)(err)}`);
|
245899
245911
|
return 1;
|
245900
245912
|
}
|
245901
245913
|
}
|
245902
|
-
let
|
245914
|
+
let authConfig;
|
245903
245915
|
try {
|
245904
|
-
|
245916
|
+
authConfig = configFiles.readAuthConfigFile();
|
245905
245917
|
}
|
245906
245918
|
catch (err) {
|
245907
|
-
|
245908
|
-
|
245909
|
-
|
245910
|
-
|
245911
|
-
|
245912
|
-
|
245913
|
-
|
245914
|
-
|
245915
|
-
|
245916
|
-
'init',
|
245917
|
-
'update',
|
245918
|
-
'build',
|
245919
|
-
];
|
245920
|
-
if (authConfigExists) {
|
245921
|
-
try {
|
245922
|
-
authConfig = configFiles.readAuthConfigFile();
|
245923
|
-
}
|
245924
|
-
catch (err) {
|
245925
|
-
console.error((0, error_1.default)(`${'An unexpected error occurred while trying to read the ' +
|
245926
|
-
`auth config in "${(0, humanize_path_1.default)(VERCEL_AUTH_CONFIG_PATH)}" `}${(0, is_error_1.errorToString)(err)}`));
|
245927
|
-
return 1;
|
245928
|
-
}
|
245929
|
-
// This is from when Vercel CLI supported
|
245930
|
-
// multiple providers. In that case, we really
|
245931
|
-
// need to migrate.
|
245932
|
-
// @ts-ignore
|
245933
|
-
if (authConfig.credentials) {
|
245934
|
-
authConfigExists = false;
|
245935
|
-
}
|
245936
|
-
}
|
245937
|
-
else {
|
245938
|
-
const results = await (0, get_default_1.getDefaultAuthConfig)(authConfig);
|
245939
|
-
authConfig = results.config;
|
245940
|
-
migrated = results.migrated;
|
245941
|
-
try {
|
245942
|
-
configFiles.writeToAuthConfigFile(authConfig);
|
245919
|
+
if ((0, is_error_1.isErrnoException)(err) && err.code === 'ENOENT') {
|
245920
|
+
authConfig = get_default_1.defaultAuthConfig;
|
245921
|
+
try {
|
245922
|
+
configFiles.writeToAuthConfigFile(authConfig);
|
245923
|
+
}
|
245924
|
+
catch (err) {
|
245925
|
+
output.error(`An unexpected error occurred while trying to write the auth config to "${(0, humanize_path_1.default)(VERCEL_AUTH_CONFIG_PATH)}" ${(0, is_error_1.errorToString)(err)}`);
|
245926
|
+
return 1;
|
245927
|
+
}
|
245943
245928
|
}
|
245944
|
-
|
245945
|
-
|
245946
|
-
`default config to "${(0, humanize_path_1.default)(VERCEL_AUTH_CONFIG_PATH)}" `}${(0, is_error_1.errorToString)(err)}`));
|
245929
|
+
else {
|
245930
|
+
output.error(`An unexpected error occurred while trying to read the auth config in "${(0, humanize_path_1.default)(VERCEL_AUTH_CONFIG_PATH)}" ${(0, is_error_1.errorToString)(err)}`);
|
245947
245931
|
return 1;
|
245948
245932
|
}
|
245949
245933
|
}
|
245950
|
-
// Let the user know we migrated the config
|
245951
|
-
if (migrated) {
|
245952
|
-
const directory = (0, param_1.default)((0, humanize_path_1.default)(VERCEL_DIR));
|
245953
|
-
debug(`The credentials and configuration within the ${directory} directory were upgraded`);
|
245954
|
-
}
|
245955
245934
|
if (typeof argv['--api'] === 'string') {
|
245956
245935
|
apiUrl = argv['--api'];
|
245957
245936
|
}
|
@@ -245959,17 +245938,12 @@ const main = async () => {
|
|
245959
245938
|
apiUrl = config.api;
|
245960
245939
|
}
|
245961
245940
|
try {
|
245962
|
-
// eslint-disable-next-line no-new
|
245963
245941
|
new url_1.URL(apiUrl);
|
245964
245942
|
}
|
245965
245943
|
catch (err) {
|
245966
245944
|
output.error(`Please provide a valid URL instead of ${(0, highlight_1.default)(apiUrl)}.`);
|
245967
245945
|
return 1;
|
245968
245946
|
}
|
245969
|
-
if (!config) {
|
245970
|
-
output.error(`Vercel global config was not loaded.`);
|
245971
|
-
return 1;
|
245972
|
-
}
|
245973
245947
|
// Shared API `Client` instance for all sub-commands to utilize
|
245974
245948
|
client = new client_1.default({
|
245975
245949
|
apiUrl,
|
@@ -246010,6 +245984,14 @@ const main = async () => {
|
|
246010
245984
|
subcommand = argv._[3] || 'deploy';
|
246011
245985
|
client.argv.push('-h');
|
246012
245986
|
}
|
245987
|
+
const subcommandsWithoutToken = [
|
245988
|
+
'login',
|
245989
|
+
'logout',
|
245990
|
+
'help',
|
245991
|
+
'init',
|
245992
|
+
'update',
|
245993
|
+
'build',
|
245994
|
+
];
|
246013
245995
|
// Prompt for login if there is no current token
|
246014
245996
|
if ((!authConfig || !authConfig.token) &&
|
246015
245997
|
!client.argv.includes('-h') &&
|
@@ -247348,9 +247330,7 @@ async function writeStaticFile(outputDir, file, path, overrides, cleanUrls = fal
|
|
247348
247330
|
}
|
247349
247331
|
const dest = (0, path_1.join)(outputDir, 'static', fsPath);
|
247350
247332
|
await fs_extra_1.default.mkdirp((0, path_1.dirname)(dest));
|
247351
|
-
|
247352
|
-
const stream = file.toStream();
|
247353
|
-
await (0, promisepipe_1.default)(stream, fs_extra_1.default.createWriteStream(dest, { mode: file.mode }));
|
247333
|
+
await (0, build_utils_1.downloadFile)(file, dest);
|
247354
247334
|
}
|
247355
247335
|
/**
|
247356
247336
|
* Serializes the `EdgeFunction` instance to the file system.
|
@@ -248476,69 +248456,16 @@ exports.readLocalConfig = readLocalConfig;
|
|
248476
248456
|
"use strict";
|
248477
248457
|
|
248478
248458
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
248479
|
-
exports.
|
248480
|
-
|
248481
|
-
|
248482
|
-
|
248483
|
-
|
248484
|
-
collectMetrics: true,
|
248485
|
-
};
|
248486
|
-
if (existingCopy) {
|
248487
|
-
const keep = [
|
248488
|
-
'_',
|
248489
|
-
'currentTeam',
|
248490
|
-
'desktop',
|
248491
|
-
'updateChannel',
|
248492
|
-
'collectMetrics',
|
248493
|
-
'api',
|
248494
|
-
// This is deleted later in the code
|
248495
|
-
];
|
248496
|
-
try {
|
248497
|
-
const existing = Object.assign({}, existingCopy);
|
248498
|
-
// @ts-ignore
|
248499
|
-
const sh = Object.assign({}, existing.sh || {});
|
248500
|
-
Object.assign(config, existing, sh);
|
248501
|
-
for (const key of Object.keys(config)) {
|
248502
|
-
if (!keep.includes(key)) {
|
248503
|
-
// @ts-ignore
|
248504
|
-
delete config[key];
|
248505
|
-
}
|
248506
|
-
}
|
248507
|
-
if (typeof config.currentTeam === 'object') {
|
248508
|
-
// @ts-ignore
|
248509
|
-
config.currentTeam = config.currentTeam.id;
|
248510
|
-
}
|
248511
|
-
// @ts-ignore
|
248512
|
-
if (typeof config.user === 'object') {
|
248513
|
-
// @ts-ignore
|
248514
|
-
config.user = config.user.uid || config.user.id;
|
248515
|
-
}
|
248516
|
-
migrated = true;
|
248517
|
-
}
|
248518
|
-
catch (err) { }
|
248519
|
-
}
|
248520
|
-
return { config, migrated };
|
248459
|
+
exports.defaultAuthConfig = exports.defaultGlobalConfig = void 0;
|
248460
|
+
exports.defaultGlobalConfig = {
|
248461
|
+
'// Note': 'This is your Vercel config file. For more information see the global configuration documentation.',
|
248462
|
+
'// Docs': 'https://vercel.com/docs/project-configuration#global-configuration/config-json',
|
248463
|
+
collectMetrics: true,
|
248521
248464
|
};
|
248522
|
-
exports.
|
248523
|
-
|
248524
|
-
|
248525
|
-
const config = {
|
248526
|
-
_: 'This is your Vercel credentials file. DO NOT SHARE! More: https://vercel.com/docs/configuration#global',
|
248527
|
-
};
|
248528
|
-
if (existing) {
|
248529
|
-
try {
|
248530
|
-
// @ts-ignore
|
248531
|
-
const sh = existing.credentials.find(item => item.provider === 'sh');
|
248532
|
-
if (sh) {
|
248533
|
-
config.token = sh.token;
|
248534
|
-
}
|
248535
|
-
migrated = true;
|
248536
|
-
}
|
248537
|
-
catch (err) { }
|
248538
|
-
}
|
248539
|
-
return { config, migrated };
|
248465
|
+
exports.defaultAuthConfig = {
|
248466
|
+
'// Note': 'This is your Vercel credentials file. DO NOT SHARE!',
|
248467
|
+
'// Docs': 'https://vercel.com/docs/project-configuration#global-configuration/auth-json',
|
248540
248468
|
};
|
248541
|
-
exports.getDefaultAuthConfig = getDefaultAuthConfig;
|
248542
248469
|
|
248543
248470
|
|
248544
248471
|
/***/ }),
|
@@ -250823,6 +250750,7 @@ class DevServer {
|
|
250823
250750
|
err.message = `Command not found: ${chalk_1.default.cyan(err.path, ...err.spawnargs)}\nPlease ensure that ${(0, cmd_1.default)(err.path)} is properly installed`;
|
250824
250751
|
err.link = 'https://vercel.link/command-not-found';
|
250825
250752
|
}
|
250753
|
+
this.output.prettyError(err);
|
250826
250754
|
await this.sendError(req, res, requestId, 'EDGE_FUNCTION_INVOCATION_FAILED', 500);
|
250827
250755
|
return;
|
250828
250756
|
}
|
@@ -253986,18 +253914,20 @@ function findChanges(oldEnv, newEnv) {
|
|
253986
253914
|
function buildDeltaString(oldEnv, newEnv) {
|
253987
253915
|
const { added, changed, removed } = findChanges(oldEnv, newEnv);
|
253988
253916
|
let deltaString = '';
|
253917
|
+
deltaString += chalk_1.default.green(addDeltaSection('+', changed, true));
|
253989
253918
|
deltaString += chalk_1.default.green(addDeltaSection('+', added));
|
253990
|
-
deltaString += chalk_1.default.yellow(addDeltaSection('~', changed));
|
253991
253919
|
deltaString += chalk_1.default.red(addDeltaSection('-', removed));
|
253992
|
-
return deltaString
|
253920
|
+
return deltaString
|
253921
|
+
? chalk_1.default.gray('Changes:\n') + deltaString + '\n'
|
253922
|
+
: deltaString;
|
253993
253923
|
}
|
253994
253924
|
exports.buildDeltaString = buildDeltaString;
|
253995
|
-
function addDeltaSection(prefix, arr) {
|
253925
|
+
function addDeltaSection(prefix, arr, changed = false) {
|
253996
253926
|
if (arr.length === 0)
|
253997
253927
|
return '';
|
253998
253928
|
return (arr
|
253999
253929
|
.sort()
|
254000
|
-
.map(item => `${prefix} ${item}`)
|
253930
|
+
.map(item => `${prefix} ${item}${changed ? ' (Updated)' : ''}`)
|
254001
253931
|
.join('\n') + '\n');
|
254002
253932
|
}
|
254003
253933
|
|
@@ -261100,7 +261030,7 @@ module.exports = JSON.parse("{\"application/1d-interleaved-parityfec\":{\"source
|
|
261100
261030
|
/***/ ((module) => {
|
261101
261031
|
|
261102
261032
|
"use strict";
|
261103
|
-
module.exports = JSON.parse("{\"name\":\"vercel\",\"version\":\"27.3.
|
261033
|
+
module.exports = JSON.parse("{\"name\":\"vercel\",\"version\":\"27.3.6\",\"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 --runInBand --bail --forceExit\",\"test-unit\":\"yarn test test/unit/\",\"test-integration-cli\":\"rimraf test/fixtures/integration && ava test/integration.js --serial --fail-fast --verbose\",\"test-integration-dev\":\"yarn 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\"],\"ava\":{\"extensions\":[\"ts\"],\"require\":[\"ts-node/register/transpile-only\",\"esm\"]},\"engines\":{\"node\":\">= 14\"},\"dependencies\":{\"@vercel/build-utils\":\"5.1.1\",\"@vercel/go\":\"2.0.14\",\"@vercel/hydrogen\":\"0.0.11\",\"@vercel/next\":\"3.1.14\",\"@vercel/node\":\"2.5.5\",\"@vercel/python\":\"3.1.6\",\"@vercel/redwood\":\"1.0.15\",\"@vercel/remix\":\"1.0.16\",\"@vercel/ruby\":\"1.3.22\",\"@vercel/static-build\":\"1.0.15\",\"update-notifier\":\"5.1.0\"},\"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/ansi-escapes\":\"3.0.0\",\"@types/ansi-regex\":\"4.0.0\",\"@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\":\"11.11.0\",\"@types/node-fetch\":\"2.5.10\",\"@types/npm-package-arg\":\"6.1.0\",\"@types/pluralize\":\"0.0.29\",\"@types/progress\":\"2.0.3\",\"@types/psl\":\"1.1.0\",\"@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/client\":\"12.1.9\",\"@vercel/frameworks\":\"1.1.2\",\"@vercel/fs-detectors\":\"2.0.4\",\"@vercel/fun\":\"1.0.4\",\"@vercel/ncc\":\"0.24.0\",\"@zeit/source-map-support\":\"0.6.2\",\"ajv\":\"6.12.2\",\"alpha-sort\":\"2.0.1\",\"ansi-escapes\":\"3.0.0\",\"ansi-regex\":\"3.0.0\",\"arg\":\"5.0.0\",\"async-listen\":\"1.2.0\",\"async-retry\":\"1.1.3\",\"async-sema\":\"2.1.4\",\"ava\":\"2.2.0\",\"boxen\":\"4.2.0\",\"bytes\":\"3.0.0\",\"chalk\":\"4.1.0\",\"chance\":\"1.1.7\",\"chokidar\":\"3.3.1\",\"codecov\":\"3.8.2\",\"cpy\":\"7.2.0\",\"credit-card\":\"3.0.1\",\"date-fns\":\"1.29.0\",\"debug\":\"3.1.0\",\"dot\":\"1.1.3\",\"dotenv\":\"4.0.0\",\"email-prompt\":\"0.3.2\",\"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\",\"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\",\"jsonlines\":\"0.1.1\",\"load-json-file\":\"3.0.0\",\"mime-types\":\"2.1.24\",\"minimatch\":\"3.0.4\",\"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\",\"progress\":\"2.0.3\",\"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\":\"5.2.0\",\"stripe\":\"5.1.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.7.4\",\"universal-analytics\":\"0.4.20\",\"utility-types\":\"2.1.0\",\"which\":\"2.0.2\",\"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\"]}}");
|
261104
261034
|
|
261105
261035
|
/***/ }),
|
261106
261036
|
|
@@ -261116,7 +261046,7 @@ module.exports = JSON.parse("{\"VISA\":\"Visa\",\"MASTERCARD\":\"MasterCard\",\"
|
|
261116
261046
|
/***/ ((module) => {
|
261117
261047
|
|
261118
261048
|
"use strict";
|
261119
|
-
module.exports = JSON.parse("{\"name\":\"@vercel/client\",\"version\":\"12.1.
|
261049
|
+
module.exports = JSON.parse("{\"name\":\"@vercel/client\",\"version\":\"12.1.9\",\"main\":\"dist/index.js\",\"typings\":\"dist/index.d.ts\",\"homepage\":\"https://vercel.com\",\"license\":\"MIT\",\"files\":[\"dist\"],\"repository\":{\"type\":\"git\",\"url\":\"https://github.com/vercel/vercel.git\",\"directory\":\"packages/client\"},\"scripts\":{\"build\":\"tsc\",\"test-integration-once\":\"yarn 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\":\"yarn test tests/unit.*test.*\"},\"engines\":{\"node\":\">= 14\"},\"devDependencies\":{\"@types/async-retry\":\"1.4.1\",\"@types/fs-extra\":\"7.0.0\",\"@types/jest\":\"27.4.1\",\"@types/minimatch\":\"3.0.5\",\"@types/ms\":\"0.7.30\",\"@types/node\":\"12.0.4\",\"@types/node-fetch\":\"2.5.4\",\"@types/recursive-readdir\":\"2.2.0\",\"typescript\":\"4.3.4\"},\"jest\":{\"preset\":\"ts-jest\",\"testEnvironment\":\"node\",\"verbose\":false,\"setupFilesAfterEnv\":[\"<rootDir>/tests/setup/index.ts\"]},\"dependencies\":{\"@vercel/build-utils\":\"5.1.1\",\"@vercel/routing-utils\":\"2.0.1\",\"@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\"}}");
|
261120
261050
|
|
261121
261051
|
/***/ }),
|
261122
261052
|
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "vercel",
|
3
|
-
"version": "27.3.
|
3
|
+
"version": "27.3.6",
|
4
4
|
"preferGlobal": true,
|
5
5
|
"license": "Apache-2.0",
|
6
6
|
"description": "The command-line interface for Vercel",
|
@@ -16,7 +16,6 @@
|
|
16
16
|
"test-unit": "yarn test test/unit/",
|
17
17
|
"test-integration-cli": "rimraf test/fixtures/integration && ava test/integration.js --serial --fail-fast --verbose",
|
18
18
|
"test-integration-dev": "yarn test test/dev/",
|
19
|
-
"prepublishOnly": "yarn build",
|
20
19
|
"coverage": "codecov",
|
21
20
|
"build": "ts-node ./scripts/build.ts",
|
22
21
|
"dev": "ts-node ./src/index.ts"
|
@@ -42,16 +41,16 @@
|
|
42
41
|
"node": ">= 14"
|
43
42
|
},
|
44
43
|
"dependencies": {
|
45
|
-
"@vercel/build-utils": "5.
|
46
|
-
"@vercel/go": "2.0.
|
47
|
-
"@vercel/hydrogen": "0.0.
|
48
|
-
"@vercel/next": "3.1.
|
49
|
-
"@vercel/node": "2.5.
|
50
|
-
"@vercel/python": "3.1.
|
51
|
-
"@vercel/redwood": "1.0.
|
52
|
-
"@vercel/remix": "1.0.
|
53
|
-
"@vercel/ruby": "1.3.
|
54
|
-
"@vercel/static-build": "1.0.
|
44
|
+
"@vercel/build-utils": "5.1.1",
|
45
|
+
"@vercel/go": "2.0.14",
|
46
|
+
"@vercel/hydrogen": "0.0.11",
|
47
|
+
"@vercel/next": "3.1.14",
|
48
|
+
"@vercel/node": "2.5.5",
|
49
|
+
"@vercel/python": "3.1.6",
|
50
|
+
"@vercel/redwood": "1.0.15",
|
51
|
+
"@vercel/remix": "1.0.16",
|
52
|
+
"@vercel/ruby": "1.3.22",
|
53
|
+
"@vercel/static-build": "1.0.15",
|
55
54
|
"update-notifier": "5.1.0"
|
56
55
|
},
|
57
56
|
"devDependencies": {
|
@@ -97,9 +96,9 @@
|
|
97
96
|
"@types/which": "1.3.2",
|
98
97
|
"@types/write-json-file": "2.2.1",
|
99
98
|
"@types/yauzl-promise": "2.1.0",
|
100
|
-
"@vercel/client": "12.1.
|
101
|
-
"@vercel/frameworks": "1.1.
|
102
|
-
"@vercel/fs-detectors": "2.0.
|
99
|
+
"@vercel/client": "12.1.9",
|
100
|
+
"@vercel/frameworks": "1.1.2",
|
101
|
+
"@vercel/fs-detectors": "2.0.4",
|
103
102
|
"@vercel/fun": "1.0.4",
|
104
103
|
"@vercel/ncc": "0.24.0",
|
105
104
|
"@zeit/source-map-support": "0.6.2",
|
@@ -197,5 +196,5 @@
|
|
197
196
|
"<rootDir>/test/**/*.test.ts"
|
198
197
|
]
|
199
198
|
},
|
200
|
-
"gitHead": "
|
199
|
+
"gitHead": "5eb8b16cbdf6215618b4b8125673941757fa1a8e"
|
201
200
|
}
|