vercel-cli 48.5.0__tar.gz → 48.6.6__tar.gz
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.
Potentially problematic release.
This version of vercel-cli might be problematic. Click here for more details.
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/PKG-INFO +1 -1
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/dist/index.js +106 -24
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/.package-lock.json +3 -3
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/CHANGELOG.md +12 -0
- vercel_cli-48.6.6/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/framework-helpers.d.ts +17 -0
- vercel_cli-48.6.6/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/framework-helpers.js +52 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/node-version.d.ts +4 -1
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/node-version.js +36 -2
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/run-user-scripts.d.ts +6 -10
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/run-user-scripts.js +8 -10
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/index.d.ts +3 -2
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/index.js +73 -10
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/types.d.ts +3 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/types.js +4 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/package.json +2 -2
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/package.json +3 -3
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/.gitignore +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/README.md +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/pyproject.toml +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/LICENSE +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/README.md +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/dist/VERCEL_DIR_README.txt +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/dist/builder-worker.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/dist/get-latest-worker.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/dist/vc.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/LICENSE +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/build.mjs +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/clone-env.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/clone-env.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/debug.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/debug.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/default-cache-path-glob.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/default-cache-path-glob.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/edge-function.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/edge-function.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/errors.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/errors.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/file-blob.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/file-blob.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/file-fs-ref.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/file-fs-ref.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/file-ref.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/file-ref.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/download.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/download.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/get-writable-directory.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/get-writable-directory.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/glob.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/glob.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/normalize-path.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/normalize-path.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/read-config-file.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/read-config-file.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/rename.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/rename.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/stream-to-buffer.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/fs/stream-to-buffer.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/generate-node-builder-functions.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/generate-node-builder-functions.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/get-ignore-filter.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/get-ignore-filter.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/get-installed-package-version.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/get-installed-package-version.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/get-platform-env.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/get-platform-env.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/get-prefixed-env-vars.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/get-prefixed-env-vars.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/hard-link-dir.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/hard-link-dir.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/lambda.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/lambda.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/nodejs-lambda.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/nodejs-lambda.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/os.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/os.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/prerender.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/prerender.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/schemas.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/schemas.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/should-serve.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/should-serve.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/trace/constants.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/trace/constants.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/trace/index.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/trace/index.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/trace/trace.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/trace/trace.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/validate-npmrc.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/validate-npmrc.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/file-blob.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/file-fs-ref.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/file-ref.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/fs/download.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/fs/get-writable-directory.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/fs/glob.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/fs/rename.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/fs/run-user-scripts.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/fs/stream-to-buffer.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/build-utils/lambda.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/detect-agent/CHANGELOG.md +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/detect-agent/LICENSE +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/detect-agent/README.md +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/detect-agent/dist/index.d.ts +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/detect-agent/dist/index.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/detect-agent/package.json +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/python/LICENSE +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/python/dist/index.js +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/python/package.json +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/python/vc_init.py +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/python/vc_init_dev_asgi.py +0 -0
- {vercel_cli-48.5.0 → vercel_cli-48.6.6}/vercel_cli/vendor/node_modules/@vercel/python/vc_init_dev_wsgi.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: vercel-cli
|
|
3
|
-
Version: 48.
|
|
3
|
+
Version: 48.6.6
|
|
4
4
|
Summary: Vercel CLI packaged for Python (bundled Node.js, vendored npm)
|
|
5
5
|
Project-URL: Homepage, https://github.com/nuage-studio/vercel-cli-python
|
|
6
6
|
Project-URL: Repository, https://github.com/nuage-studio/vercel-cli-python
|
|
@@ -49550,7 +49550,7 @@ var require_package = __commonJS2({
|
|
|
49550
49550
|
"../client/package.json"(exports2, module2) {
|
|
49551
49551
|
module2.exports = {
|
|
49552
49552
|
name: "@vercel/client",
|
|
49553
|
-
version: "17.
|
|
49553
|
+
version: "17.1.2",
|
|
49554
49554
|
main: "dist/index.js",
|
|
49555
49555
|
typings: "dist/index.d.ts",
|
|
49556
49556
|
homepage: "https://vercel.com",
|
|
@@ -49589,10 +49589,10 @@ var require_package = __commonJS2({
|
|
|
49589
49589
|
vitest: "2.0.1"
|
|
49590
49590
|
},
|
|
49591
49591
|
dependencies: {
|
|
49592
|
-
"@vercel/build-utils": "12.1
|
|
49592
|
+
"@vercel/build-utils": "12.2.1",
|
|
49593
49593
|
"@vercel/error-utils": "2.0.3",
|
|
49594
49594
|
"@vercel/microfrontends": "1.2.2",
|
|
49595
|
-
"@vercel/routing-utils": "5.2.
|
|
49595
|
+
"@vercel/routing-utils": "5.2.1",
|
|
49596
49596
|
"async-retry": "1.2.3",
|
|
49597
49597
|
"async-sema": "3.0.0",
|
|
49598
49598
|
"fs-extra": "8.0.1",
|
|
@@ -120639,6 +120639,9 @@ var require_detect_builders = __commonJS2({
|
|
|
120639
120639
|
config2.excludeFiles = func.excludeFiles;
|
|
120640
120640
|
}
|
|
120641
120641
|
}
|
|
120642
|
+
if (options.bunVersion) {
|
|
120643
|
+
config2.bunVersion = options.bunVersion;
|
|
120644
|
+
}
|
|
120642
120645
|
const builder = {
|
|
120643
120646
|
use,
|
|
120644
120647
|
src: fileName,
|
|
@@ -120695,6 +120698,9 @@ var require_detect_builders = __commonJS2({
|
|
|
120695
120698
|
if (projectSettings.outputDirectory) {
|
|
120696
120699
|
config2.outputDirectory = projectSettings.outputDirectory;
|
|
120697
120700
|
}
|
|
120701
|
+
if (options.bunVersion) {
|
|
120702
|
+
config2.bunVersion = options.bunVersion;
|
|
120703
|
+
}
|
|
120698
120704
|
if (pkg && (framework === void 0 || framework !== "storybook" && createdAt < Date.parse("2020-03-01"))) {
|
|
120699
120705
|
const deps = {
|
|
120700
120706
|
...pkg.dependencies,
|
|
@@ -120815,7 +120821,7 @@ var require_detect_builders = __commonJS2({
|
|
|
120815
120821
|
}
|
|
120816
120822
|
if (frontendBuilder && (0, import_is_official_runtime.isOfficialRuntime)("next", frontendBuilder.use)) {
|
|
120817
120823
|
for (const fnKey of unusedFunctions.values()) {
|
|
120818
|
-
if (fnKey.startsWith("pages/") || fnKey.startsWith("src/pages") || fnKey.startsWith("app/") || fnKey.startsWith("src/app/")) {
|
|
120824
|
+
if (fnKey.startsWith("pages/") || fnKey.startsWith("src/pages") || fnKey.startsWith("app/") || fnKey.startsWith("src/app/") || fnKey.startsWith("middleware") || fnKey.startsWith("src/middleware")) {
|
|
120819
120825
|
unusedFunctions.delete(fnKey);
|
|
120820
120826
|
} else {
|
|
120821
120827
|
return {
|
|
@@ -133019,7 +133025,7 @@ var require_superstatic = __commonJS2({
|
|
|
133019
133025
|
convertTrailingSlash: () => convertTrailingSlash,
|
|
133020
133026
|
getCleanUrls: () => getCleanUrls2,
|
|
133021
133027
|
pathToRegexp: () => pathToRegexp,
|
|
133022
|
-
sourceToRegex: () =>
|
|
133028
|
+
sourceToRegex: () => sourceToRegex3
|
|
133023
133029
|
});
|
|
133024
133030
|
module2.exports = __toCommonJS4(superstatic_exports);
|
|
133025
133031
|
var import_url20 = require("url");
|
|
@@ -133097,7 +133103,7 @@ var require_superstatic = __commonJS2({
|
|
|
133097
133103
|
}
|
|
133098
133104
|
function convertRedirects(redirects, defaultStatus = 308) {
|
|
133099
133105
|
return redirects.map((r) => {
|
|
133100
|
-
const { src, segments } =
|
|
133106
|
+
const { src, segments } = sourceToRegex3(r.source);
|
|
133101
133107
|
const hasSegments = collectHasSegments(r.has);
|
|
133102
133108
|
normalizeHasKeys(r.has);
|
|
133103
133109
|
normalizeHasKeys(r.missing);
|
|
@@ -133130,7 +133136,7 @@ var require_superstatic = __commonJS2({
|
|
|
133130
133136
|
}
|
|
133131
133137
|
function convertRewrites(rewrites, internalParamNames) {
|
|
133132
133138
|
return rewrites.map((r) => {
|
|
133133
|
-
const { src, segments } =
|
|
133139
|
+
const { src, segments } = sourceToRegex3(r.source);
|
|
133134
133140
|
const hasSegments = collectHasSegments(r.has);
|
|
133135
133141
|
normalizeHasKeys(r.has);
|
|
133136
133142
|
normalizeHasKeys(r.missing);
|
|
@@ -133161,7 +133167,7 @@ var require_superstatic = __commonJS2({
|
|
|
133161
133167
|
function convertHeaders(headers) {
|
|
133162
133168
|
return headers.map((h) => {
|
|
133163
133169
|
const obj = {};
|
|
133164
|
-
const { src, segments } =
|
|
133170
|
+
const { src, segments } = sourceToRegex3(h.source);
|
|
133165
133171
|
const hasSegments = collectHasSegments(h.has);
|
|
133166
133172
|
normalizeHasKeys(h.has);
|
|
133167
133173
|
normalizeHasKeys(h.missing);
|
|
@@ -133223,7 +133229,7 @@ var require_superstatic = __commonJS2({
|
|
|
133223
133229
|
}
|
|
133224
133230
|
return routes2;
|
|
133225
133231
|
}
|
|
133226
|
-
function
|
|
133232
|
+
function sourceToRegex3(source) {
|
|
133227
133233
|
const keys = [];
|
|
133228
133234
|
const r = pathToRegexp("632", source, keys, {
|
|
133229
133235
|
strict: true,
|
|
@@ -134275,7 +134281,8 @@ var require_dist23 = __commonJS2({
|
|
|
134275
134281
|
isHandler: () => isHandler2,
|
|
134276
134282
|
isValidHandleValue: () => isValidHandleValue,
|
|
134277
134283
|
mergeRoutes: () => import_merge2.mergeRoutes,
|
|
134278
|
-
normalizeRoutes: () => normalizeRoutes2
|
|
134284
|
+
normalizeRoutes: () => normalizeRoutes2,
|
|
134285
|
+
sourceToRegex: () => import_superstatic2.sourceToRegex
|
|
134279
134286
|
});
|
|
134280
134287
|
module2.exports = __toCommonJS4(src_exports2);
|
|
134281
134288
|
var import_url20 = require("url");
|
|
@@ -145932,11 +145939,8 @@ var init_unzip = __esm({
|
|
|
145932
145939
|
// src/util/build/write-build-result.ts
|
|
145933
145940
|
async function writeBuildResult(repoRootPath, outputDir, buildResult, build2, builder, builderPkg, vercelConfig, standalone = false) {
|
|
145934
145941
|
let version2 = builder.version;
|
|
145935
|
-
if (
|
|
145936
|
-
version2 =
|
|
145937
|
-
}
|
|
145938
|
-
if ("experimentalVersion" in builder && process.env.VERCEL_EXPERIMENTAL_HONO_BUILD === "1" && "name" in builder && builder.name === "hono") {
|
|
145939
|
-
version2 = builder.experimentalVersion;
|
|
145942
|
+
if ((0, import_build_utils11.isExperimentalBackendsEnabled)() && "output" in buildResult) {
|
|
145943
|
+
version2 = 2;
|
|
145940
145944
|
}
|
|
145941
145945
|
if (typeof version2 !== "number" || version2 === 2) {
|
|
145942
145946
|
return writeBuildResultV2(
|
|
@@ -146081,6 +146085,37 @@ async function writeBuildResultV2(repoRootPath, outputDir, buildResult, build2,
|
|
|
146081
146085
|
}
|
|
146082
146086
|
async function writeBuildResultV3(repoRootPath, outputDir, buildResult, build2, vercelConfig, standalone = false) {
|
|
146083
146087
|
const { output: output2 } = buildResult;
|
|
146088
|
+
if (process.env.VERCEL_EXPERIMENTAL_ROUTES_JSON === "1") {
|
|
146089
|
+
const routesJsonPath = (0, import_path21.join)(outputDir, "..", "routes.json");
|
|
146090
|
+
if ((0, import_fs_extra12.existsSync)(routesJsonPath)) {
|
|
146091
|
+
try {
|
|
146092
|
+
const newOutput = {
|
|
146093
|
+
index: output2
|
|
146094
|
+
};
|
|
146095
|
+
const routesJson = await import_fs_extra12.default.readJSON(routesJsonPath);
|
|
146096
|
+
if (routesJson && typeof routesJson === "object" && "routes" in routesJson && Array.isArray(routesJson.routes)) {
|
|
146097
|
+
for (const route of routesJson.routes) {
|
|
146098
|
+
if (route.source === "/") {
|
|
146099
|
+
continue;
|
|
146100
|
+
}
|
|
146101
|
+
if (route.source) {
|
|
146102
|
+
newOutput[route.source] = output2;
|
|
146103
|
+
}
|
|
146104
|
+
}
|
|
146105
|
+
}
|
|
146106
|
+
return writeBuildResultV2(
|
|
146107
|
+
repoRootPath,
|
|
146108
|
+
outputDir,
|
|
146109
|
+
{ output: newOutput, routes: buildResult.routes },
|
|
146110
|
+
build2,
|
|
146111
|
+
vercelConfig,
|
|
146112
|
+
standalone
|
|
146113
|
+
);
|
|
146114
|
+
} catch (error3) {
|
|
146115
|
+
output_manager_default.error(`Failed to read routes.json: ${error3}`);
|
|
146116
|
+
}
|
|
146117
|
+
}
|
|
146118
|
+
}
|
|
146084
146119
|
const src = build2.src;
|
|
146085
146120
|
if (typeof src !== "string") {
|
|
146086
146121
|
throw new Error(`Expected "build.src" to be a string`);
|
|
@@ -146356,6 +146391,7 @@ var init_write_build_result = __esm({
|
|
|
146356
146391
|
init_unzip();
|
|
146357
146392
|
init_link2();
|
|
146358
146393
|
import_client3 = __toESM3(require_dist7());
|
|
146394
|
+
init_output_manager();
|
|
146359
146395
|
({ normalize: normalize2 } = import_path21.posix);
|
|
146360
146396
|
OUTPUT_DIR = (0, import_path21.join)(VERCEL_DIR2, "output");
|
|
146361
146397
|
}
|
|
@@ -146798,7 +146834,8 @@ var init_validate_config = __esm({
|
|
|
146798
146834
|
trailingSlash: import_routing_utils.trailingSlashSchema,
|
|
146799
146835
|
functions: import_build_utils12.functionsSchema,
|
|
146800
146836
|
images: imagesSchema,
|
|
146801
|
-
crons: cronsSchema
|
|
146837
|
+
crons: cronsSchema,
|
|
146838
|
+
bunVersion: { type: "string" }
|
|
146802
146839
|
}
|
|
146803
146840
|
};
|
|
146804
146841
|
ajv = new import_ajv2.default();
|
|
@@ -148307,8 +148344,12 @@ async function doBuild(client2, project, buildsJson, cwd, outputDir, span, stand
|
|
|
148307
148344
|
devCommand: projectSettings.devCommand ?? void 0,
|
|
148308
148345
|
buildCommand: projectSettings.buildCommand ?? void 0,
|
|
148309
148346
|
framework: projectSettings.framework,
|
|
148310
|
-
nodeVersion: projectSettings.nodeVersion
|
|
148311
|
-
|
|
148347
|
+
nodeVersion: projectSettings.nodeVersion,
|
|
148348
|
+
bunVersion: localConfig.bunVersion ?? void 0
|
|
148349
|
+
} : {
|
|
148350
|
+
...build2.config || {},
|
|
148351
|
+
bunVersion: localConfig.bunVersion ?? void 0
|
|
148352
|
+
};
|
|
148312
148353
|
const builderSpan = span.child("vc.builder", {
|
|
148313
148354
|
name: builderPkg.name
|
|
148314
148355
|
});
|
|
@@ -148328,11 +148369,6 @@ async function doBuild(client2, project, buildsJson, cwd, outputDir, span, stand
|
|
|
148328
148369
|
try {
|
|
148329
148370
|
buildResult = await builderSpan.trace(
|
|
148330
148371
|
() => {
|
|
148331
|
-
if (process.env.VERCEL_EXPERIMENTAL_EXPRESS_BUILD === "1" && "name" in builder && builder.name === "express" && "experimentalBuild" in builder && typeof builder.experimentalBuild === "function") {
|
|
148332
|
-
return builder.experimentalBuild(buildOptions);
|
|
148333
|
-
} else if (process.env.VERCEL_EXPERIMENTAL_HONO_BUILD === "1" && "name" in builder && builder.name === "hono" && "experimentalBuild" in builder && typeof builder.experimentalBuild === "function") {
|
|
148334
|
-
return builder.experimentalBuild(buildOptions);
|
|
148335
|
-
}
|
|
148336
148372
|
return builder.build(buildOptions);
|
|
148337
148373
|
}
|
|
148338
148374
|
);
|
|
@@ -148366,6 +148402,49 @@ async function doBuild(client2, project, buildsJson, cwd, outputDir, span, stand
|
|
|
148366
148402
|
});
|
|
148367
148403
|
}
|
|
148368
148404
|
}
|
|
148405
|
+
const backendBuilders = [
|
|
148406
|
+
"@vercel/express",
|
|
148407
|
+
"@vercel/hono",
|
|
148408
|
+
"@vercel/fastify"
|
|
148409
|
+
];
|
|
148410
|
+
const isBackendBuilder = build2.use && backendBuilders.includes(build2.use);
|
|
148411
|
+
if (process.env.VERCEL_EXPERIMENTAL_ROUTES_JSON === "1") {
|
|
148412
|
+
if ("output" in buildResult && buildResult.output && isBackendBuilder) {
|
|
148413
|
+
const routesJsonPath = (0, import_path27.join)(outputDir, "..", "routes.json");
|
|
148414
|
+
if ((0, import_fs_extra18.existsSync)(routesJsonPath)) {
|
|
148415
|
+
try {
|
|
148416
|
+
const routesJson = await readJSONFile(routesJsonPath);
|
|
148417
|
+
if (routesJson && typeof routesJson === "object" && "routes" in routesJson && Array.isArray(routesJson.routes)) {
|
|
148418
|
+
const convertedRoutes = [];
|
|
148419
|
+
for (const route of routesJson.routes) {
|
|
148420
|
+
if (typeof route.source !== "string") {
|
|
148421
|
+
continue;
|
|
148422
|
+
}
|
|
148423
|
+
const { src } = (0, import_routing_utils2.sourceToRegex)(route.source);
|
|
148424
|
+
const newRoute = {
|
|
148425
|
+
src,
|
|
148426
|
+
dest: route.source
|
|
148427
|
+
};
|
|
148428
|
+
if (route.methods) {
|
|
148429
|
+
newRoute.methods = route.methods;
|
|
148430
|
+
}
|
|
148431
|
+
if (route.source === "/") {
|
|
148432
|
+
continue;
|
|
148433
|
+
}
|
|
148434
|
+
convertedRoutes.push(newRoute);
|
|
148435
|
+
}
|
|
148436
|
+
buildResult.routes = [
|
|
148437
|
+
{ handle: "filesystem" },
|
|
148438
|
+
...convertedRoutes,
|
|
148439
|
+
{ src: "/(.*)", dest: "/" }
|
|
148440
|
+
];
|
|
148441
|
+
}
|
|
148442
|
+
} catch (error3) {
|
|
148443
|
+
output_manager_default.error(`Failed to read routes.json: ${error3}`);
|
|
148444
|
+
}
|
|
148445
|
+
}
|
|
148446
|
+
}
|
|
148447
|
+
}
|
|
148369
148448
|
buildResults.set(build2, buildResult);
|
|
148370
148449
|
let buildOutputLength = 0;
|
|
148371
148450
|
if ("output" in buildResult) {
|
|
@@ -169464,7 +169543,7 @@ async function getBuildMatches(vercelConfig, cwd, devServer, fileList) {
|
|
|
169464
169543
|
if (src[0] === "/") {
|
|
169465
169544
|
src = src.substring(1);
|
|
169466
169545
|
}
|
|
169467
|
-
if (
|
|
169546
|
+
if ((0, import_build_utils16.isBackendFramework)(buildConfig.config?.framework)) {
|
|
169468
169547
|
src = "package.json";
|
|
169469
169548
|
}
|
|
169470
169549
|
if (buildConfig.config?.framework === "fastapi" || buildConfig.config?.framework === "flask") {
|
|
@@ -171122,6 +171201,9 @@ Please ensure that ${cmd(err.path)} is properly installed`;
|
|
|
171122
171201
|
return defaults;
|
|
171123
171202
|
}
|
|
171124
171203
|
}
|
|
171204
|
+
if ((0, import_build_utils17.isExperimentalBackendsEnabled)()) {
|
|
171205
|
+
return "npx @vercel/cervel dev";
|
|
171206
|
+
}
|
|
171125
171207
|
}
|
|
171126
171208
|
return void 0;
|
|
171127
171209
|
}
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
"requires": true,
|
|
4
4
|
"packages": {
|
|
5
5
|
"node_modules/@vercel/build-utils": {
|
|
6
|
-
"version": "12.1
|
|
7
|
-
"resolved": "https://registry.npmjs.org/@vercel/build-utils/-/build-utils-12.1.
|
|
8
|
-
"integrity": "sha512-
|
|
6
|
+
"version": "12.2.1",
|
|
7
|
+
"resolved": "https://registry.npmjs.org/@vercel/build-utils/-/build-utils-12.2.1.tgz",
|
|
8
|
+
"integrity": "sha512-IomevtBkebGsdSklmugLO2ECiqRUpFR9wLVbjYlyjDtcx67UGMtgdjhfxXSOIYcGzJFiOxy820YI4ajUq88qUg==",
|
|
9
9
|
"license": "Apache-2.0"
|
|
10
10
|
},
|
|
11
11
|
"node_modules/@vercel/detect-agent": {
|
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @vercel/build-utils
|
|
2
2
|
|
|
3
|
+
## 12.2.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Add backend util helpers ([#14152](https://github.com/vercel/vercel/pull/14152))
|
|
8
|
+
|
|
9
|
+
## 12.2.0
|
|
10
|
+
|
|
11
|
+
### Minor Changes
|
|
12
|
+
|
|
13
|
+
- Add support for Bun through a vercel.json property ([#14130](https://github.com/vercel/vercel/pull/14130))
|
|
14
|
+
|
|
3
15
|
## 12.1.3
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
vercel_cli-48.6.6/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/framework-helpers.d.ts
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* List of backend frameworks supported by the experimental backends feature
|
|
3
|
+
*/
|
|
4
|
+
export declare const BACKEND_FRAMEWORKS: readonly ["express", "hono", "h3", "nestjs", "fastify"];
|
|
5
|
+
export type BackendFramework = (typeof BACKEND_FRAMEWORKS)[number];
|
|
6
|
+
/**
|
|
7
|
+
* Checks if the given framework is a backend framework
|
|
8
|
+
*/
|
|
9
|
+
export declare function isBackendFramework(framework: string | null | undefined): framework is BackendFramework;
|
|
10
|
+
/**
|
|
11
|
+
* Checks if experimental backends are enabled via environment variable
|
|
12
|
+
*/
|
|
13
|
+
export declare function isExperimentalBackendsEnabled(): boolean;
|
|
14
|
+
/**
|
|
15
|
+
* Checks if experimental backends are enabled AND the framework is a backend framework
|
|
16
|
+
*/
|
|
17
|
+
export declare function shouldUseExperimentalBackends(framework: string | null | undefined): boolean;
|
vercel_cli-48.6.6/vercel_cli/vendor/node_modules/@vercel/build-utils/dist/framework-helpers.js
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var framework_helpers_exports = {};
|
|
20
|
+
__export(framework_helpers_exports, {
|
|
21
|
+
BACKEND_FRAMEWORKS: () => BACKEND_FRAMEWORKS,
|
|
22
|
+
isBackendFramework: () => isBackendFramework,
|
|
23
|
+
isExperimentalBackendsEnabled: () => isExperimentalBackendsEnabled,
|
|
24
|
+
shouldUseExperimentalBackends: () => shouldUseExperimentalBackends
|
|
25
|
+
});
|
|
26
|
+
module.exports = __toCommonJS(framework_helpers_exports);
|
|
27
|
+
const BACKEND_FRAMEWORKS = [
|
|
28
|
+
"express",
|
|
29
|
+
"hono",
|
|
30
|
+
"h3",
|
|
31
|
+
"nestjs",
|
|
32
|
+
"fastify"
|
|
33
|
+
];
|
|
34
|
+
function isBackendFramework(framework) {
|
|
35
|
+
if (!framework)
|
|
36
|
+
return false;
|
|
37
|
+
return BACKEND_FRAMEWORKS.includes(framework);
|
|
38
|
+
}
|
|
39
|
+
function isExperimentalBackendsEnabled() {
|
|
40
|
+
return process.env.VERCEL_EXPERIMENTAL_BACKENDS === "1" || // Previously used for experimental express and hono builds
|
|
41
|
+
process.env.VERCEL_EXPERIMENTAL_EXPRESS_BUILD === "1" || process.env.VERCEL_EXPERIMENTAL_HONO_BUILD === "1";
|
|
42
|
+
}
|
|
43
|
+
function shouldUseExperimentalBackends(framework) {
|
|
44
|
+
return isExperimentalBackendsEnabled() && isBackendFramework(framework);
|
|
45
|
+
}
|
|
46
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
47
|
+
0 && (module.exports = {
|
|
48
|
+
BACKEND_FRAMEWORKS,
|
|
49
|
+
isBackendFramework,
|
|
50
|
+
isExperimentalBackendsEnabled,
|
|
51
|
+
shouldUseExperimentalBackends
|
|
52
|
+
});
|
|
@@ -1,10 +1,13 @@
|
|
|
1
|
-
import { NodeVersion } from '../types';
|
|
1
|
+
import { BunVersion, NodeVersion, Version } from '../types';
|
|
2
2
|
export type NodeVersionMajor = ReturnType<typeof getOptions>[number]['major'];
|
|
3
3
|
export declare const NODE_VERSIONS: NodeVersion[];
|
|
4
|
+
export declare const BUN_VERSIONS: BunVersion[];
|
|
4
5
|
export declare function getNodeVersionByMajor(major: number): NodeVersion | undefined;
|
|
5
6
|
declare function getOptions(): NodeVersion[];
|
|
6
7
|
export declare function getAvailableNodeVersions(): NodeVersionMajor[];
|
|
7
8
|
export declare function getLatestNodeVersion(availableVersions?: NodeVersionMajor[]): NodeVersion;
|
|
8
9
|
export declare function getDiscontinuedNodeVersions(): NodeVersion[];
|
|
9
10
|
export declare function getSupportedNodeVersion(engineRange: string | undefined, isAuto?: boolean, availableVersions?: NodeVersionMajor[]): Promise<NodeVersion>;
|
|
11
|
+
export declare function getSupportedBunVersion(engineRange: string): BunVersion;
|
|
12
|
+
export declare function isBunVersion(version: Version): boolean;
|
|
10
13
|
export {};
|
|
@@ -28,12 +28,15 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
28
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
29
|
var node_version_exports = {};
|
|
30
30
|
__export(node_version_exports, {
|
|
31
|
+
BUN_VERSIONS: () => BUN_VERSIONS,
|
|
31
32
|
NODE_VERSIONS: () => NODE_VERSIONS,
|
|
32
33
|
getAvailableNodeVersions: () => getAvailableNodeVersions,
|
|
33
34
|
getDiscontinuedNodeVersions: () => getDiscontinuedNodeVersions,
|
|
34
35
|
getLatestNodeVersion: () => getLatestNodeVersion,
|
|
35
36
|
getNodeVersionByMajor: () => getNodeVersionByMajor,
|
|
36
|
-
|
|
37
|
+
getSupportedBunVersion: () => getSupportedBunVersion,
|
|
38
|
+
getSupportedNodeVersion: () => getSupportedNodeVersion,
|
|
39
|
+
isBunVersion: () => isBunVersion
|
|
37
40
|
});
|
|
38
41
|
module.exports = __toCommonJS(node_version_exports);
|
|
39
42
|
var import_fs = require("fs");
|
|
@@ -89,6 +92,13 @@ const NODE_VERSIONS = [
|
|
|
89
92
|
discontinueDate: /* @__PURE__ */ new Date("2020-01-06")
|
|
90
93
|
})
|
|
91
94
|
];
|
|
95
|
+
const BUN_VERSIONS = [
|
|
96
|
+
new import_types.BunVersion({
|
|
97
|
+
major: 1,
|
|
98
|
+
range: "1.x",
|
|
99
|
+
runtime: "bun1.x"
|
|
100
|
+
})
|
|
101
|
+
];
|
|
92
102
|
function getNodeVersionByMajor(major) {
|
|
93
103
|
return NODE_VERSIONS.find((v) => v.major === major);
|
|
94
104
|
}
|
|
@@ -175,12 +185,36 @@ async function getSupportedNodeVersion(engineRange, isAuto = false, availableVer
|
|
|
175
185
|
}
|
|
176
186
|
return selection;
|
|
177
187
|
}
|
|
188
|
+
function getSupportedBunVersion(engineRange) {
|
|
189
|
+
if ((0, import_semver.validRange)(engineRange)) {
|
|
190
|
+
const selected = BUN_VERSIONS.find((version) => {
|
|
191
|
+
return (0, import_semver.intersects)(version.range, engineRange);
|
|
192
|
+
});
|
|
193
|
+
if (selected) {
|
|
194
|
+
return new import_types.BunVersion({
|
|
195
|
+
major: selected.major,
|
|
196
|
+
range: selected.range,
|
|
197
|
+
runtime: selected.runtime
|
|
198
|
+
});
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
throw new import_errors.NowBuildError({
|
|
202
|
+
message: `Found invalid Bun Version: "${engineRange}".`,
|
|
203
|
+
code: "BUILD_UTILS_BUN_VERSION_INVALID"
|
|
204
|
+
});
|
|
205
|
+
}
|
|
206
|
+
function isBunVersion(version) {
|
|
207
|
+
return version.runtime.startsWith("bun");
|
|
208
|
+
}
|
|
178
209
|
// Annotate the CommonJS export names for ESM import in node:
|
|
179
210
|
0 && (module.exports = {
|
|
211
|
+
BUN_VERSIONS,
|
|
180
212
|
NODE_VERSIONS,
|
|
181
213
|
getAvailableNodeVersions,
|
|
182
214
|
getDiscontinuedNodeVersions,
|
|
183
215
|
getLatestNodeVersion,
|
|
184
216
|
getNodeVersionByMajor,
|
|
185
|
-
|
|
217
|
+
getSupportedBunVersion,
|
|
218
|
+
getSupportedNodeVersion,
|
|
219
|
+
isBunVersion
|
|
186
220
|
});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import { SpawnOptions } from 'child_process';
|
|
3
|
-
import { Meta, PackageJson, NodeVersion, Config } from '../types';
|
|
3
|
+
import { Meta, PackageJson, NodeVersion, Config, BunVersion } from '../types';
|
|
4
4
|
export type CliType = 'yarn' | 'npm' | 'pnpm' | 'bun' | 'vlt';
|
|
5
5
|
export interface ScanParentDirsResult {
|
|
6
6
|
/**
|
|
@@ -85,23 +85,22 @@ export declare function getNodeBinPath({ cwd, }: {
|
|
|
85
85
|
export declare function getNodeBinPaths({ start, base, }: TraverseUpDirectoriesProps): string[];
|
|
86
86
|
export declare function runShellScript(fsPath: string, args?: string[], spawnOpts?: SpawnOptions): Promise<boolean>;
|
|
87
87
|
export declare function getSpawnOptions(meta: Meta, nodeVersion: NodeVersion): SpawnOptions;
|
|
88
|
-
export declare function getNodeVersion(destPath: string, fallbackVersion?: string | undefined, config?: Config, meta?: Meta, availableVersions?: number[]): Promise<NodeVersion>;
|
|
88
|
+
export declare function getNodeVersion(destPath: string, fallbackVersion?: string | undefined, config?: Config, meta?: Meta, availableVersions?: number[]): Promise<NodeVersion | BunVersion>;
|
|
89
89
|
export declare function scanParentDirs(destPath: string, readPackageJson?: boolean, base?: string): Promise<ScanParentDirsResult>;
|
|
90
90
|
export declare function turboVersionSpecifierSupportsCorepack(turboVersionSpecifier: string): boolean;
|
|
91
91
|
export declare function usingCorepack(env: {
|
|
92
92
|
[x: string]: string | undefined;
|
|
93
93
|
}, packageJsonPackageManager: string | undefined, turboSupportsCorepackHome: boolean | undefined): boolean;
|
|
94
94
|
export declare function walkParentDirs({ base, start, filename, }: WalkParentDirsProps): Promise<string | null>;
|
|
95
|
-
export declare function runNpmInstall(destPath: string, args?: string[], spawnOpts?: SpawnOptions, meta?: Meta,
|
|
95
|
+
export declare function runNpmInstall(destPath: string, args?: string[], spawnOpts?: SpawnOptions, meta?: Meta, projectCreatedAt?: number): Promise<boolean>;
|
|
96
96
|
/**
|
|
97
97
|
* Prepares the input environment based on the used package manager and lockfile
|
|
98
98
|
* versions.
|
|
99
99
|
*/
|
|
100
|
-
export declare function getEnvForPackageManager({ cliType, lockfileVersion, packageJsonPackageManager,
|
|
100
|
+
export declare function getEnvForPackageManager({ cliType, lockfileVersion, packageJsonPackageManager, env, packageJsonEngines, turboSupportsCorepackHome, projectCreatedAt, }: {
|
|
101
101
|
cliType: CliType;
|
|
102
102
|
lockfileVersion: number | undefined;
|
|
103
103
|
packageJsonPackageManager?: string | undefined;
|
|
104
|
-
nodeVersion: NodeVersion | undefined;
|
|
105
104
|
env: {
|
|
106
105
|
[x: string]: string | undefined;
|
|
107
106
|
};
|
|
@@ -120,7 +119,6 @@ export declare function getPathOverrideForPackageManager({ cliType, lockfileVers
|
|
|
120
119
|
cliType: CliType;
|
|
121
120
|
lockfileVersion: number | undefined;
|
|
122
121
|
corepackPackageManager: string | undefined;
|
|
123
|
-
nodeVersion: NodeVersion | undefined;
|
|
124
122
|
corepackEnabled?: boolean;
|
|
125
123
|
packageJsonEngines?: PackageJson.Engines;
|
|
126
124
|
projectCreatedAt?: number;
|
|
@@ -160,10 +158,9 @@ export declare function detectPackageManager(cliType: CliType, lockfileVersion:
|
|
|
160
158
|
* Note: Make sure it doesn't contain any `console.log` calls.
|
|
161
159
|
* @deprecated use `getEnvForPackageManager` instead
|
|
162
160
|
*/
|
|
163
|
-
export declare function getPathForPackageManager({ cliType, lockfileVersion,
|
|
161
|
+
export declare function getPathForPackageManager({ cliType, lockfileVersion, env, }: {
|
|
164
162
|
cliType: CliType;
|
|
165
163
|
lockfileVersion: number | undefined;
|
|
166
|
-
nodeVersion: NodeVersion | undefined;
|
|
167
164
|
env: {
|
|
168
165
|
[x: string]: string | undefined;
|
|
169
166
|
};
|
|
@@ -187,10 +184,9 @@ export declare function getPathForPackageManager({ cliType, lockfileVersion, nod
|
|
|
187
184
|
*/
|
|
188
185
|
yarnNodeLinker: string | undefined;
|
|
189
186
|
};
|
|
190
|
-
export declare function runCustomInstallCommand({ destPath, installCommand,
|
|
187
|
+
export declare function runCustomInstallCommand({ destPath, installCommand, spawnOpts, projectCreatedAt, }: {
|
|
191
188
|
destPath: string;
|
|
192
189
|
installCommand: string;
|
|
193
|
-
nodeVersion: NodeVersion;
|
|
194
190
|
spawnOpts?: SpawnOptions;
|
|
195
191
|
projectCreatedAt?: number;
|
|
196
192
|
}): Promise<void>;
|
|
@@ -182,6 +182,9 @@ function getSpawnOptions(meta, nodeVersion) {
|
|
|
182
182
|
const opts = {
|
|
183
183
|
env: (0, import_clone_env.cloneEnv)(process.env)
|
|
184
184
|
};
|
|
185
|
+
if ((0, import_node_version.isBunVersion)(nodeVersion)) {
|
|
186
|
+
return opts;
|
|
187
|
+
}
|
|
185
188
|
if (!meta.isDev) {
|
|
186
189
|
let found = false;
|
|
187
190
|
const oldPath = opts.env.PATH || process.env.PATH || "";
|
|
@@ -200,6 +203,9 @@ function getSpawnOptions(meta, nodeVersion) {
|
|
|
200
203
|
return opts;
|
|
201
204
|
}
|
|
202
205
|
async function getNodeVersion(destPath, fallbackVersion = process.env.VERCEL_PROJECT_SETTINGS_NODE_VERSION, config = {}, meta = {}, availableVersions = (0, import_node_version.getAvailableNodeVersions)()) {
|
|
206
|
+
if (config.bunVersion) {
|
|
207
|
+
return (0, import_node_version.getSupportedBunVersion)(config.bunVersion);
|
|
208
|
+
}
|
|
203
209
|
const latestVersion = (0, import_node_version.getLatestNodeVersion)(availableVersions);
|
|
204
210
|
if (meta.isDev) {
|
|
205
211
|
latestVersion.runtime = "nodejs";
|
|
@@ -520,7 +526,7 @@ function checkIfAlreadyInstalled(runNpmInstallSet, packageJsonPath) {
|
|
|
520
526
|
return { alreadyInstalled, runNpmInstallSet: initializedRunNpmInstallSet };
|
|
521
527
|
}
|
|
522
528
|
const runNpmInstallSema = new import_async_sema.default(1);
|
|
523
|
-
async function runNpmInstall(destPath, args = [], spawnOpts, meta,
|
|
529
|
+
async function runNpmInstall(destPath, args = [], spawnOpts, meta, projectCreatedAt) {
|
|
524
530
|
if (meta?.isDev) {
|
|
525
531
|
(0, import_debug.default)("Skipping dependency installation because dev mode is enabled");
|
|
526
532
|
return false;
|
|
@@ -573,7 +579,6 @@ async function runNpmInstall(destPath, args = [], spawnOpts, meta, nodeVersion,
|
|
|
573
579
|
cliType,
|
|
574
580
|
lockfileVersion,
|
|
575
581
|
packageJsonPackageManager,
|
|
576
|
-
nodeVersion,
|
|
577
582
|
env,
|
|
578
583
|
packageJsonEngines: packageJson?.engines,
|
|
579
584
|
turboSupportsCorepackHome,
|
|
@@ -600,7 +605,6 @@ function getEnvForPackageManager({
|
|
|
600
605
|
cliType,
|
|
601
606
|
lockfileVersion,
|
|
602
607
|
packageJsonPackageManager,
|
|
603
|
-
nodeVersion,
|
|
604
608
|
env,
|
|
605
609
|
packageJsonEngines,
|
|
606
610
|
turboSupportsCorepackHome,
|
|
@@ -619,7 +623,6 @@ function getEnvForPackageManager({
|
|
|
619
623
|
cliType,
|
|
620
624
|
lockfileVersion,
|
|
621
625
|
corepackPackageManager: packageJsonPackageManager,
|
|
622
|
-
nodeVersion,
|
|
623
626
|
corepackEnabled,
|
|
624
627
|
packageJsonEngines,
|
|
625
628
|
projectCreatedAt
|
|
@@ -913,15 +916,13 @@ function detectPackageManager(cliType, lockfileVersion, projectCreatedAt) {
|
|
|
913
916
|
function getPathForPackageManager({
|
|
914
917
|
cliType,
|
|
915
918
|
lockfileVersion,
|
|
916
|
-
nodeVersion,
|
|
917
919
|
env
|
|
918
920
|
}) {
|
|
919
921
|
const corepackEnabled = env.ENABLE_EXPERIMENTAL_COREPACK === "1";
|
|
920
922
|
let overrides = getPathOverrideForPackageManager({
|
|
921
923
|
cliType,
|
|
922
924
|
lockfileVersion,
|
|
923
|
-
corepackPackageManager: void 0
|
|
924
|
-
nodeVersion
|
|
925
|
+
corepackPackageManager: void 0
|
|
925
926
|
});
|
|
926
927
|
if (corepackEnabled) {
|
|
927
928
|
overrides = NO_OVERRIDE;
|
|
@@ -947,7 +948,6 @@ function getPathForPackageManager({
|
|
|
947
948
|
async function runCustomInstallCommand({
|
|
948
949
|
destPath,
|
|
949
950
|
installCommand,
|
|
950
|
-
nodeVersion,
|
|
951
951
|
spawnOpts,
|
|
952
952
|
projectCreatedAt
|
|
953
953
|
}) {
|
|
@@ -963,7 +963,6 @@ async function runCustomInstallCommand({
|
|
|
963
963
|
cliType,
|
|
964
964
|
lockfileVersion,
|
|
965
965
|
packageJsonPackageManager,
|
|
966
|
-
nodeVersion,
|
|
967
966
|
env: spawnOpts?.env || {},
|
|
968
967
|
packageJsonEngines: packageJson?.engines,
|
|
969
968
|
turboSupportsCorepackHome,
|
|
@@ -1000,7 +999,6 @@ async function runPackageJsonScript(destPath, scriptNames, spawnOpts, projectCre
|
|
|
1000
999
|
cliType,
|
|
1001
1000
|
lockfileVersion,
|
|
1002
1001
|
packageJsonPackageManager,
|
|
1003
|
-
nodeVersion: void 0,
|
|
1004
1002
|
env: (0, import_clone_env.cloneEnv)(process.env, spawnOpts?.env),
|
|
1005
1003
|
packageJsonEngines: packageJson?.engines,
|
|
1006
1004
|
turboSupportsCorepackHome,
|
|
@@ -9,7 +9,7 @@ import getWriteableDirectory from './fs/get-writable-directory';
|
|
|
9
9
|
import glob, { GlobOptions } from './fs/glob';
|
|
10
10
|
import rename from './fs/rename';
|
|
11
11
|
import { spawnAsync, execCommand, spawnCommand, walkParentDirs, getScriptName, installDependencies, runPackageJsonScript, runNpmInstall, runBundleInstall, runPipInstall, runShellScript, runCustomInstallCommand, getEnvForPackageManager, getNodeVersion, getPathForPackageManager, detectPackageManager, getSpawnOptions, getNodeBinPath, getNodeBinPaths, scanParentDirs, traverseUpDirectories } from './fs/run-user-scripts';
|
|
12
|
-
import { getLatestNodeVersion, getDiscontinuedNodeVersions, getSupportedNodeVersion } from './fs/node-version';
|
|
12
|
+
import { getLatestNodeVersion, getDiscontinuedNodeVersions, getSupportedNodeVersion, isBunVersion, getSupportedBunVersion } from './fs/node-version';
|
|
13
13
|
import streamToBuffer, { streamToBufferChunks } from './fs/stream-to-buffer';
|
|
14
14
|
import debug from './debug';
|
|
15
15
|
import getIgnoreFilter from './get-ignore-filter';
|
|
@@ -18,7 +18,7 @@ import { getPrefixedEnvVars } from './get-prefixed-env-vars';
|
|
|
18
18
|
import { cloneEnv } from './clone-env';
|
|
19
19
|
import { hardLinkDir } from './hard-link-dir';
|
|
20
20
|
import { validateNpmrc } from './validate-npmrc';
|
|
21
|
-
export { FileBlob, FileFsRef, FileRef, Lambda, NodejsLambda, createLambda, Prerender, download, downloadFile, DownloadedFiles, getWriteableDirectory, glob, GlobOptions, rename, spawnAsync, getScriptName, installDependencies, runPackageJsonScript, execCommand, spawnCommand, walkParentDirs, getNodeBinPath, getNodeBinPaths, getSupportedNodeVersion, detectPackageManager, runNpmInstall, runBundleInstall, runPipInstall, runShellScript, runCustomInstallCommand, getEnvForPackageManager, getNodeVersion, getPathForPackageManager, getLatestNodeVersion, getDiscontinuedNodeVersions, getSpawnOptions, getPlatformEnv, getPrefixedEnvVars, streamToBuffer, streamToBufferChunks, debug, isSymbolicLink, isDirectory, getLambdaOptionsFromFunction, scanParentDirs, getIgnoreFilter, cloneEnv, hardLinkDir, traverseUpDirectories, validateNpmrc, };
|
|
21
|
+
export { FileBlob, FileFsRef, FileRef, Lambda, NodejsLambda, createLambda, Prerender, download, downloadFile, DownloadedFiles, getWriteableDirectory, glob, GlobOptions, rename, spawnAsync, getScriptName, installDependencies, runPackageJsonScript, execCommand, spawnCommand, walkParentDirs, getNodeBinPath, getNodeBinPaths, getSupportedNodeVersion, isBunVersion, getSupportedBunVersion, detectPackageManager, runNpmInstall, runBundleInstall, runPipInstall, runShellScript, runCustomInstallCommand, getEnvForPackageManager, getNodeVersion, getPathForPackageManager, getLatestNodeVersion, getDiscontinuedNodeVersions, getSpawnOptions, getPlatformEnv, getPrefixedEnvVars, streamToBuffer, streamToBufferChunks, debug, isSymbolicLink, isDirectory, getLambdaOptionsFromFunction, scanParentDirs, getIgnoreFilter, cloneEnv, hardLinkDir, traverseUpDirectories, validateNpmrc, };
|
|
22
22
|
export { EdgeFunction } from './edge-function';
|
|
23
23
|
export { readConfigFile } from './fs/read-config-file';
|
|
24
24
|
export { normalizePath } from './fs/normalize-path';
|
|
@@ -32,3 +32,4 @@ export { NODE_VERSIONS } from './fs/node-version';
|
|
|
32
32
|
export { getInstalledPackageVersion } from './get-installed-package-version';
|
|
33
33
|
export { defaultCachePathGlob } from './default-cache-path-glob';
|
|
34
34
|
export { generateNodeBuilderFunctions } from './generate-node-builder-functions';
|
|
35
|
+
export { BACKEND_FRAMEWORKS, BackendFramework, isBackendFramework, isExperimentalBackendsEnabled, shouldUseExperimentalBackends, } from './framework-helpers';
|