vercel 60.0.1 → 60.1.1

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 (36) hide show
  1. package/dist/chunks/chunk-2TBUMUHF.js +7 -0
  2. package/dist/chunks/{chunk-S74YKDNZ.js → chunk-3CQQXHDI.js} +1 -1
  3. package/dist/chunks/{chunk-V6IKQCOT.js → chunk-5U25FWD5.js} +1 -1
  4. package/dist/chunks/{chunk-42IHNZIE.js → chunk-7HT5KIFA.js} +1 -1
  5. package/dist/chunks/chunk-DKV4IVH5.js +7 -0
  6. package/dist/chunks/{chunk-LLXCLOZO.js → chunk-DPH3CQXE.js} +1 -1
  7. package/dist/chunks/chunk-H4IUDU5W.js +9 -0
  8. package/dist/chunks/{chunk-FXZ6TVIP.js → chunk-KOOED3TJ.js} +2 -2
  9. package/dist/chunks/{chunk-EOIRBY3F.js → chunk-MSLHCYBD.js} +1 -1
  10. package/dist/chunks/{chunk-25MLFUQD.js → chunk-TTMLSKF7.js} +1 -1
  11. package/dist/chunks/{chunk-2HZGNTI4.js → chunk-WH6M54KF.js} +1 -1
  12. package/dist/chunks/{chunk-TKBORMUF.js → chunk-WKZ6JSGZ.js} +1 -1
  13. package/dist/chunks/{config-2327CWL2.js → config-4FCRR7C5.js} +1 -1
  14. package/dist/chunks/{constants-NCE2LWSS.js → constants-G4UYVLOF.js} +1 -1
  15. package/dist/chunks/{login-VJZGWSOW.js → login-X3KPMMEP.js} +1 -1
  16. package/dist/chunks/ls-GD6LB7IE.js +8 -0
  17. package/dist/chunks/{openapi-G3HACVTQ.js → openapi-7JUPKBWV.js} +1 -1
  18. package/dist/chunks/{prompt-missing-credentials-KCPCA6L7.js → prompt-missing-credentials-PPUSNDNC.js} +1 -1
  19. package/dist/chunks/rm-OYSWVVSJ.js +8 -0
  20. package/dist/chunks/set-GESKJPQA.js +7 -0
  21. package/dist/commands/build/index.js +1 -1
  22. package/dist/commands/deploy/index.js +2 -2
  23. package/dist/commands/dev/index.js +7 -7
  24. package/dist/commands/env/index.js +1 -1
  25. package/dist/commands/link/index.js +1 -1
  26. package/dist/commands/list/index.js +1 -1
  27. package/dist/commands-bulk.js +81 -71
  28. package/dist/index.js +2 -2
  29. package/dist/version.mjs +1 -1
  30. package/package.json +55 -55
  31. package/dist/chunks/chunk-IRM6H42E.js +0 -7
  32. package/dist/chunks/chunk-M5AV545M.js +0 -7
  33. package/dist/chunks/chunk-UQW7M4LS.js +0 -9
  34. package/dist/chunks/ls-BVBCVIRX.js +0 -8
  35. package/dist/chunks/rm-5W45I3TO.js +0 -8
  36. package/dist/chunks/set-XWOUJJ7R.js +0 -7
@@ -0,0 +1,7 @@
1
+ import { createRequire as __createRequire } from 'node:module';
2
+ import { fileURLToPath as __fileURLToPath } from 'node:url';
3
+ import { dirname as __dirname_ } from 'node:path';
4
+ const require = __createRequire(import.meta.url);
5
+ const __filename = __fileURLToPath(import.meta.url);
6
+ const __dirname = __dirname_(__filename);
7
+ import{resolveProjectContext}from"./chunk-ZWYU5SBC.js";import{AGENT_REASON,AGENT_STATUS}from"./chunk-WUH5HYCX.js";import{detectExplicitScope}from"./chunk-4OKKSZVX.js";import{printError}from"./chunk-N5AIKGEO.js";import{getProjectByNameOrId}from"./chunk-RLCFE3MK.js";import{buildCommandWithGlobalFlags,getErrorRecovery,outputActionRequired,outputAgentError}from"./chunk-KCARCOP5.js";import{ProjectNotFound,isAPIError}from"./chunk-RINZXCDJ.js";import{output_manager_default}from"./chunk-EWWFNMPZ.js";function messageFor(err){return isAPIError(err)?err.serverMessage||err.message:err instanceof Error?err.message:String(err)}function handleTracingApiError(client,err){if(client.nonInteractive){let apiError=isAPIError(err)?err:void 0,status=apiError?.status;outputAgentError(client,{status:AGENT_STATUS.ERROR,reason:status===403?AGENT_REASON.PERMISSION_DENIED:status===404?AGENT_REASON.NOT_FOUND:status===429?AGENT_REASON.RATE_LIMITED:AGENT_REASON.API_ERROR,message:messageFor(err),...apiError?.status===429&&getErrorRecovery(apiError,client)})}return isAPIError(err)&&err.status===403?(output_manager_default.error(messageFor(err)),1):(printError(err),1)}function configError(client,reason,message){return outputAgentError(client,{status:AGENT_STATUS.ERROR,reason,message}),output_manager_default.error(message),1}function invalidArguments(client,message){return configError(client,AGENT_REASON.INVALID_ARGUMENTS,message)}function ruleNotFound(client,message){return configError(client,AGENT_REASON.NOT_FOUND,message)}function confirmationRequired(client,message,next){return outputAgentError(client,{status:AGENT_STATUS.ERROR,reason:AGENT_REASON.CONFIRMATION_REQUIRED,message,userActionRequired:!0,next}),output_manager_default.error(message),1}var MISSING_BOTH_MESSAGE="No linked project found. Run `vercel link`, pass --cwd to a linked dir, or use --scope <team> and --project <name>.";async function resolveScope({client,flags={},linkedProject}){let flagScope=flags.scope?.trim()||void 0,flagProject=flags.project?.trim()||void 0;if(linkedProject.status==="linked"){if(!flagScope&&!flagProject)return{teamId:linkedProject.org.id,projectId:linkedProject.project.id};let teamId=flagScope?client.config.currentTeam:linkedProject.org.id;if(!teamId)return{reason:AGENT_REASON.NOT_FOUND,message:`Team not found: ${flagScope}`};let project=await getProjectByNameOrId(client,flagProject??linkedProject.project.id,teamId);return project instanceof ProjectNotFound?{reason:AGENT_REASON.NOT_FOUND,message:`Project not found: ${flagProject}`}:{teamId,projectId:project.id}}if(flagScope&&flagProject){let teamId=client.config.currentTeam;if(!teamId)return{reason:AGENT_REASON.NOT_FOUND,message:`Team not found: ${flagScope}`};let project=await getProjectByNameOrId(client,flagProject,teamId);return project instanceof ProjectNotFound?{reason:AGENT_REASON.NOT_FOUND,message:`Project not found: ${flagProject}`}:{teamId,projectId:project.id}}return{reason:AGENT_REASON.NOT_LINKED,message:MISSING_BOTH_MESSAGE}}async function resolveConfigScope(client,flags){let link=await resolveProjectContext({client,projectNameOrId:flags.project});return link.status==="error"?{exitCode:link.exitCode}:link.status==="not_linked"?(outputActionRequired(client,{status:AGENT_STATUS.ACTION_REQUIRED,reason:AGENT_REASON.NOT_LINKED,message:MISSING_BOTH_MESSAGE,hint:"Link a project or pass --scope and --project.",next:[{command:buildCommandWithGlobalFlags(client.argv,"link"),when:"link this directory to a project"}]}),output_manager_default.error(MISSING_BOTH_MESSAGE),{exitCode:1}):flags.project===void 0&&detectExplicitScope(client)&&link.org.id!==client.config.currentTeam?{exitCode:invalidArguments(client,`The linked project ${link.project.name} belongs to ${link.org.slug||link.org.id}, which is not the scope that was passed. Pass --project <name> to act on a project in that scope.`)}:{teamId:link.org.id,projectId:link.project.id}}export{resolveScope,handleTracingApiError,invalidArguments,ruleNotFound,confirmationRequired,resolveConfigScope};