@vercel/backends 0.0.8 → 0.0.10

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.d.mts CHANGED
@@ -1,7 +1,8 @@
1
- import { BuildV2 } from "@vercel/build-utils";
1
+ import { BuildV2, PrepareCache } from "@vercel/build-utils";
2
2
 
3
3
  //#region src/index.d.ts
4
4
  declare const version = 2;
5
5
  declare const build: BuildV2;
6
+ declare const prepareCache: PrepareCache;
6
7
  //#endregion
7
- export { build, version };
8
+ export { build, prepareCache, version };
package/dist/index.mjs CHANGED
@@ -1,6 +1,6 @@
1
1
  import { createRequire } from "node:module";
2
- import { existsSync, lstatSync, readFileSync } from "fs";
3
2
  import { delimiter, dirname, join, relative } from "path";
3
+ import { existsSync, lstatSync, readFileSync } from "fs";
4
4
  import { introspectApp } from "@vercel/introspection";
5
5
  import { nodeFileTrace } from "@vercel/nft";
6
6
  import { join as join$1, relative as relative$1 } from "node:path";
@@ -52811,8 +52811,8 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
52811
52811
  buildsSchema: () => buildsSchema,
52812
52812
  cloneEnv: () => cloneEnv,
52813
52813
  createLambda: () => createLambda,
52814
- debug: () => debug,
52815
- defaultCachePathGlob: () => defaultCachePathGlob,
52814
+ debug: () => debug$1,
52815
+ defaultCachePathGlob: () => defaultCachePathGlob$1,
52816
52816
  detectPackageManager: () => detectPackageManager,
52817
52817
  download: () => download$1,
52818
52818
  downloadFile: () => downloadFile,
@@ -52839,14 +52839,15 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
52839
52839
  getSupportedBunVersion: () => getSupportedBunVersion,
52840
52840
  getSupportedNodeVersion: () => getSupportedNodeVersion,
52841
52841
  getWriteableDirectory: () => getWritableDirectory,
52842
- glob: () => glob,
52842
+ glob: () => glob$1,
52843
52843
  hardLinkDir: () => hardLinkDir,
52844
52844
  installDependencies: () => installDependencies,
52845
52845
  isBackendBuilder: () => isBackendBuilder,
52846
52846
  isBackendFramework: () => isBackendFramework,
52847
- isBunVersion: () => isBunVersion,
52847
+ isBunVersion: () => isBunVersion$1,
52848
52848
  isDirectory: () => isDirectory,
52849
52849
  isExperimentalBackendsEnabled: () => isExperimentalBackendsEnabled,
52850
+ isExperimentalBackendsWithoutIntrospectionEnabled: () => isExperimentalBackendsWithoutIntrospectionEnabled,
52850
52851
  isSymbolicLink: () => isSymbolicLink,
52851
52852
  normalizePath: () => normalizePath,
52852
52853
  readConfigFile: () => readConfigFile,
@@ -53162,7 +53163,7 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
53162
53163
  }
53163
53164
  return n;
53164
53165
  };
53165
- function debug(message, ...additional) {
53166
+ function debug$1(message, ...additional) {
53166
53167
  if (getPlatformEnv("BUILDER_DEBUG")) console.log(message, ...additional);
53167
53168
  else if (process.env.VERCEL_DEBUG_PREFIX) console.log(`${process.env.VERCEL_DEBUG_PREFIX}${message}`, ...additional);
53168
53169
  }
@@ -53267,7 +53268,7 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
53267
53268
  async function download$1(files, basePath, meta) {
53268
53269
  const { isDev = false, skipDownload = false, filesChanged = null, filesRemoved = null } = meta || {};
53269
53270
  if (isDev || skipDownload) return files;
53270
- debug("Downloading deployment source files...");
53271
+ debug$1("Downloading deployment source files...");
53271
53272
  const start = Date.now();
53272
53273
  const files2 = {};
53273
53274
  const filenames = Object.keys(files);
@@ -53290,7 +53291,7 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
53290
53291
  files2[name] = await downloadFile(file, import_path2.default.join(basePath, name));
53291
53292
  }));
53292
53293
  const duration = Date.now() - start;
53293
- debug(`Downloaded ${filenames.length} source files: ${duration}ms`);
53294
+ debug$1(`Downloaded ${filenames.length} source files: ${duration}ms`);
53294
53295
  return files2;
53295
53296
  }
53296
53297
  function getDefaultLambdaArchitecture(architecture) {
@@ -53529,7 +53530,7 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
53529
53530
  return isWin ? p.replace(/\\/g, "/") : p;
53530
53531
  }
53531
53532
  var vanillaGlob = (0, import_util.promisify)(import_glob.default);
53532
- async function glob(pattern, opts, mountpoint) {
53533
+ async function glob$1(pattern, opts, mountpoint) {
53533
53534
  const options = typeof opts === "string" ? { cwd: opts } : opts;
53534
53535
  if (!options.cwd) throw new Error("Second argument (basePath) must be specified for names of resulting files");
53535
53536
  if (!import_path4.default.isAbsolute(options.cwd)) throw new Error(`basePath/cwd must be an absolute path (${options.cwd})`);
@@ -53722,7 +53723,7 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
53722
53723
  link: "http://vercel.link/node-version",
53723
53724
  message: `${`Node.js Version "${selection.range}" is discontinued and must be upgraded.`} ${getHint(isAuto)}`
53724
53725
  });
53725
- debug(`Selected Node.js ${selection.range}`);
53726
+ debug$1(`Selected Node.js ${selection.range}`);
53726
53727
  if (selection.state === "deprecated") {
53727
53728
  const d = selection.formattedDate;
53728
53729
  if (d) console.warn(`Error: Node.js version ${selection.range} is deprecated. Deployments created on or after ${d} will fail to build. ${getHint(isAuto)}`);
@@ -53746,7 +53747,7 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
53746
53747
  code: "BUILD_UTILS_BUN_VERSION_INVALID"
53747
53748
  });
53748
53749
  }
53749
- function isBunVersion(version$1) {
53750
+ function isBunVersion$1(version$1) {
53750
53751
  return version$1.runtime.startsWith("bun");
53751
53752
  }
53752
53753
  var import_js_yaml = __toESM(require_js_yaml2());
@@ -53891,7 +53892,7 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
53891
53892
  }
53892
53893
  function getSpawnOptions$1(meta, nodeVersion) {
53893
53894
  const opts = { env: cloneEnv(process.env) };
53894
- if (isBunVersion(nodeVersion)) return opts;
53895
+ if (isBunVersion$1(nodeVersion)) return opts;
53895
53896
  if (!meta.isDev) {
53896
53897
  let found = false;
53897
53898
  const pathSegments = (opts.env.PATH || process.env.PATH || "").split(import_path5.default.delimiter).map((segment) => {
@@ -54096,11 +54097,7 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
54096
54097
  switch (packageManager) {
54097
54098
  case "npm": return {
54098
54099
  prettyCommand: "npm install",
54099
- commandArguments: args.filter((a) => a !== "--prefer-offline").concat([
54100
- "install",
54101
- "--no-audit",
54102
- "--unsafe-perm"
54103
- ])
54100
+ commandArguments: args.filter((a) => a !== "--prefer-offline").concat(["install", "--no-audit"])
54104
54101
  };
54105
54102
  case "pnpm": return {
54106
54103
  prettyCommand: "pnpm install",
@@ -54142,7 +54139,7 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
54142
54139
  var runNpmInstallSema = new import_async_sema4.default(1);
54143
54140
  async function runNpmInstall$1(destPath, args = [], spawnOpts, meta, projectCreatedAt) {
54144
54141
  if (meta?.isDev) {
54145
- debug("Skipping dependency installation because dev mode is enabled");
54142
+ debug$1("Skipping dependency installation because dev mode is enabled");
54146
54143
  return false;
54147
54144
  }
54148
54145
  (0, import_assert6.default)(import_path5.default.isAbsolute(destPath));
@@ -54150,7 +54147,7 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
54150
54147
  await runNpmInstallSema.acquire();
54151
54148
  const { cliType, packageJsonPath, packageJson, lockfileVersion, packageJsonPackageManager, turboSupportsCorepackHome } = await scanParentDirs$1(destPath, true);
54152
54149
  if (!packageJsonPath) {
54153
- debug(`Skipping dependency installation because no package.json was found for ${destPath}`);
54150
+ debug$1(`Skipping dependency installation because no package.json was found for ${destPath}`);
54154
54151
  return false;
54155
54152
  }
54156
54153
  const defaultInstall = args.length === 0;
@@ -54170,7 +54167,7 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
54170
54167
  }
54171
54168
  const installTime = Date.now();
54172
54169
  console.log("Installing dependencies...");
54173
- debug(`Installing to ${destPath}`);
54170
+ debug$1(`Installing to ${destPath}`);
54174
54171
  const opts = {
54175
54172
  cwd: destPath,
54176
54173
  ...spawnOpts
@@ -54192,7 +54189,7 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
54192
54189
  args,
54193
54190
  opts
54194
54191
  });
54195
- debug(`Install complete [${Date.now() - installTime}ms]`);
54192
+ debug$1(`Install complete [${Date.now() - installTime}ms]`);
54196
54193
  return true;
54197
54194
  } finally {
54198
54195
  runNpmInstallSema.release();
@@ -54208,8 +54205,8 @@ var require_dist$1 = /* @__PURE__ */ __commonJS$1({ "../build-utils/dist/index.j
54208
54205
  packageJsonEngines,
54209
54206
  projectCreatedAt
54210
54207
  });
54211
- if (corepackEnabled) debug(`Detected corepack use for "${packageJsonPackageManager}". Not overriding package manager version.`);
54212
- else debug(`Detected ${detectedPackageManager}. Added "${newPath}" to path. Based on assumed package manager "${cliType}", lockfile "${detectedLockfile}", and lockfileVersion "${lockfileVersion}"`);
54208
+ if (corepackEnabled) debug$1(`Detected corepack use for "${packageJsonPackageManager}". Not overriding package manager version.`);
54209
+ else debug$1(`Detected ${detectedPackageManager}. Added "${newPath}" to path. Based on assumed package manager "${cliType}", lockfile "${detectedLockfile}", and lockfileVersion "${lockfileVersion}"`);
54213
54210
  const newEnv = { ...env };
54214
54211
  const alreadyInPath = (newPath2) => {
54215
54212
  return (env.PATH ?? "").split(import_path5.default.delimiter).includes(newPath2);
@@ -54231,7 +54228,6 @@ To use ${otherVersion}, manually opt in using corepack (https://vercel.com/docs/
54231
54228
  const versionString = cliType === "pnpm" ? `version ${lockfileVersion} ` : "";
54232
54229
  console.log(`Detected \`${detectedLockfile}\` ${versionString}generated by ${detectedPackageManager}`);
54233
54230
  }
54234
- if (cliType === "bun") console.warn("Warning: Bun is used as a package manager at build time only, not at runtime with Functions");
54235
54231
  }
54236
54232
  }
54237
54233
  if (cliType === "yarn" && !env.YARN_NODE_LINKER) newEnv.YARN_NODE_LINKER = "node-modules";
@@ -54415,7 +54411,7 @@ To use ${otherVersion}, manually opt in using corepack (https://vercel.com/docs/
54415
54411
  turboSupportsCorepackHome,
54416
54412
  projectCreatedAt
54417
54413
  });
54418
- debug(`Running with $PATH:`, env?.PATH || "");
54414
+ debug$1(`Running with $PATH:`, env?.PATH || "");
54419
54415
  await execCommand$1(installCommand, {
54420
54416
  ...spawnOpts,
54421
54417
  env,
@@ -54427,7 +54423,7 @@ To use ${otherVersion}, manually opt in using corepack (https://vercel.com/docs/
54427
54423
  const { packageJson, cliType, lockfileVersion, packageJsonPackageManager, turboSupportsCorepackHome } = await scanParentDirs$1(destPath, true);
54428
54424
  const scriptName = getScriptName(packageJson, typeof scriptNames === "string" ? [scriptNames] : scriptNames);
54429
54425
  if (!scriptName) return false;
54430
- debug("Running user script...");
54426
+ debug$1("Running user script...");
54431
54427
  const runScriptTime = Date.now();
54432
54428
  const opts = {
54433
54429
  cwd: destPath,
@@ -54449,12 +54445,12 @@ To use ${otherVersion}, manually opt in using corepack (https://vercel.com/docs/
54449
54445
  else opts.prettyCommand = `yarn run ${scriptName}`;
54450
54446
  console.log(`Running "${opts.prettyCommand}"`);
54451
54447
  await spawnAsync(cliType, ["run", scriptName], opts);
54452
- debug(`Script complete [${Date.now() - runScriptTime}ms]`);
54448
+ debug$1(`Script complete [${Date.now() - runScriptTime}ms]`);
54453
54449
  return true;
54454
54450
  }
54455
54451
  async function runBundleInstall(destPath, args = [], spawnOpts, meta) {
54456
54452
  if (meta && meta.isDev) {
54457
- debug("Skipping dependency installation because dev mode is enabled");
54453
+ debug$1("Skipping dependency installation because dev mode is enabled");
54458
54454
  return;
54459
54455
  }
54460
54456
  (0, import_assert6.default)(import_path5.default.isAbsolute(destPath));
@@ -54467,7 +54463,7 @@ To use ${otherVersion}, manually opt in using corepack (https://vercel.com/docs/
54467
54463
  }
54468
54464
  async function runPipInstall(destPath, args = [], spawnOpts, meta) {
54469
54465
  if (meta && meta.isDev) {
54470
- debug("Skipping dependency installation because dev mode is enabled");
54466
+ debug$1("Skipping dependency installation because dev mode is enabled");
54471
54467
  return;
54472
54468
  }
54473
54469
  (0, import_assert6.default)(import_path5.default.isAbsolute(destPath));
@@ -54812,15 +54808,15 @@ To use ${otherVersion}, manually opt in using corepack (https://vercel.com/docs/
54812
54808
  const resolved = __require.resolve(`${packageName}/package.json`, { paths: path7 ? Array.isArray(path7) ? path7 : [path7] : [process.cwd()] });
54813
54809
  return __require(resolved).version;
54814
54810
  } catch (err) {
54815
- debug(`Could not resolve package "${packageName}". Package is not installed.`, err);
54811
+ debug$1(`Could not resolve package "${packageName}". Package is not installed.`, err);
54816
54812
  return;
54817
54813
  }
54818
54814
  }
54819
- var defaultCachePathGlob = "**/{node_modules,.yarn/cache}/**";
54815
+ var defaultCachePathGlob$1 = "**/{node_modules,.yarn/cache}/**";
54820
54816
  var import_node_path = __require("path");
54821
54817
  var import_node_fs = __toESM(__require("fs"));
54822
54818
  var import_node_module = __require("module");
54823
- function generateNodeBuilderFunctions(frameworkName, regex, validFilenames, validExtensions, nodeBuild) {
54819
+ function generateNodeBuilderFunctions(frameworkName, regex, validFilenames, validExtensions, nodeBuild, opts) {
54824
54820
  const entrypointsForMessage = validFilenames.map((filename) => `- ${filename}.{${validExtensions.join(",")}}`).join("\n");
54825
54821
  const require_ = (0, import_node_module.createRequire)(__filename);
54826
54822
  const build$2 = async (args) => {
@@ -54838,7 +54834,8 @@ To use ${otherVersion}, manually opt in using corepack (https://vercel.com/docs/
54838
54834
  considerBuildCommand: true,
54839
54835
  entrypointCallback: async () => {
54840
54836
  return entrypointCallback(args);
54841
- }
54837
+ },
54838
+ checks: opts?.checks ?? (() => {})
54842
54839
  });
54843
54840
  let version$1 = void 0;
54844
54841
  try {
@@ -54856,16 +54853,16 @@ To use ${otherVersion}, manually opt in using corepack (https://vercel.com/docs/
54856
54853
  const entrypointGlob = `{${validFilenames.map((entrypoint) => `${entrypoint}`).join(",")}}.{${validExtensions.join(",")}}`;
54857
54854
  const dir = args.config.projectSettings?.outputDirectory?.replace(/^\/+|\/+$/g, "");
54858
54855
  if (dir) {
54859
- const { entrypoint: entrypointFromOutputDir, entrypointsNotMatchingRegex: entrypointsNotMatchingRegex2 } = findEntrypoint$1(await glob(entrypointGlob, (0, import_node_path.join)(args.workPath, dir)));
54856
+ const { entrypoint: entrypointFromOutputDir, entrypointsNotMatchingRegex: entrypointsNotMatchingRegex2 } = findEntrypoint$1(await glob$1(entrypointGlob, (0, import_node_path.join)(args.workPath, dir)));
54860
54857
  if (entrypointFromOutputDir) return (0, import_node_path.join)(dir, entrypointFromOutputDir);
54861
54858
  if (entrypointsNotMatchingRegex2.length > 0) throw new Error(`No entrypoint found which imports ${frameworkName}. Found possible ${pluralize("entrypoint", entrypointsNotMatchingRegex2.length)}: ${entrypointsNotMatchingRegex2.join(", ")}`);
54862
54859
  throw new Error(`No entrypoint found in output directory: "${dir}". Searched for:
54863
54860
  ${entrypointsForMessage}`);
54864
54861
  }
54865
- const { entrypoint: entrypointFromRoot, entrypointsNotMatchingRegex } = findEntrypoint$1(await glob(entrypointGlob, args.workPath));
54862
+ const { entrypoint: entrypointFromRoot, entrypointsNotMatchingRegex } = findEntrypoint$1(await glob$1(entrypointGlob, args.workPath));
54866
54863
  if (entrypointFromRoot) return entrypointFromRoot;
54867
54864
  if (mainPackageEntrypoint) {
54868
- const entrypointFromPackageJson = await glob(mainPackageEntrypoint, args.workPath);
54865
+ const entrypointFromPackageJson = await glob$1(mainPackageEntrypoint, args.workPath);
54869
54866
  if (entrypointFromPackageJson[mainPackageEntrypoint]) {
54870
54867
  if (checkMatchesRegex(entrypointFromPackageJson[mainPackageEntrypoint])) return mainPackageEntrypoint;
54871
54868
  }
@@ -54942,8 +54939,11 @@ ${entrypointsForMessage}`);
54942
54939
  if (!framework) return false;
54943
54940
  return BACKEND_FRAMEWORKS.includes(framework);
54944
54941
  }
54942
+ function isExperimentalBackendsWithoutIntrospectionEnabled() {
54943
+ return process.env.VERCEL_BACKENDS_BUILDS === "1";
54944
+ }
54945
54945
  function isExperimentalBackendsEnabled() {
54946
- return process.env.VERCEL_EXPERIMENTAL_BACKENDS === "1" || process.env.VERCEL_EXPERIMENTAL_EXPRESS_BUILD === "1" || process.env.VERCEL_EXPERIMENTAL_HONO_BUILD === "1";
54946
+ return isExperimentalBackendsWithoutIntrospectionEnabled() || process.env.VERCEL_EXPERIMENTAL_BACKENDS === "1" || process.env.VERCEL_EXPERIMENTAL_EXPRESS_BUILD === "1" || process.env.VERCEL_EXPERIMENTAL_HONO_BUILD === "1";
54947
54947
  }
54948
54948
  function isBackendBuilder(builder) {
54949
54949
  if (!builder) return false;
@@ -55011,13 +55011,16 @@ async function maybeExecBuildCommand(args, options) {
55011
55011
  //#endregion
55012
55012
  //#region src/node-file-trace.ts
55013
55013
  var import_dist$1 = require_dist$1();
55014
- const nodeFileTrace$1 = async (args, output) => {
55014
+ const nodeFileTrace$1 = async (args, downloadResult, output) => {
55015
55015
  const { dir: outputDir, handler } = output;
55016
55016
  const entry = join(outputDir, handler);
55017
55017
  const files = {};
55018
+ const conditions = (0, import_dist$1.isBunVersion)(downloadResult.nodeVersion) ? ["bun"] : void 0;
55018
55019
  const nftResult = await nodeFileTrace([entry], {
55019
55020
  base: args.repoRootPath,
55020
- ignore: args.config.excludeFiles
55021
+ ignore: args.config.excludeFiles,
55022
+ conditions,
55023
+ mixedModules: true
55021
55024
  });
55022
55025
  const packageJsonPath = join(args.workPath, "package.json");
55023
55026
  if (existsSync(packageJsonPath)) {
@@ -55089,7 +55092,7 @@ const doBuild = async (args, downloadResult) => {
55089
55092
  cwd: args.workPath,
55090
55093
  out: defaultOutputDirectory
55091
55094
  });
55092
- tsPromise = buildResult.tsPromise;
55095
+ tsPromise = buildResult.tsPromise ?? void 0;
55093
55096
  const { handler: handler$1 } = await getBuildSummary(buildResult.rolldownResult.outputDir);
55094
55097
  return {
55095
55098
  dir: buildResult.rolldownResult.outputDir,
@@ -55103,7 +55106,7 @@ const doBuild = async (args, downloadResult) => {
55103
55106
  cwd: args.workPath,
55104
55107
  out: outputDir
55105
55108
  });
55106
- tsPromise = buildResult.tsPromise;
55109
+ tsPromise = buildResult.tsPromise ?? void 0;
55107
55110
  const { handler: handler$1 } = await getBuildSummary(buildResult.rolldownResult.outputDir);
55108
55111
  return {
55109
55112
  dir: buildResult.rolldownResult.outputDir,
@@ -55141,14 +55144,18 @@ const version = 2;
55141
55144
  const build = async (args) => {
55142
55145
  const downloadResult = await downloadInstallAndBundle(args);
55143
55146
  const outputConfig = await doBuild(args, downloadResult);
55144
- const { files } = await nodeFileTrace$1(args, outputConfig);
55147
+ const { files } = await nodeFileTrace$1(args, downloadResult, outputConfig);
55148
+ (0, import_dist.debug)("Building route mapping..");
55145
55149
  const { routes, framework } = await introspectApp({
55146
55150
  ...outputConfig,
55151
+ framework: args.config.framework,
55147
55152
  env: {
55148
55153
  ...args.meta?.env ?? {},
55149
55154
  ...args.meta?.buildEnv ?? {}
55150
55155
  }
55151
55156
  });
55157
+ if (routes.length > 2) (0, import_dist.debug)(`Route mapping built successfully with ${routes.length} routes`);
55158
+ else (0, import_dist.debug)(`Route mapping failed to detect routes`);
55152
55159
  const handler = relative$1(args.repoRootPath, join$1(outputConfig.dir, outputConfig.handler));
55153
55160
  const lambda = new import_dist.NodejsLambda({
55154
55161
  runtime: downloadResult.nodeVersion.runtime,
@@ -55156,7 +55163,10 @@ const build = async (args) => {
55156
55163
  files,
55157
55164
  shouldAddHelpers: false,
55158
55165
  shouldAddSourcemapSupport: true,
55159
- framework,
55166
+ framework: {
55167
+ slug: framework?.slug ?? "",
55168
+ version: framework?.version ?? ""
55169
+ },
55160
55170
  awsLambdaHandler: ""
55161
55171
  });
55162
55172
  const output = { index: lambda };
@@ -55170,6 +55180,9 @@ const build = async (args) => {
55170
55180
  output
55171
55181
  };
55172
55182
  };
55183
+ const prepareCache = ({ repoRootPath, workPath }) => {
55184
+ return (0, import_dist.glob)(import_dist.defaultCachePathGlob, repoRootPath || workPath);
55185
+ };
55173
55186
 
55174
55187
  //#endregion
55175
- export { build, version };
55188
+ export { build, prepareCache, version };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vercel/backends",
3
- "version": "0.0.8",
3
+ "version": "0.0.10",
4
4
  "license": "Apache-2.0",
5
5
  "main": "./dist/index.mjs",
6
6
  "homepage": "https://vercel.com/docs",
@@ -25,7 +25,7 @@
25
25
  "@vercel/static-config": "3.1.2",
26
26
  "fs-extra": "11.1.0",
27
27
  "rolldown": "1.0.0-beta.35",
28
- "@vercel/cervel": "0.0.4",
28
+ "@vercel/cervel": "0.0.6",
29
29
  "@vercel/introspection": "0.0.2"
30
30
  },
31
31
  "devDependencies": {
@@ -33,7 +33,7 @@
33
33
  "@types/fs-extra": "11",
34
34
  "@types/jest": "27.5.1",
35
35
  "@types/node": "22",
36
- "@vercel/build-utils": "13.0.1",
36
+ "@vercel/build-utils": "13.1.0",
37
37
  "execa": "3.2.0",
38
38
  "hono": "4.10.1",
39
39
  "jest-junit": "16.0.0",