vercel 54.3.0 → 54.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/dist/chunks/{add-6BI52GC7.js → add-6XIRI7GJ.js} +4 -4
  2. package/dist/chunks/{chunk-AKWLMA5B.js → chunk-4VFNBXZ2.js} +1 -1
  3. package/dist/chunks/{chunk-63MSANDD.js → chunk-4W26QRXA.js} +4 -4
  4. package/dist/chunks/{chunk-4KGRBMBC.js → chunk-ASARRYQ2.js} +5 -5
  5. package/dist/chunks/{chunk-3NTROBCB.js → chunk-BTQ6HRS4.js} +1 -1
  6. package/dist/chunks/{chunk-R6QYB2GK.js → chunk-CPI4NTRV.js} +2 -2
  7. package/dist/chunks/{chunk-SRLTKHXQ.js → chunk-F23AADZM.js} +3 -3
  8. package/dist/chunks/{chunk-HFVP2JUO.js → chunk-FVMTH5YE.js} +2 -2
  9. package/dist/chunks/{chunk-PU4PEBGY.js → chunk-HE7FK57F.js} +1 -1
  10. package/dist/chunks/{chunk-SJAFZ3UZ.js → chunk-KW4SFTHO.js} +9 -6
  11. package/dist/chunks/{chunk-RNIZUKES.js → chunk-L3JT6XDK.js} +185 -139
  12. package/dist/chunks/{chunk-W64ECC2K.js → chunk-LHB57VQA.js} +1 -1
  13. package/dist/chunks/{chunk-SXYVZF6H.js → chunk-MZM2IMEM.js} +1 -1
  14. package/dist/chunks/{chunk-B3RJGSB2.js → chunk-PHZ7DOO3.js} +1 -1
  15. package/dist/chunks/{chunk-5TTQBT67.js → chunk-QYUIKYIF.js} +1 -1
  16. package/dist/chunks/{chunk-GJI2IQHA.js → chunk-RIRQQSUQ.js} +1 -1
  17. package/dist/chunks/{chunk-7UDM3VHD.js → chunk-SFCULGGZ.js} +1 -1
  18. package/dist/chunks/{chunk-EU5K7JFJ.js → chunk-UDG7NUUQ.js} +2 -2
  19. package/dist/chunks/{chunk-PXR6WCEU.js → chunk-XPQUP4VC.js} +3 -3
  20. package/dist/chunks/{chunk-ZUK6C2UA.js → chunk-YQS3X3N5.js} +1 -1
  21. package/dist/chunks/{compile-vercel-config-UTUECEB5.js → compile-vercel-config-5WZ2LFBA.js} +1 -1
  22. package/dist/chunks/{delete-FML7PGMQ.js → delete-JB4S3TTR.js} +2 -2
  23. package/dist/chunks/{disable-LJFGBJQD.js → disable-Y5MQYBZT.js} +2 -2
  24. package/dist/chunks/{discard-JKLUB56V.js → discard-DNGSXOP5.js} +2 -2
  25. package/dist/chunks/{edit-24LNAGLI.js → edit-FHYSRIAM.js} +3 -3
  26. package/dist/chunks/{enable-XV6WCSRR.js → enable-TI7IDW4D.js} +2 -2
  27. package/dist/chunks/{export-IZAJQNHO.js → export-DGCLBJXG.js} +2 -2
  28. package/dist/chunks/{inspect-4OYBTMEZ.js → inspect-YSEEB6K3.js} +3 -3
  29. package/dist/chunks/{list-PEXOOVJA.js → list-2IC4JQ7V.js} +2 -2
  30. package/dist/chunks/{list-FOLL3X7L.js → list-K2E7LRUZ.js} +3 -3
  31. package/dist/chunks/{ls-3D5FA5CD.js → ls-LV3EOIGK.js} +4 -4
  32. package/dist/chunks/{publish-FV5R2JPI.js → publish-UCZDXEVP.js} +2 -2
  33. package/dist/chunks/{query-JM422UQL.js → query-YS24VBYT.js} +2 -2
  34. package/dist/chunks/{reorder-H5VPRRYP.js → reorder-5PEIRI7B.js} +2 -2
  35. package/dist/chunks/{restore-JPFHV2E2.js → restore-BNKCGWUN.js} +2 -2
  36. package/dist/chunks/{rm-AQFIGZB7.js → rm-MMZJTUSV.js} +4 -4
  37. package/dist/chunks/{rule-inspect-XV56NBAE.js → rule-inspect-45WAIMAY.js} +4 -4
  38. package/dist/chunks/{rules-SUXFDKPS.js → rules-F7NTLPKL.js} +6 -6
  39. package/dist/chunks/{schema-3I4KYWU3.js → schema-V33O6TZC.js} +2 -2
  40. package/dist/chunks/{update-3W7ETGXO.js → update-LSMYRPF7.js} +4 -4
  41. package/dist/commands/build/index.js +12 -12
  42. package/dist/commands/deploy/index.js +10 -10
  43. package/dist/commands/dev/index.js +16 -16
  44. package/dist/commands/env/index.js +4 -4
  45. package/dist/commands/link/index.js +7 -7
  46. package/dist/commands/list/index.js +3 -3
  47. package/dist/commands-bulk.js +31 -31
  48. package/dist/index.js +8 -8
  49. package/dist/version.mjs +1 -1
  50. package/package.json +20 -20
@@ -13816,7 +13816,7 @@ var require_frameworks = __commonJS({
13816
13816
  frameworks: () => frameworks
13817
13817
  });
13818
13818
  module.exports = __toCommonJS2(frameworks_exports);
13819
- var import_path11 = __require("path");
13819
+ var import_path12 = __require("path");
13820
13820
  var import_fs4 = __require("fs");
13821
13821
  var import_read_config_file = require_read_config_file();
13822
13822
  __reExport(frameworks_exports, require_types(), module.exports);
@@ -13943,7 +13943,7 @@ var require_frameworks = __commonJS({
13943
13943
  getOutputDirName: async () => "public",
13944
13944
  defaultRoutes: async (dirPrefix) => {
13945
13945
  try {
13946
- const nowRoutesPath = (0, import_path11.join)(
13946
+ const nowRoutesPath = (0, import_path12.join)(
13947
13947
  dirPrefix,
13948
13948
  "public",
13949
13949
  "__now_routes_g4t5bY.json"
@@ -14231,10 +14231,10 @@ var require_frameworks = __commonJS({
14231
14231
  getOutputDirName: async (dirPrefix) => {
14232
14232
  const base = "build";
14233
14233
  try {
14234
- const location = (0, import_path11.join)(dirPrefix, base);
14234
+ const location = (0, import_path12.join)(dirPrefix, base);
14235
14235
  const content = await readdir(location, { withFileTypes: true });
14236
14236
  if (content.length === 1 && content[0].isDirectory()) {
14237
- return (0, import_path11.join)(base, content[0].name);
14237
+ return (0, import_path12.join)(base, content[0].name);
14238
14238
  }
14239
14239
  } catch (error) {
14240
14240
  console.error(`Error detecting output directory: `, error);
@@ -14312,10 +14312,10 @@ var require_frameworks = __commonJS({
14312
14312
  getOutputDirName: async (dirPrefix) => {
14313
14313
  const base = "build";
14314
14314
  try {
14315
- const location = (0, import_path11.join)(dirPrefix, base);
14315
+ const location = (0, import_path12.join)(dirPrefix, base);
14316
14316
  const content = await readdir(location, { withFileTypes: true });
14317
14317
  if (content.length === 1 && content[0].isDirectory()) {
14318
- return (0, import_path11.join)(base, content[0].name);
14318
+ return (0, import_path12.join)(base, content[0].name);
14319
14319
  }
14320
14320
  } catch (error) {
14321
14321
  console.error(`Error detecting output directory: `, error);
@@ -14476,7 +14476,7 @@ var require_frameworks = __commonJS({
14476
14476
  }
14477
14477
  },
14478
14478
  dependency: "@dojo/cli",
14479
- getOutputDirName: async () => (0, import_path11.join)("output", "dist"),
14479
+ getOutputDirName: async () => (0, import_path12.join)("output", "dist"),
14480
14480
  defaultRoutes: [
14481
14481
  {
14482
14482
  handle: "filesystem"
@@ -14711,11 +14711,11 @@ var require_frameworks = __commonJS({
14711
14711
  getOutputDirName: async (dirPrefix) => {
14712
14712
  const base = "dist";
14713
14713
  try {
14714
- const location = (0, import_path11.join)(dirPrefix, base);
14714
+ const location = (0, import_path12.join)(dirPrefix, base);
14715
14715
  const content = await readdir(location, { withFileTypes: true });
14716
14716
  if (content.length === 1 && content[0].isDirectory()) {
14717
- const potentialOutDir = (0, import_path11.join)(base, content[0].name);
14718
- const potentialOutDirWithBrowser = (0, import_path11.join)(potentialOutDir, "browser");
14717
+ const potentialOutDir = (0, import_path12.join)(base, content[0].name);
14718
+ const potentialOutDirWithBrowser = (0, import_path12.join)(potentialOutDir, "browser");
14719
14719
  return (0, import_fs4.existsSync)(potentialOutDirWithBrowser) ? potentialOutDirWithBrowser : potentialOutDir;
14720
14720
  }
14721
14721
  } catch (error) {
@@ -14768,10 +14768,10 @@ var require_frameworks = __commonJS({
14768
14768
  getOutputDirName: async (dirPrefix) => {
14769
14769
  const base = "build";
14770
14770
  try {
14771
- const location = (0, import_path11.join)(dirPrefix, base);
14771
+ const location = (0, import_path12.join)(dirPrefix, base);
14772
14772
  const content = await readdir(location);
14773
14773
  const paths = content.filter((item) => !item.includes("."));
14774
- return (0, import_path11.join)(base, paths[0]);
14774
+ return (0, import_path12.join)(base, paths[0]);
14775
14775
  } catch (error) {
14776
14776
  console.error(`Error detecting output directory: `, error);
14777
14777
  }
@@ -15389,7 +15389,7 @@ var require_frameworks = __commonJS({
15389
15389
  getOutputDirName: async (dirPrefix) => {
15390
15390
  const config = await (0, import_read_config_file.readConfigFile)(
15391
15391
  ["config.json", "config.yaml", "config.toml"].map((fileName) => {
15392
- return (0, import_path11.join)(dirPrefix, fileName);
15392
+ return (0, import_path12.join)(dirPrefix, fileName);
15393
15393
  })
15394
15394
  );
15395
15395
  return config && config.publishDir || "public";
@@ -15430,7 +15430,7 @@ var require_frameworks = __commonJS({
15430
15430
  },
15431
15431
  getOutputDirName: async (dirPrefix) => {
15432
15432
  const config = await (0, import_read_config_file.readConfigFile)(
15433
- (0, import_path11.join)(dirPrefix, "_config.yml")
15433
+ (0, import_path12.join)(dirPrefix, "_config.yml")
15434
15434
  );
15435
15435
  return config && config.destination || "_site";
15436
15436
  },
@@ -22670,14 +22670,14 @@ var require_utils3 = __commonJS({
22670
22670
  __export2(utils_exports, {
22671
22671
  DETECTION_FRAMEWORKS: () => DETECTION_FRAMEWORKS,
22672
22672
  INTERNAL_QUEUES_PREFIX: () => INTERNAL_QUEUES_PREFIX,
22673
- INTERNAL_SERVICE_PREFIX: () => import_build_utils5.INTERNAL_SERVICE_PREFIX,
22673
+ INTERNAL_SERVICE_PREFIX: () => import_build_utils6.INTERNAL_SERVICE_PREFIX,
22674
22674
  assignRoutePrefixes: () => assignRoutePrefixes,
22675
22675
  combineBuildCommand: () => combineBuildCommand,
22676
22676
  filterFrameworksByRuntime: () => filterFrameworksByRuntime,
22677
22677
  getBuilderForRuntime: () => getBuilderForRuntime,
22678
- getInternalServiceCronPath: () => import_build_utils5.getInternalServiceCronPath,
22679
- getInternalServiceCronPathPrefix: () => import_build_utils5.getInternalServiceCronPathPrefix,
22680
- getInternalServiceFunctionPath: () => import_build_utils5.getInternalServiceFunctionPath,
22678
+ getInternalServiceCronPath: () => import_build_utils6.getInternalServiceCronPath,
22679
+ getInternalServiceCronPathPrefix: () => import_build_utils6.getInternalServiceCronPathPrefix,
22680
+ getInternalServiceFunctionPath: () => import_build_utils6.getInternalServiceFunctionPath,
22681
22681
  getInternalServiceWorkerPath: () => getInternalServiceWorkerPath2,
22682
22682
  getInternalServiceWorkerPathPrefix: () => getInternalServiceWorkerPathPrefix2,
22683
22683
  hasFile: () => hasFile,
@@ -22692,7 +22692,7 @@ var require_utils3 = __commonJS({
22692
22692
  });
22693
22693
  module.exports = __toCommonJS2(utils_exports);
22694
22694
  var import_framework_helpers = __require("@vercel/build-utils/dist/framework-helpers");
22695
- var import_build_utils5 = __require("@vercel/build-utils");
22695
+ var import_build_utils6 = __require("@vercel/build-utils");
22696
22696
  var import_frameworks2 = require_frameworks();
22697
22697
  var import_types = require_types3();
22698
22698
  var DETECTION_FRAMEWORKS = import_frameworks2.frameworkList.filter(
@@ -22723,7 +22723,7 @@ var require_utils3 = __commonJS({
22723
22723
  return normalized || "index";
22724
22724
  }
22725
22725
  function getInternalServiceWorkerPathPrefix2(serviceName) {
22726
- return `${import_build_utils5.INTERNAL_SERVICE_PREFIX}/${serviceName}/workers`;
22726
+ return `${import_build_utils6.INTERNAL_SERVICE_PREFIX}/${serviceName}/workers`;
22727
22727
  }
22728
22728
  function getInternalServiceWorkerPath2(serviceName, entrypoint, handler = "worker") {
22729
22729
  const normalizedEntrypoint = normalizeInternalServiceEntrypoint(entrypoint);
@@ -23158,8 +23158,8 @@ var require_resolve2 = __commonJS({
23158
23158
  validateServiceEntrypoint: () => validateServiceEntrypoint
23159
23159
  });
23160
23160
  module.exports = __toCommonJS2(resolve_exports);
23161
- var import_path11 = __require("path");
23162
- var import_build_utils5 = __require("@vercel/build-utils");
23161
+ var import_path12 = __require("path");
23162
+ var import_build_utils6 = __require("@vercel/build-utils");
23163
23163
  var import_types = require_types3();
23164
23164
  var import_utils4 = require_utils3();
23165
23165
  var import_frameworks2 = require_frameworks();
@@ -23189,7 +23189,7 @@ var require_resolve2 = __commonJS({
23189
23189
  if (!root) {
23190
23190
  return { fs: fs5 };
23191
23191
  }
23192
- const normalizedRoot = import_path11.posix.normalize(root);
23192
+ const normalizedRoot = import_path12.posix.normalize(root);
23193
23193
  if (!await fs5.hasPath(normalizedRoot)) {
23194
23194
  return {
23195
23195
  fs: fs5,
@@ -23213,7 +23213,7 @@ var require_resolve2 = __commonJS({
23213
23213
  return { fs: fs5.chdir(normalizedRoot) };
23214
23214
  }
23215
23215
  function normalizeServiceEntrypoint(entrypoint) {
23216
- const normalized = import_path11.posix.normalize(entrypoint);
23216
+ const normalized = import_path12.posix.normalize(entrypoint);
23217
23217
  return normalized === "" ? "." : normalized;
23218
23218
  }
23219
23219
  function getEffectiveServiceTrigger(config) {
@@ -23271,7 +23271,7 @@ var require_resolve2 = __commonJS({
23271
23271
  };
23272
23272
  }
23273
23273
  function toWorkspaceRelativeEntrypoint(entrypoint, workspace) {
23274
- const normalizedEntrypoint = import_path11.posix.normalize(entrypoint);
23274
+ const normalizedEntrypoint = import_path12.posix.normalize(entrypoint);
23275
23275
  if (workspace === ".") {
23276
23276
  return normalizedEntrypoint;
23277
23277
  }
@@ -23279,7 +23279,7 @@ var require_resolve2 = __commonJS({
23279
23279
  if (normalizedEntrypoint.startsWith(workspacePrefix)) {
23280
23280
  return normalizedEntrypoint.slice(workspacePrefix.length);
23281
23281
  }
23282
- const relativeEntrypoint = import_path11.posix.relative(
23282
+ const relativeEntrypoint = import_path12.posix.relative(
23283
23283
  workspace,
23284
23284
  normalizedEntrypoint
23285
23285
  );
@@ -23300,14 +23300,14 @@ var require_resolve2 = __commonJS({
23300
23300
  if (!manifests || manifests.length === 0) {
23301
23301
  return void 0;
23302
23302
  }
23303
- let dir = import_path11.posix.dirname(import_path11.posix.normalize(entrypoint)) || ".";
23303
+ let dir = import_path12.posix.dirname(import_path12.posix.normalize(entrypoint)) || ".";
23304
23304
  if (dir === "") {
23305
23305
  dir = ".";
23306
23306
  }
23307
23307
  let reachedRoot = false;
23308
23308
  while (!reachedRoot) {
23309
23309
  for (const manifest of manifests) {
23310
- const manifestPath = dir === "." ? manifest : import_path11.posix.join(dir, manifest);
23310
+ const manifestPath = dir === "." ? manifest : import_path12.posix.join(dir, manifest);
23311
23311
  if (await (0, import_utils4.hasFile)(fs5, manifestPath)) {
23312
23312
  return dir;
23313
23313
  }
@@ -23315,7 +23315,7 @@ var require_resolve2 = __commonJS({
23315
23315
  if (dir === "." || dir === "/") {
23316
23316
  reachedRoot = true;
23317
23317
  } else {
23318
- const parent = import_path11.posix.dirname(dir);
23318
+ const parent = import_path12.posix.dirname(dir);
23319
23319
  if (!parent || parent === dir) {
23320
23320
  reachedRoot = true;
23321
23321
  } else {
@@ -23458,8 +23458,8 @@ var require_resolve2 = __commonJS({
23458
23458
  trigger: effectiveTrigger
23459
23459
  };
23460
23460
  const isJobService = serviceType === "job" || serviceType === "cron";
23461
- const isScheduleJobService = (0, import_build_utils5.isScheduleTriggeredService)(effectiveService);
23462
- const isQueueJobService = serviceType === "job" && (0, import_build_utils5.isQueueTriggeredService)(effectiveService);
23461
+ const isScheduleJobService = (0, import_build_utils6.isScheduleTriggeredService)(effectiveService);
23462
+ const isQueueJobService = serviceType === "job" && (0, import_build_utils6.isQueueTriggeredService)(effectiveService);
23463
23463
  const isWorkflowService = serviceType === "job" && effectiveTrigger === "workflow";
23464
23464
  const isNonWebService = serviceType === "worker" || isJobService;
23465
23465
  const serviceTypeLabel = isJobService ? "Job" : serviceType === "worker" ? "Worker" : "Web";
@@ -23513,10 +23513,10 @@ var require_resolve2 = __commonJS({
23513
23513
  serviceName: name
23514
23514
  };
23515
23515
  }
23516
- if (serviceType === "job" && effectiveTrigger && !import_build_utils5.JOB_TRIGGERS.includes(effectiveTrigger)) {
23516
+ if (serviceType === "job" && effectiveTrigger && !import_build_utils6.JOB_TRIGGERS.includes(effectiveTrigger)) {
23517
23517
  return {
23518
23518
  code: "INVALID_JOB_TRIGGER",
23519
- message: `Job service "${name}" has invalid trigger "${effectiveTrigger}". Expected ${import_build_utils5.JOB_TRIGGERS.map((t) => `"${t}"`).join(", ")}.`,
23519
+ message: `Job service "${name}" has invalid trigger "${effectiveTrigger}". Expected ${import_build_utils6.JOB_TRIGGERS.map((t) => `"${t}"`).join(", ")}.`,
23520
23520
  serviceName: name
23521
23521
  };
23522
23522
  }
@@ -23542,7 +23542,7 @@ var require_resolve2 = __commonJS({
23542
23542
  };
23543
23543
  }
23544
23544
  if (config.root !== void 0) {
23545
- const normalizedRoot = import_path11.posix.normalize(config.root);
23545
+ const normalizedRoot = import_path12.posix.normalize(config.root);
23546
23546
  if (normalizedRoot.startsWith("/")) {
23547
23547
  return {
23548
23548
  code: "INVALID_ROOT",
@@ -23730,12 +23730,12 @@ var require_resolve2 = __commonJS({
23730
23730
  }
23731
23731
  }
23732
23732
  if (root) {
23733
- const normalizedRoot = import_path11.posix.normalize(root);
23733
+ const normalizedRoot = import_path12.posix.normalize(root);
23734
23734
  if (normalizedRoot !== ".") {
23735
- workspace = workspace === "." ? normalizedRoot : import_path11.posix.join(normalizedRoot, workspace);
23735
+ workspace = workspace === "." ? normalizedRoot : import_path12.posix.join(normalizedRoot, workspace);
23736
23736
  }
23737
23737
  }
23738
- const topics = type === "worker" ? (0, import_build_utils5.getServiceQueueTopics)({ type, topics: config.topics }) : trigger === "queue" ? config.topics : void 0;
23738
+ const topics = type === "worker" ? (0, import_build_utils6.getServiceQueueTopics)({ type, topics: config.topics }) : trigger === "queue" ? config.topics : trigger === "workflow" ? ["__wkf_*"] : void 0;
23739
23739
  let builderUse;
23740
23740
  let builderSrc;
23741
23741
  const frameworkDefinition = config.framework ? frameworksBySlug.get(config.framework) : void 0;
@@ -23743,7 +23743,7 @@ var require_resolve2 = __commonJS({
23743
23743
  builderUse = config.builder;
23744
23744
  builderSrc = resolvedEntrypointFile || frameworkDefinition?.useRuntime?.src || "package.json";
23745
23745
  } else if (config.framework) {
23746
- const isCronService = (0, import_build_utils5.isScheduleTriggeredService)({ type, trigger });
23746
+ const isCronService = (0, import_build_utils6.isScheduleTriggeredService)({ type, trigger });
23747
23747
  if ((0, import_build_utils22.isNodeBackendFramework)(config.framework) && (type === "web" || isCronService)) {
23748
23748
  builderUse = "@vercel/backends";
23749
23749
  } else {
@@ -23757,7 +23757,7 @@ var require_resolve2 = __commonJS({
23757
23757
  );
23758
23758
  }
23759
23759
  if (inferredRuntime === "node") {
23760
- const isCronService = (0, import_build_utils5.isScheduleTriggeredService)({ type, trigger });
23760
+ const isCronService = (0, import_build_utils6.isScheduleTriggeredService)({ type, trigger });
23761
23761
  builderUse = type === "web" || isCronService ? "@vercel/backends" : "@vercel/node";
23762
23762
  } else {
23763
23763
  builderUse = (0, import_utils4.getBuilderForRuntime)(inferredRuntime);
@@ -23770,7 +23770,7 @@ var require_resolve2 = __commonJS({
23770
23770
  const resolvedRoutePrefixSource = type === "web" && typeof routePrefix === "string" ? routePrefixWasConfigured ? routePrefixSource : "generated" : void 0;
23771
23771
  const isRoot = workspace === ".";
23772
23772
  if (!isRoot) {
23773
- builderSrc = import_path11.posix.join(workspace, builderSrc);
23773
+ builderSrc = import_path12.posix.join(workspace, builderSrc);
23774
23774
  }
23775
23775
  const builderConfig = { zeroConfig: true };
23776
23776
  if (builderUse === "@vercel/backends") {
@@ -23919,7 +23919,7 @@ var require_resolve2 = __commonJS({
23919
23919
  entrypoint: resolvedEntrypoint.normalized,
23920
23920
  runtime: inferredRuntime
23921
23921
  });
23922
- const workspace = inferredWorkspace ?? import_path11.posix.dirname(resolvedEntrypoint.normalized);
23922
+ const workspace = inferredWorkspace ?? import_path12.posix.dirname(resolvedEntrypoint.normalized);
23923
23923
  const detection = await detectFrameworkFromWorkspace({
23924
23924
  fs: serviceFs,
23925
23925
  workspace,
@@ -24319,7 +24319,7 @@ var require_detect_railway = __commonJS({
24319
24319
  detectRailwayServices: () => detectRailwayServices
24320
24320
  });
24321
24321
  module.exports = __toCommonJS2(detect_railway_exports);
24322
- var import_path11 = __require("path");
24322
+ var import_path12 = __require("path");
24323
24323
  var import_smol_toml3 = __toESM2(__require("smol-toml"));
24324
24324
  var import_detect_framework = require_detect_framework();
24325
24325
  var import_utils4 = require_utils3();
@@ -24467,7 +24467,7 @@ var require_detect_railway = __commonJS({
24467
24467
  if (entry.type !== "dir" || SKIP_DIRS.has(entry.name)) {
24468
24468
  continue;
24469
24469
  }
24470
- const childPath = dirPath === "." ? entry.name : import_path11.posix.join(dirPath, entry.name);
24470
+ const childPath = dirPath === "." ? entry.name : import_path12.posix.join(dirPath, entry.name);
24471
24471
  const child = await findRailwayConfigs(fs5, childPath, depth + 1);
24472
24472
  configs.push(...child.configs);
24473
24473
  warnings.push(...child.warnings);
@@ -24477,7 +24477,7 @@ var require_detect_railway = __commonJS({
24477
24477
  async function readRailwayConfigRaw(fs5, dirPath) {
24478
24478
  const warnings = [];
24479
24479
  for (const filename of [RAILWAY_JSON, RAILWAY_TOML]) {
24480
- const filePath = dirPath === "." ? filename : import_path11.posix.join(dirPath, filename);
24480
+ const filePath = dirPath === "." ? filename : import_path12.posix.join(dirPath, filename);
24481
24481
  try {
24482
24482
  const exists = await fs5.isFile(filePath);
24483
24483
  if (!exists)
@@ -27439,7 +27439,7 @@ var require_detect_render = __commonJS({
27439
27439
  static: "web"
27440
27440
  };
27441
27441
  async function detectRenderServices(options) {
27442
- const { fs: fs5 } = options;
27442
+ const { fs: fs5, detectEntrypoint } = options;
27443
27443
  const raw = await readRenderYaml(fs5);
27444
27444
  if (raw.warning) {
27445
27445
  return { services: null, errors: [], warnings: [raw.warning] };
@@ -27563,7 +27563,16 @@ var require_detect_render = __commonJS({
27563
27563
  serviceConfig.type = vercelType;
27564
27564
  serviceConfig.framework = framework.slug ?? void 0;
27565
27565
  if (rootDir !== ".") {
27566
- serviceConfig.entrypoint = rootDir;
27566
+ serviceConfig.root = rootDir;
27567
+ if (detectEntrypoint && !(0, import_utils4.isFrontendFramework)(serviceConfig.framework)) {
27568
+ const detected = await detectEntrypoint({
27569
+ workPath: rootDir,
27570
+ framework: serviceConfig.framework
27571
+ });
27572
+ if (detected) {
27573
+ serviceConfig.entrypoint = detected.entrypoint;
27574
+ }
27575
+ }
27567
27576
  }
27568
27577
  const buildCommand = (0, import_utils4.combineBuildCommand)(
27569
27578
  rs.buildCommand,
@@ -27894,7 +27903,7 @@ var require_detect_services = __commonJS({
27894
27903
  generateServicesRoutes: () => generateServicesRoutes2
27895
27904
  });
27896
27905
  module.exports = __toCommonJS2(detect_services_exports);
27897
- var import_build_utils5 = __require("@vercel/build-utils");
27906
+ var import_build_utils6 = __require("@vercel/build-utils");
27898
27907
  var import_routing_utils2 = require_dist5();
27899
27908
  var import_utils4 = require_utils3();
27900
27909
  var import_resolve = require_resolve2();
@@ -28164,7 +28173,7 @@ var require_detect_services = __commonJS({
28164
28173
  }
28165
28174
  }
28166
28175
  }
28167
- const cronServices = services.filter(import_build_utils5.isScheduleTriggeredService);
28176
+ const cronServices = services.filter(import_build_utils6.isScheduleTriggeredService);
28168
28177
  for (const service of cronServices) {
28169
28178
  const cronPrefix = (0, import_utils4.getInternalServiceCronPathPrefix)(service.name);
28170
28179
  const functionPath = (0, import_utils4.getInternalServiceFunctionPath)(service.name);
@@ -28237,7 +28246,7 @@ var require_filesystem = __commonJS({
28237
28246
  DetectorFilesystem: () => DetectorFilesystem2
28238
28247
  });
28239
28248
  module.exports = __toCommonJS2(filesystem_exports);
28240
- var import_path11 = __require("path");
28249
+ var import_path12 = __require("path");
28241
28250
  var DetectorFilesystem2 = class {
28242
28251
  constructor() {
28243
28252
  this.hasPath = async (path) => {
@@ -28281,13 +28290,13 @@ var require_filesystem = __commonJS({
28281
28290
  }
28282
28291
  if (options?.potentialFiles) {
28283
28292
  const filesInReaddirDir = options.potentialFiles.filter(
28284
- (path) => (0, import_path11.basename)(path) === path
28293
+ (path) => (0, import_path12.basename)(path) === path
28285
28294
  );
28286
28295
  const filesThatDoNotExist = filesInReaddirDir.filter(
28287
28296
  (path) => !directoryFiles.has(path)
28288
28297
  );
28289
28298
  for (const filePath of filesThatDoNotExist) {
28290
- const fullFilePath = dirPath === "/" ? filePath : import_path11.posix.join(dirPath, filePath);
28299
+ const fullFilePath = dirPath === "/" ? filePath : import_path12.posix.join(dirPath, filePath);
28291
28300
  this.fileCache.set(fullFilePath, Promise.resolve(false));
28292
28301
  this.pathCache.set(fullFilePath, Promise.resolve(false));
28293
28302
  }
@@ -28348,7 +28357,7 @@ var require_local_file_system_detector = __commonJS({
28348
28357
  });
28349
28358
  module.exports = __toCommonJS2(local_file_system_detector_exports);
28350
28359
  var import_promises4 = __toESM2(__require("fs/promises"));
28351
- var import_path11 = __require("path");
28360
+ var import_path12 = __require("path");
28352
28361
  var import_filesystem = require_filesystem();
28353
28362
  var import_error_utils5 = require_dist();
28354
28363
  var LocalFileSystemDetector4 = class _LocalFileSystemDetector extends import_filesystem.DetectorFilesystem {
@@ -28389,7 +28398,7 @@ var require_local_file_system_detector = __commonJS({
28389
28398
  }
28390
28399
  result.push({
28391
28400
  name: entry.name,
28392
- path: (0, import_path11.join)(this.getRelativeFilePath(dir), entry.name),
28401
+ path: (0, import_path12.join)(this.getRelativeFilePath(dir), entry.name),
28393
28402
  type
28394
28403
  });
28395
28404
  }
@@ -28399,10 +28408,10 @@ var require_local_file_system_detector = __commonJS({
28399
28408
  return new _LocalFileSystemDetector(this.getFilePath(name));
28400
28409
  }
28401
28410
  getRelativeFilePath(name) {
28402
- return name.startsWith(this.rootPath) ? (0, import_path11.relative)(this.rootPath, name) : name;
28411
+ return name.startsWith(this.rootPath) ? (0, import_path12.relative)(this.rootPath, name) : name;
28403
28412
  }
28404
28413
  getFilePath(name) {
28405
- return (0, import_path11.join)(this.rootPath, this.getRelativeFilePath(name));
28414
+ return (0, import_path12.join)(this.rootPath, this.getRelativeFilePath(name));
28406
28415
  }
28407
28416
  };
28408
28417
  }
@@ -28586,10 +28595,10 @@ var require_detect_builders = __commonJS({
28586
28595
  module.exports = __toCommonJS2(detect_builders_exports);
28587
28596
  var import_minimatch = __toESM2(require_minimatch());
28588
28597
  var import_semver = require_semver();
28589
- var import_path11 = __require("path");
28598
+ var import_path12 = __require("path");
28590
28599
  var import_frameworks2 = require_frameworks();
28591
28600
  var import_is_official_runtime = require_is_official_runtime();
28592
- var import_build_utils5 = __require("@vercel/build-utils");
28601
+ var import_build_utils6 = __require("@vercel/build-utils");
28593
28602
  var import_get_services_builders = require_get_services_builders();
28594
28603
  var REGEX_MIDDLEWARE_FILES = "middleware.[jt]s";
28595
28604
  var REGEX_VERCEL_PLATFORM_FILES = [
@@ -28616,7 +28625,7 @@ var require_detect_builders = __commonJS({
28616
28625
  return new Set(
28617
28626
  builders.filter(
28618
28627
  (b) => Boolean(b.config && b.config.zeroConfig && b.src?.startsWith("api/"))
28619
- ).map((b) => (0, import_path11.extname)(b.src)).filter(Boolean)
28628
+ ).map((b) => (0, import_path12.extname)(b.src)).filter(Boolean)
28620
28629
  );
28621
28630
  }
28622
28631
  function detectApiDirectory2(builders) {
@@ -28865,16 +28874,16 @@ var require_detect_builders = __commonJS({
28865
28874
  return null;
28866
28875
  }
28867
28876
  if (fileName.endsWith(".py") && options.workPath) {
28868
- const fsPath = (0, import_path11.join)(options.workPath, fileName);
28869
- const isEntrypoint = await (0, import_build_utils5.isPythonEntrypoint)({ fsPath });
28877
+ const fsPath = (0, import_path12.join)(options.workPath, fileName);
28878
+ const isEntrypoint = await (0, import_build_utils6.isPythonEntrypoint)({ fsPath });
28870
28879
  if (!isEntrypoint) {
28871
28880
  return null;
28872
28881
  }
28873
28882
  }
28874
28883
  const nodeExtensions = [".js", ".mjs", ".ts", ".tsx"];
28875
28884
  if (fileName.startsWith("api/") && process.env.VERCEL_NODE_FILTER_ENTRYPOINTS === "1" && nodeExtensions.some((ext) => fileName.endsWith(ext)) && options.workPath) {
28876
- const fsPath = (0, import_path11.join)(options.workPath, fileName);
28877
- const isEntrypoint = await (0, import_build_utils5.isNodeEntrypoint)({ fsPath });
28885
+ const fsPath = (0, import_path12.join)(options.workPath, fileName);
28886
+ const isEntrypoint = await (0, import_build_utils6.isNodeEntrypoint)({ fsPath });
28878
28887
  if (!isEntrypoint) {
28879
28888
  return null;
28880
28889
  }
@@ -28984,8 +28993,8 @@ var require_detect_builders = __commonJS({
28984
28993
  const f = slugToFramework.get(framework || "");
28985
28994
  if (f && f.useRuntime) {
28986
28995
  const { src, use } = f.useRuntime;
28987
- const shouldUseUnifiedBackend = (0, import_build_utils5.isExperimentalBackendsEnabled)() && import_build_utils5.BACKEND_BUILDERS.includes(use);
28988
- const finalUse = shouldUseUnifiedBackend ? import_build_utils5.UNIFIED_BACKEND_BUILDER : use;
28996
+ const shouldUseUnifiedBackend = (0, import_build_utils6.isExperimentalBackendsEnabled)() && import_build_utils6.BACKEND_BUILDERS.includes(use);
28997
+ const finalUse = shouldUseUnifiedBackend ? import_build_utils6.UNIFIED_BACKEND_BUILDER : use;
28989
28998
  return { src, use: `${finalUse}${withTag}`, config };
28990
28999
  }
28991
29000
  const entrypoints = /* @__PURE__ */ new Set([
@@ -29162,14 +29171,14 @@ var require_detect_builders = __commonJS({
29162
29171
  return null;
29163
29172
  }
29164
29173
  function getSegmentName(segment) {
29165
- const { name } = (0, import_path11.parse)(segment);
29174
+ const { name } = (0, import_path12.parse)(segment);
29166
29175
  if (name.startsWith("[") && name.endsWith("]")) {
29167
29176
  return name.slice(1, -1);
29168
29177
  }
29169
29178
  return null;
29170
29179
  }
29171
29180
  function getAbsolutePath(unresolvedPath) {
29172
- const { dir, name } = (0, import_path11.parse)(unresolvedPath);
29181
+ const { dir, name } = (0, import_path12.parse)(unresolvedPath);
29173
29182
  const parts = joinPath(dir, name).split("/");
29174
29183
  return parts.map((part) => part.replace(/\[.*\]/, "1")).join("/");
29175
29184
  }
@@ -29248,7 +29257,7 @@ var require_detect_builders = __commonJS({
29248
29257
  isDynamic = true;
29249
29258
  return `([^/]+)`;
29250
29259
  } else if (isLast) {
29251
- const { name: fileName2, ext: ext2 } = (0, import_path11.parse)(segment);
29260
+ const { name: fileName2, ext: ext2 } = (0, import_path12.parse)(segment);
29252
29261
  const isIndex2 = fileName2 === "index";
29253
29262
  const prefix = isIndex2 ? "/" : "";
29254
29263
  const names = [
@@ -29260,7 +29269,7 @@ var require_detect_builders = __commonJS({
29260
29269
  }
29261
29270
  return segment;
29262
29271
  });
29263
- const { name: fileName, ext } = (0, import_path11.parse)(filePath);
29272
+ const { name: fileName, ext } = (0, import_path12.parse)(filePath);
29264
29273
  const isIndex = fileName === "index";
29265
29274
  const queryString = `${query.length ? "?" : ""}${query.join("&")}`;
29266
29275
  const src = isIndex ? `^/${srcParts.slice(0, -1).join("/")}${srcParts.slice(-1)[0]}$` : `^/${srcParts.join("/")}$`;
@@ -29788,11 +29797,11 @@ var require_get_workspaces = __commonJS({
29788
29797
  getWorkspaces: () => getWorkspaces3
29789
29798
  });
29790
29799
  module.exports = __toCommonJS2(get_workspaces_exports);
29791
- var import_path11 = __toESM2(__require("path"));
29800
+ var import_path12 = __toESM2(__require("path"));
29792
29801
  var import_workspace_managers = require_workspace_managers();
29793
29802
  var import_detect_framework = require_detect_framework();
29794
29803
  var MAX_DEPTH_TRAVERSE = 3;
29795
- var posixPath = import_path11.default.posix;
29804
+ var posixPath = import_path12.default.posix;
29796
29805
  async function getWorkspaces3({
29797
29806
  fs: fs5,
29798
29807
  depth = MAX_DEPTH_TRAVERSE,
@@ -33243,12 +33252,12 @@ var require_get_workspace_package_paths = __commonJS({
33243
33252
  getWorkspacePackagePaths: () => getWorkspacePackagePaths3
33244
33253
  });
33245
33254
  module.exports = __toCommonJS2(get_workspace_package_paths_exports);
33246
- var import_path11 = __toESM2(__require("path"));
33255
+ var import_path12 = __toESM2(__require("path"));
33247
33256
  var import_js_yaml = __toESM2(require_js_yaml3());
33248
33257
  var import_glob = __toESM2(require_glob());
33249
33258
  var import_json5 = __toESM2(require_lib5());
33250
33259
  var import_get_glob_fs = require_get_glob_fs();
33251
- var posixPath = import_path11.default.posix;
33260
+ var posixPath = import_path12.default.posix;
33252
33261
  async function getWorkspacePackagePaths3({
33253
33262
  fs: fs5,
33254
33263
  workspace
@@ -33278,13 +33287,13 @@ var require_get_workspace_package_paths = __commonJS({
33278
33287
  });
33279
33288
  }
33280
33289
  var isWin = process.platform === "win32";
33281
- var normalizePath2 = (p) => isWin ? p.replace(/\\/g, "/") : p;
33290
+ var normalizePath3 = (p) => isWin ? p.replace(/\\/g, "/") : p;
33282
33291
  async function getPackagePaths(packages, fs5) {
33283
33292
  return (await Promise.all(
33284
33293
  packages.map(
33285
33294
  (packageGlob) => new Promise((resolve4, reject) => {
33286
33295
  (0, import_glob.default)(
33287
- normalizePath2(posixPath.join(packageGlob, "package.json")),
33296
+ normalizePath3(posixPath.join(packageGlob, "package.json")),
33288
33297
  {
33289
33298
  cwd: "/",
33290
33299
  fs: (0, import_get_glob_fs.getGlobFs)(fs5)
@@ -33615,7 +33624,7 @@ var require_get_monorepo_default_settings = __commonJS({
33615
33624
  getMonorepoDefaultSettings: () => getMonorepoDefaultSettings
33616
33625
  });
33617
33626
  module.exports = __toCommonJS2(get_monorepo_default_settings_exports);
33618
- var import_path11 = __require("path");
33627
+ var import_path12 = __require("path");
33619
33628
  var import_monorepo_managers = require_monorepo_managers();
33620
33629
  var import_package_managers = require_package_managers();
33621
33630
  var import_detect_framework = require_detect_framework();
@@ -33719,8 +33728,8 @@ var require_get_monorepo_default_settings = __commonJS({
33719
33728
  const nxJSON = import_json5.default.parse(nxJSONBuf.toString("utf-8"));
33720
33729
  if (!nxJSON?.targetDefaults?.build) {
33721
33730
  const [projectJSONBuf, packageJSONBuf] = await Promise.all([
33722
- detectorFilesystem.readFile((0, import_path11.join)(projectPath, "project.json")).catch(() => null),
33723
- detectorFilesystem.readFile((0, import_path11.join)(projectPath, "package.json")).catch(() => null)
33731
+ detectorFilesystem.readFile((0, import_path12.join)(projectPath, "project.json")).catch(() => null),
33732
+ detectorFilesystem.readFile((0, import_path12.join)(projectPath, "package.json")).catch(() => null)
33724
33733
  ]);
33725
33734
  let hasBuildTarget = false;
33726
33735
  if (projectJSONBuf) {
@@ -36622,7 +36631,7 @@ var require_package = __commonJS({
36622
36631
  "../client/package.json"(exports, module) {
36623
36632
  module.exports = {
36624
36633
  name: "@vercel/client",
36625
- version: "17.5.2",
36634
+ version: "17.5.3",
36626
36635
  main: "dist/index.js",
36627
36636
  typings: "dist/index.d.ts",
36628
36637
  homepage: "https://vercel.com",
@@ -36745,7 +36754,7 @@ var require_readdir_recursive = __commonJS({
36745
36754
  });
36746
36755
  module.exports = __toCommonJS2(readdir_recursive_exports);
36747
36756
  var import_fs4 = __toESM2(__require("fs"));
36748
- var import_path11 = __toESM2(__require("path"));
36757
+ var import_path12 = __toESM2(__require("path"));
36749
36758
  var import_minimatch = __toESM2(require_minimatch2());
36750
36759
  function patternMatcher(pattern) {
36751
36760
  return function(path, stats) {
@@ -36773,7 +36782,7 @@ var require_readdir_recursive = __commonJS({
36773
36782
  return resolve4(list2);
36774
36783
  }
36775
36784
  files.forEach(function(file) {
36776
- const filePath = import_path11.default.join(path, file);
36785
+ const filePath = import_path12.default.join(path, file);
36777
36786
  import_fs4.default.lstat(filePath, function(_err, stats) {
36778
36787
  if (_err) {
36779
36788
  return reject(_err);
@@ -44283,11 +44292,11 @@ var require_utils9 = __commonJS({
44283
44292
  });
44284
44293
  module.exports = __toCommonJS2(utils_exports);
44285
44294
  var import_node_fetch = __toESM2(require_lib2());
44286
- var import_path11 = __require("path");
44295
+ var import_path12 = __require("path");
44287
44296
  var import_url4 = __require("url");
44288
44297
  var import_ignore = __toESM2(require_ignore());
44289
44298
  var import_pkg = require_pkg();
44290
- var import_build_utils5 = __require("@vercel/build-utils");
44299
+ var import_build_utils6 = __require("@vercel/build-utils");
44291
44300
  var import_async_sema = require_lib7();
44292
44301
  var import_fs_extra9 = require_lib6();
44293
44302
  var import_readdir_recursive = __toESM2(require_readdir_recursive());
@@ -44359,7 +44368,7 @@ var require_utils9 = __commonJS({
44359
44368
  debug("Building file tree...");
44360
44369
  if (isDirectory2 && !Array.isArray(path)) {
44361
44370
  const ignores2 = (absPath) => {
44362
- const rel = (0, import_path11.relative)(path, absPath);
44371
+ const rel = (0, import_path12.relative)(path, absPath);
44363
44372
  const ignored = ig.ignores(rel);
44364
44373
  if (ignored) {
44365
44374
  ignoreList.push(rel);
@@ -44370,7 +44379,7 @@ var require_utils9 = __commonJS({
44370
44379
  const refs = /* @__PURE__ */ new Set();
44371
44380
  if (prebuilt) {
44372
44381
  const vcConfigFilePaths = fileList.filter(
44373
- (file) => (0, import_path11.basename)(file) === ".vc-config.json"
44382
+ (file) => (0, import_path12.basename)(file) === ".vc-config.json"
44374
44383
  );
44375
44384
  await Promise.all(
44376
44385
  vcConfigFilePaths.map(async (p) => {
@@ -44379,13 +44388,13 @@ var require_utils9 = __commonJS({
44379
44388
  if (!config.filePathMap)
44380
44389
  return;
44381
44390
  for (const v of Object.values(config.filePathMap)) {
44382
- refs.add((0, import_path11.join)(path, v));
44391
+ refs.add((0, import_path12.join)(path, v));
44383
44392
  }
44384
44393
  })
44385
44394
  );
44386
44395
  try {
44387
44396
  let microfrontendConfigPath = (0, import_utils4.findConfig)({
44388
- dir: (0, import_path11.join)(path, rootDirectory || "")
44397
+ dir: (0, import_path12.join)(path, rootDirectory || "")
44389
44398
  });
44390
44399
  if (!microfrontendConfigPath && !rootDirectory && projectName) {
44391
44400
  microfrontendConfigPath = (0, import_utils4.findConfig)({
@@ -44403,7 +44412,7 @@ var require_utils9 = __commonJS({
44403
44412
  }
44404
44413
  }
44405
44414
  try {
44406
- const routesJsonPath = (0, import_path11.join)(path, ".vercel", "routes.json");
44415
+ const routesJsonPath = (0, import_path12.join)(path, ".vercel", "routes.json");
44407
44416
  const routesJsonContent = await maybeRead(routesJsonPath, null);
44408
44417
  if (routesJsonContent !== null) {
44409
44418
  refs.add(routesJsonPath);
@@ -44415,12 +44424,12 @@ var require_utils9 = __commonJS({
44415
44424
  if (prebuilt && bulkRedirectsPath) {
44416
44425
  try {
44417
44426
  const projectRoot = path;
44418
- const bulkRedirectsFullPath = (0, import_path11.join)(
44427
+ const bulkRedirectsFullPath = (0, import_path12.join)(
44419
44428
  projectRoot,
44420
44429
  rootDirectory || "",
44421
44430
  bulkRedirectsPath
44422
44431
  );
44423
- const relativeFromRoot = (0, import_path11.relative)(projectRoot, bulkRedirectsFullPath);
44432
+ const relativeFromRoot = (0, import_path12.relative)(projectRoot, bulkRedirectsFullPath);
44424
44433
  if (relativeFromRoot.startsWith("..")) {
44425
44434
  debug(
44426
44435
  `Skipping bulk redirects path "${bulkRedirectsPath}" - path traversal detected (resolves outside project root)`
@@ -44475,9 +44484,9 @@ var require_utils9 = __commonJS({
44475
44484
  if (typeof cwd !== "string") {
44476
44485
  throw new Error(`\`cwd\` must be a "string"`);
44477
44486
  }
44478
- const relOutputDir = (0, import_path11.relative)(cwd, vercelOutputDir);
44487
+ const relOutputDir = (0, import_path12.relative)(cwd, vercelOutputDir);
44479
44488
  ignores = ["*"];
44480
- const parts = relOutputDir.split(import_path11.sep);
44489
+ const parts = relOutputDir.split(import_path12.sep);
44481
44490
  parts.forEach((_, i) => {
44482
44491
  const level = parts.slice(0, i + 1).join("/");
44483
44492
  ignores.push(`!${level}`);
@@ -44517,11 +44526,11 @@ var require_utils9 = __commonJS({
44517
44526
  const files = await Promise.all(
44518
44527
  cwds.map(async (cwd2) => {
44519
44528
  const [vercelignore, nowignore] = await Promise.all([
44520
- maybeRead((0, import_path11.join)(cwd2, ".vercelignore"), ""),
44521
- maybeRead((0, import_path11.join)(cwd2, ".nowignore"), "")
44529
+ maybeRead((0, import_path12.join)(cwd2, ".vercelignore"), ""),
44530
+ maybeRead((0, import_path12.join)(cwd2, ".nowignore"), "")
44522
44531
  ]);
44523
44532
  if (vercelignore && nowignore) {
44524
- throw new import_build_utils5.NowBuildError({
44533
+ throw new import_build_utils6.NowBuildError({
44525
44534
  code: "CONFLICTING_IGNORE_FILES",
44526
44535
  message: "Cannot use both a `.vercelignore` and `.nowignore` file. Please delete the `.nowignore` file.",
44527
44536
  link: "https://vercel.link/combining-old-and-new-config"
@@ -44577,9 +44586,9 @@ ${clearRelative(ignoreFile)}`);
44577
44586
  for (const name of file.names) {
44578
44587
  let fileName;
44579
44588
  if (clientOptions.isDirectory) {
44580
- fileName = typeof clientOptions.path === "string" ? (0, import_path11.relative)(clientOptions.path, name) : name;
44589
+ fileName = typeof clientOptions.path === "string" ? (0, import_path12.relative)(clientOptions.path, name) : name;
44581
44590
  } else {
44582
- const segments = name.split(import_path11.sep);
44591
+ const segments = name.split(import_path12.sep);
44583
44592
  fileName = segments[segments.length - 1];
44584
44593
  }
44585
44594
  preparedFiles.push({
@@ -45964,7 +45973,7 @@ var require_BufferList = __commonJS({
45964
45973
  this.head = this.tail = null;
45965
45974
  this.length = 0;
45966
45975
  };
45967
- BufferList.prototype.join = function join10(s) {
45976
+ BufferList.prototype.join = function join11(s) {
45968
45977
  if (this.length === 0)
45969
45978
  return "";
45970
45979
  var p = this.head;
@@ -49556,7 +49565,7 @@ var require_archive = __commonJS({
49556
49565
  module.exports = __toCommonJS2(archive_exports);
49557
49566
  var import_node_path2 = __require("path");
49558
49567
  var import_node_zlib = __require("zlib");
49559
- var import_build_utils5 = __require("@vercel/build-utils");
49568
+ var import_build_utils6 = __require("@vercel/build-utils");
49560
49569
  var import_tar_fs = __toESM2(require_tar_fs());
49561
49570
  var import_hashes = require_hashes();
49562
49571
  async function createTgzFiles(workPath, fileList, debug, exclude) {
@@ -49565,7 +49574,7 @@ var require_archive = __commonJS({
49565
49574
  const tarStream = import_tar_fs.default.pack(workPath, {
49566
49575
  entries: filesToArchive.map((file) => (0, import_node_path2.relative)(workPath, file))
49567
49576
  }).pipe((0, import_node_zlib.createGzip)());
49568
- const chunkedTarBuffers = await (0, import_build_utils5.streamToBufferChunks)(tarStream);
49577
+ const chunkedTarBuffers = await (0, import_build_utils6.streamToBufferChunks)(tarStream);
49569
49578
  debug?.(`Packed tarball into ${chunkedTarBuffers.length} chunks`);
49570
49579
  return new Map(
49571
49580
  chunkedTarBuffers.map((chunk, index) => [
@@ -49608,7 +49617,7 @@ var require_create_deployment = __commonJS({
49608
49617
  });
49609
49618
  module.exports = __toCommonJS2(create_deployment_exports);
49610
49619
  var import_fs_extra9 = require_lib6();
49611
- var import_path11 = __require("path");
49620
+ var import_path12 = __require("path");
49612
49621
  var import_hashes = require_hashes();
49613
49622
  var import_deploy = require_deploy();
49614
49623
  var import_upload = require_upload();
@@ -49658,14 +49667,14 @@ var require_create_deployment = __commonJS({
49658
49667
  clientOptions.isDirectory = !Array.isArray(path) && (0, import_fs_extra9.lstatSync)(path).isDirectory();
49659
49668
  if (Array.isArray(path)) {
49660
49669
  for (const filePath of path) {
49661
- if (!(0, import_path11.isAbsolute)(filePath)) {
49670
+ if (!(0, import_path12.isAbsolute)(filePath)) {
49662
49671
  throw new import_errors3.DeploymentError({
49663
49672
  code: "invalid_path",
49664
49673
  message: `Provided path ${filePath} is not absolute`
49665
49674
  });
49666
49675
  }
49667
49676
  }
49668
- } else if (!(0, import_path11.isAbsolute)(path)) {
49677
+ } else if (!(0, import_path12.isAbsolute)(path)) {
49669
49678
  throw new import_errors3.DeploymentError({
49670
49679
  code: "invalid_path",
49671
49680
  message: `Provided path ${path} is not absolute`
@@ -49696,9 +49705,9 @@ var require_create_deployment = __commonJS({
49696
49705
  }
49697
49706
  } catch (err) {
49698
49707
  if (clientOptions.prebuilt && (0, import_error_utils5.isErrnoException)(err) && err.code === "ENOENT" && err.path) {
49699
- const errPath = (0, import_path11.relative)(workPath, err.path);
49700
- err.message = `File does not exist: "${(0, import_path11.relative)(workPath, errPath)}"`;
49701
- if (errPath.split(import_path11.sep).includes("node_modules")) {
49708
+ const errPath = (0, import_path12.relative)(workPath, err.path);
49709
+ err.message = `File does not exist: "${(0, import_path12.relative)(workPath, errPath)}"`;
49710
+ if (errPath.split(import_path12.sep).includes("node_modules")) {
49702
49711
  err.message = `Please ensure project dependencies have been installed:
49703
49712
  ${err.message}`;
49704
49713
  }
@@ -49761,7 +49770,7 @@ var require_continue = __commonJS({
49761
49770
  continueDeployment: () => continueDeployment2
49762
49771
  });
49763
49772
  module.exports = __toCommonJS2(continue_exports);
49764
- var import_path11 = __require("path");
49773
+ var import_path12 = __require("path");
49765
49774
  var import_fs_extra9 = __toESM2(require_lib6());
49766
49775
  var import_check_deployment_status = require_check_deployment_status();
49767
49776
  var import_utils4 = require_utils9();
@@ -49773,7 +49782,7 @@ var require_continue = __commonJS({
49773
49782
  async function* continueDeployment2(options) {
49774
49783
  const debug = (0, import_utils4.createDebug)(options.debug);
49775
49784
  debug(`Continuing deployment: ${options.deploymentId}`);
49776
- const outputDir = options.vercelOutputDir || (0, import_path11.join)(options.path, ".vercel", "output");
49785
+ const outputDir = options.vercelOutputDir || (0, import_path12.join)(options.path, ".vercel", "output");
49777
49786
  if (!await import_fs_extra9.default.pathExists(outputDir)) {
49778
49787
  return yield {
49779
49788
  type: "error",
@@ -49788,7 +49797,7 @@ var require_continue = __commonJS({
49788
49797
  { isDirectory: true, prebuilt: true, vercelOutputDir: outputDir },
49789
49798
  debug
49790
49799
  );
49791
- const provisionJsonPath = (0, import_path11.join)(outputDir, "provision.json");
49800
+ const provisionJsonPath = (0, import_path12.join)(outputDir, "provision.json");
49792
49801
  const unbundledFiles = fileList.filter((f) => f === provisionJsonPath);
49793
49802
  let files;
49794
49803
  if (options.archive === "tgz") {
@@ -50039,7 +50048,7 @@ var require_dist7 = __commonJS({
50039
50048
  // src/util/compile-vercel-config.ts
50040
50049
  var import_dotenv = __toESM(require_main(), 1);
50041
50050
  import { mkdir, readFile as readFile5, writeFile as writeFile4, unlink, access } from "fs/promises";
50042
- import { join as join9, basename as basename3 } from "path";
50051
+ import { join as join10, basename as basename3 } from "path";
50043
50052
  import { fork } from "child_process";
50044
50053
  import { parse as tomlParse2 } from "smol-toml";
50045
50054
 
@@ -50047,7 +50056,7 @@ import { parse as tomlParse2 } from "smol-toml";
50047
50056
  var import_ajv2 = __toESM(require_ajv(), 1);
50048
50057
  var import_fs_extra8 = __toESM(require_lib3(), 1);
50049
50058
  import fs4 from "fs";
50050
- import { join as join8, relative } from "path";
50059
+ import { join as join9, relative } from "path";
50051
50060
  import { promisify } from "util";
50052
50061
 
50053
50062
  // src/util/projects/get-project-by-id-or-name.ts
@@ -53428,12 +53437,12 @@ function escapeValue(value) {
53428
53437
  var import_chalk12 = __toESM(require_source(), 1);
53429
53438
  var import_fs_extra7 = __toESM(require_lib3(), 1);
53430
53439
  import { stat } from "fs/promises";
53431
- import { join as join7, dirname } from "path";
53440
+ import { join as join8, dirname } from "path";
53432
53441
 
53433
53442
  // src/util/projects/detect-services.ts
53434
53443
  var import_fs_detectors2 = __toESM(require_dist6(), 1);
53435
53444
  import { readFile as readFile3, writeFile as writeFile2 } from "fs/promises";
53436
- import { basename as basename2, join as join6 } from "path";
53445
+ import { basename as basename2, join as join7 } from "path";
53437
53446
  import { parse as tomlParse, stringify as tomlStringify } from "smol-toml";
53438
53447
 
53439
53448
  // src/util/is-vercel-toml-enabled.ts
@@ -54137,6 +54146,39 @@ function validateConfig(config) {
54137
54146
  return null;
54138
54147
  }
54139
54148
 
54149
+ // src/util/projects/detect-entrypoint.ts
54150
+ import { join as join6 } from "path";
54151
+ import {
54152
+ isPythonFramework,
54153
+ isNodeBackendFramework,
54154
+ normalizePath as normalizePath2
54155
+ } from "@vercel/build-utils";
54156
+ function createDetectEntrypoint(projectRoot) {
54157
+ return async ({ workPath, framework }) => {
54158
+ const absWorkPath = normalizePath2(join6(projectRoot, workPath));
54159
+ if (isPythonFramework(framework)) {
54160
+ const { detectEntrypoint } = await import("@vercel/python");
54161
+ return detectEntrypoint({
54162
+ workPath: absWorkPath,
54163
+ framework
54164
+ });
54165
+ }
54166
+ if (isNodeBackendFramework(framework)) {
54167
+ const { detectEntrypoint } = await import("@vercel/backends");
54168
+ return detectEntrypoint({
54169
+ workPath: absWorkPath
54170
+ });
54171
+ }
54172
+ if (framework === "go") {
54173
+ const { detectEntrypoint } = await import("@vercel/go");
54174
+ return detectEntrypoint({
54175
+ workPath: absWorkPath
54176
+ });
54177
+ }
54178
+ return null;
54179
+ };
54180
+ }
54181
+
54140
54182
  // src/util/projects/detect-services.ts
54141
54183
  async function isExperimentalServicesEnabled(cwd) {
54142
54184
  return process.env.VERCEL_USE_EXPERIMENTAL_SERVICES === "1" || process.env.VERCEL_USE_EXPERIMENTAL_SERVICES?.toLowerCase() === "true" || await hasExperimentalServicesConfig(cwd);
@@ -54162,7 +54204,10 @@ async function tryDetectServices(cwd) {
54162
54204
  return null;
54163
54205
  }
54164
54206
  const fs5 = new import_fs_detectors2.LocalFileSystemDetector(cwd);
54165
- const result = await (0, import_fs_detectors2.detectServices)({ fs: fs5 });
54207
+ const result = await (0, import_fs_detectors2.detectServices)({
54208
+ fs: fs5,
54209
+ detectEntrypoint: createDetectEntrypoint(cwd)
54210
+ });
54166
54211
  const hasNoServicesError = result.errors.some(
54167
54212
  (e) => e.code === "NO_SERVICES_CONFIGURED"
54168
54213
  );
@@ -54191,9 +54236,9 @@ function toProjectServicesConfigPatch(config) {
54191
54236
  }
54192
54237
  async function prepareServicesConfigWrite(cwd, config) {
54193
54238
  const compileResult = await compileVercelConfig(cwd);
54194
- const configPath = join6(cwd, "vercel.json");
54239
+ const configPath = join7(cwd, "vercel.json");
54195
54240
  if (isVercelTomlEnabled() && compileResult.sourceFile === "vercel.toml") {
54196
- return prepareTomlServicesConfigWrite(join6(cwd, "vercel.toml"), config);
54241
+ return prepareTomlServicesConfigWrite(join7(cwd, "vercel.toml"), config);
54197
54242
  }
54198
54243
  if (compileResult.wasCompiled) {
54199
54244
  throw new Error(
@@ -54273,10 +54318,10 @@ async function findProjectRoot(startDir) {
54273
54318
  } catch {
54274
54319
  return null;
54275
54320
  }
54276
- const hasVercelDir = await (0, import_fs_extra7.pathExists)(join7(dir, ".vercel"));
54277
- const hasVercelJson = await (0, import_fs_extra7.pathExists)(join7(dir, "vercel.json"));
54278
- const hasVercelToml = isVercelTomlEnabled() && await (0, import_fs_extra7.pathExists)(join7(dir, "vercel.toml"));
54279
- const hasGit = await (0, import_fs_extra7.pathExists)(join7(dir, ".git"));
54321
+ const hasVercelDir = await (0, import_fs_extra7.pathExists)(join8(dir, ".vercel"));
54322
+ const hasVercelJson = await (0, import_fs_extra7.pathExists)(join8(dir, "vercel.json"));
54323
+ const hasVercelToml = isVercelTomlEnabled() && await (0, import_fs_extra7.pathExists)(join8(dir, "vercel.toml"));
54324
+ const hasGit = await (0, import_fs_extra7.pathExists)(join8(dir, ".git"));
54280
54325
  if (hasVercelDir || hasVercelJson || hasVercelToml || hasGit) {
54281
54326
  return dir;
54282
54327
  }
@@ -54327,7 +54372,7 @@ var linkSchema = {
54327
54372
  }
54328
54373
  };
54329
54374
  function getVercelDirectory(cwd) {
54330
- const possibleDirs = [join8(cwd, VERCEL_DIR), join8(cwd, VERCEL_DIR_FALLBACK)];
54375
+ const possibleDirs = [join9(cwd, VERCEL_DIR), join9(cwd, VERCEL_DIR_FALLBACK)];
54331
54376
  const existingDirs = possibleDirs.filter((d) => isDirectory(d));
54332
54377
  if (existingDirs.length > 1) {
54333
54378
  throw new NowBuildError2({
@@ -54419,7 +54464,7 @@ async function getProjectLinkFromRepoLink(client, path, projectName, projectName
54419
54464
  }
54420
54465
  async function getLinkFromDir(dir) {
54421
54466
  try {
54422
- const json = await readFile4(join8(dir, VERCEL_DIR_PROJECT), "utf8");
54467
+ const json = await readFile4(join9(dir, VERCEL_DIR_PROJECT), "utf8");
54423
54468
  const ajv2 = new import_ajv2.default();
54424
54469
  const link = JSON.parse(json);
54425
54470
  if (!ajv2.validate(linkSchema, link)) {
@@ -54580,7 +54625,7 @@ Upon creation, it will be automatically added to your ".gitignore" file.
54580
54625
  `;
54581
54626
  async function writeReadme(path) {
54582
54627
  await writeFile3(
54583
- join8(path, VERCEL_DIR, VERCEL_DIR_README),
54628
+ join9(path, VERCEL_DIR, VERCEL_DIR_README),
54584
54629
  VERCEL_DIR_README_CONTENT
54585
54630
  );
54586
54631
  }
@@ -54589,7 +54634,7 @@ async function linkFolderToProject(client, path, projectLink, projectName, orgSl
54589
54634
  return;
54590
54635
  }
54591
54636
  try {
54592
- await (0, import_fs_extra8.ensureDir)(join8(path, VERCEL_DIR));
54637
+ await (0, import_fs_extra8.ensureDir)(join9(path, VERCEL_DIR));
54593
54638
  } catch (err) {
54594
54639
  if ((0, import_error_utils4.isErrnoException)(err) && err.code === "ENOTDIR") {
54595
54640
  return;
@@ -54597,7 +54642,7 @@ async function linkFolderToProject(client, path, projectLink, projectName, orgSl
54597
54642
  throw err;
54598
54643
  }
54599
54644
  await writeFile3(
54600
- join8(path, VERCEL_DIR, VERCEL_DIR_PROJECT),
54645
+ join9(path, VERCEL_DIR, VERCEL_DIR_PROJECT),
54601
54646
  JSON.stringify({
54602
54647
  ...projectLink,
54603
54648
  projectName
@@ -54720,7 +54765,7 @@ async function fileExists(filePath) {
54720
54765
  async function findAllVercelConfigFiles(workPath) {
54721
54766
  const foundFiles = [];
54722
54767
  for (const ext of VERCEL_CONFIG_EXTENSIONS) {
54723
- const configPath = join9(workPath, `vercel.${ext}`);
54768
+ const configPath = join10(workPath, `vercel.${ext}`);
54724
54769
  if (await fileExists(configPath)) {
54725
54770
  foundFiles.push(configPath);
54726
54771
  }
@@ -54729,13 +54774,13 @@ async function findAllVercelConfigFiles(workPath) {
54729
54774
  }
54730
54775
  async function findSourceVercelConfigFile(workPath) {
54731
54776
  for (const ext of VERCEL_CONFIG_EXTENSIONS) {
54732
- const configPath = join9(workPath, `vercel.${ext}`);
54777
+ const configPath = join10(workPath, `vercel.${ext}`);
54733
54778
  if (await fileExists(configPath)) {
54734
54779
  return basename3(configPath);
54735
54780
  }
54736
54781
  }
54737
54782
  if (isVercelTomlEnabled()) {
54738
- const tomlPath = join9(workPath, "vercel.toml");
54783
+ const tomlPath = join10(workPath, "vercel.toml");
54739
54784
  if (await fileExists(tomlPath)) {
54740
54785
  return "vercel.toml";
54741
54786
  }
@@ -54777,15 +54822,15 @@ function parseConfigLoaderError(stderr) {
54777
54822
  return stderr.trim();
54778
54823
  }
54779
54824
  async function compileVercelConfig(workPath) {
54780
- const vercelJsonPath = join9(workPath, "vercel.json");
54781
- const nowJsonPath = join9(workPath, "now.json");
54782
- const vercelTomlPath = join9(workPath, "vercel.toml");
54825
+ const vercelJsonPath = join10(workPath, "vercel.json");
54826
+ const nowJsonPath = join10(workPath, "now.json");
54827
+ const vercelTomlPath = join10(workPath, "vercel.toml");
54783
54828
  const hasVercelJson = await fileExists(vercelJsonPath);
54784
54829
  const hasNowJson = await fileExists(nowJsonPath);
54785
54830
  const hasVercelToml = isVercelTomlEnabled() && await fileExists(vercelTomlPath);
54786
54831
  const vercelConfigPath = await findVercelConfigFile(workPath);
54787
- const vercelDir = join9(workPath, VERCEL_DIR);
54788
- const compiledConfigPath = join9(vercelDir, "vercel.json");
54832
+ const vercelDir = join10(workPath, VERCEL_DIR);
54833
+ const compiledConfigPath = join10(vercelDir, "vercel.json");
54789
54834
  if (hasNowJson) {
54790
54835
  throw new DeprecatedNowJson(nowJsonPath);
54791
54836
  }
@@ -54848,10 +54893,10 @@ async function compileVercelConfig(workPath) {
54848
54893
  }
54849
54894
  }
54850
54895
  const sourceConfigPath = vercelConfigPath;
54851
- (0, import_dotenv.config)({ path: join9(workPath, ".env") });
54852
- (0, import_dotenv.config)({ path: join9(workPath, ".env.local") });
54853
- const tempOutPath = join9(vercelDir, "vercel-temp.mjs");
54854
- const loaderPath = join9(vercelDir, "vercel-loader.mjs");
54896
+ (0, import_dotenv.config)({ path: join10(workPath, ".env") });
54897
+ (0, import_dotenv.config)({ path: join10(workPath, ".env.local") });
54898
+ const tempOutPath = join10(vercelDir, "vercel-temp.mjs");
54899
+ const loaderPath = join10(vercelDir, "vercel-loader.mjs");
54855
54900
  try {
54856
54901
  const { build } = await import("esbuild");
54857
54902
  await mkdir(vercelDir, { recursive: true });
@@ -54955,9 +55000,9 @@ async function compileVercelConfig(workPath) {
54955
55000
  }
54956
55001
  }
54957
55002
  async function getVercelConfigPath(workPath) {
54958
- const vercelJsonPath = join9(workPath, "vercel.json");
54959
- const vercelTomlPath = join9(workPath, "vercel.toml");
54960
- const compiledConfigPath = join9(workPath, VERCEL_DIR, "vercel.json");
55003
+ const vercelJsonPath = join10(workPath, "vercel.json");
55004
+ const vercelTomlPath = join10(workPath, "vercel.toml");
55005
+ const compiledConfigPath = join10(workPath, VERCEL_DIR, "vercel.json");
54961
55006
  if (await fileExists(vercelJsonPath)) {
54962
55007
  return vercelJsonPath;
54963
55008
  }
@@ -55057,6 +55102,7 @@ export {
55057
55102
  getVercelConfigPath,
55058
55103
  readJSONFile,
55059
55104
  validateConfig,
55105
+ createDetectEntrypoint,
55060
55106
  tryDetectServices,
55061
55107
  writeServicesConfig,
55062
55108
  getServicesConfigWriteBlocker,