vercel 41.2.1 → 41.3.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 (2) hide show
  1. package/dist/index.js +761 -321
  2. package/package.json +15 -14
package/dist/index.js CHANGED
@@ -93,7 +93,7 @@ var require_dist2 = __commonJS2({
93
93
  var __toCommonJS4 = (mod) => __copyProps4(__defProp4({}, "__esModule", { value: true }), mod);
94
94
  var src_exports2 = {};
95
95
  __export4(src_exports2, {
96
- errorToString: () => errorToString14,
96
+ errorToString: () => errorToString15,
97
97
  isErrnoException: () => isErrnoException19,
98
98
  isError: () => isError14,
99
99
  isErrorLike: () => isErrorLike2,
@@ -111,7 +111,7 @@ var require_dist2 = __commonJS2({
111
111
  return isError14(error3) && "code" in error3;
112
112
  };
113
113
  var isErrorLike2 = (error3) => isObject2(error3) && "message" in error3;
114
- var errorToString14 = (error3, fallback) => {
114
+ var errorToString15 = (error3, fallback) => {
115
115
  if (isError14(error3) || isErrorLike2(error3))
116
116
  return error3.message;
117
117
  if (typeof error3 === "string")
@@ -121,7 +121,7 @@ var require_dist2 = __commonJS2({
121
121
  var normalizeError3 = (error3) => {
122
122
  if (isError14(error3))
123
123
  return error3;
124
- const errorMessage = errorToString14(error3);
124
+ const errorMessage = errorToString15(error3);
125
125
  return isErrorLike2(error3) ? Object.assign(new Error(errorMessage), error3) : new Error(errorMessage);
126
126
  };
127
127
  function isSpawnError2(v) {
@@ -860,7 +860,7 @@ var require_graceful_fs = __commonJS2({
860
860
  }
861
861
  function ReadStream$open() {
862
862
  var that = this;
863
- open5(that.path, that.flags, that.mode, function(err, fd) {
863
+ open6(that.path, that.flags, that.mode, function(err, fd) {
864
864
  if (err) {
865
865
  if (that.autoClose)
866
866
  that.destroy();
@@ -880,7 +880,7 @@ var require_graceful_fs = __commonJS2({
880
880
  }
881
881
  function WriteStream$open() {
882
882
  var that = this;
883
- open5(that.path, that.flags, that.mode, function(err, fd) {
883
+ open6(that.path, that.flags, that.mode, function(err, fd) {
884
884
  if (err) {
885
885
  that.destroy();
886
886
  that.emit("error", err);
@@ -897,8 +897,8 @@ var require_graceful_fs = __commonJS2({
897
897
  return new fs16.WriteStream(path11, options);
898
898
  }
899
899
  var fs$open = fs16.open;
900
- fs16.open = open5;
901
- function open5(path11, flags, mode, cb) {
900
+ fs16.open = open6;
901
+ function open6(path11, flags, mode, cb) {
902
902
  if (typeof mode === "function")
903
903
  cb = mode, mode = null;
904
904
  return go$open(path11, flags, mode, cb);
@@ -4071,14 +4071,14 @@ var require_templates = __commonJS2({
4071
4071
  }
4072
4072
  return results;
4073
4073
  }
4074
- function buildStyle(chalk114, styles) {
4074
+ function buildStyle(chalk115, styles) {
4075
4075
  const enabled = {};
4076
4076
  for (const layer of styles) {
4077
4077
  for (const style of layer.styles) {
4078
4078
  enabled[style[0]] = layer.inverse ? null : style.slice(1);
4079
4079
  }
4080
4080
  }
4081
- let current = chalk114;
4081
+ let current = chalk115;
4082
4082
  for (const [styleName, styles2] of Object.entries(enabled)) {
4083
4083
  if (!Array.isArray(styles2)) {
4084
4084
  continue;
@@ -4090,7 +4090,7 @@ var require_templates = __commonJS2({
4090
4090
  }
4091
4091
  return current;
4092
4092
  }
4093
- module2.exports = (chalk114, temporary) => {
4093
+ module2.exports = (chalk115, temporary) => {
4094
4094
  const styles = [];
4095
4095
  const chunks = [];
4096
4096
  let chunk = [];
@@ -4100,13 +4100,13 @@ var require_templates = __commonJS2({
4100
4100
  } else if (style) {
4101
4101
  const string = chunk.join("");
4102
4102
  chunk = [];
4103
- chunks.push(styles.length === 0 ? string : buildStyle(chalk114, styles)(string));
4103
+ chunks.push(styles.length === 0 ? string : buildStyle(chalk115, styles)(string));
4104
4104
  styles.push({ inverse, styles: parseStyle(style) });
4105
4105
  } else if (close2) {
4106
4106
  if (styles.length === 0) {
4107
4107
  throw new Error("Found extraneous } in Chalk template literal");
4108
4108
  }
4109
- chunks.push(buildStyle(chalk114, styles)(chunk.join("")));
4109
+ chunks.push(buildStyle(chalk115, styles)(chunk.join("")));
4110
4110
  chunk = [];
4111
4111
  styles.pop();
4112
4112
  } else {
@@ -4154,16 +4154,16 @@ var require_source = __commonJS2({
4154
4154
  }
4155
4155
  };
4156
4156
  var chalkFactory = (options) => {
4157
- const chalk115 = {};
4158
- applyOptions(chalk115, options);
4159
- chalk115.template = (...arguments_) => chalkTag(chalk115.template, ...arguments_);
4160
- Object.setPrototypeOf(chalk115, Chalk.prototype);
4161
- Object.setPrototypeOf(chalk115.template, chalk115);
4162
- chalk115.template.constructor = () => {
4157
+ const chalk116 = {};
4158
+ applyOptions(chalk116, options);
4159
+ chalk116.template = (...arguments_) => chalkTag(chalk116.template, ...arguments_);
4160
+ Object.setPrototypeOf(chalk116, Chalk.prototype);
4161
+ Object.setPrototypeOf(chalk116.template, chalk116);
4162
+ chalk116.template.constructor = () => {
4163
4163
  throw new Error("`chalk.constructor()` is deprecated. Use `new chalk.Instance()` instead.");
4164
4164
  };
4165
- chalk115.template.Instance = ChalkClass;
4166
- return chalk115.template;
4165
+ chalk116.template.Instance = ChalkClass;
4166
+ return chalk116.template;
4167
4167
  };
4168
4168
  function Chalk(options) {
4169
4169
  return chalkFactory(options);
@@ -4221,18 +4221,18 @@ var require_source = __commonJS2({
4221
4221
  }
4222
4222
  }
4223
4223
  });
4224
- var createStyler = (open5, close2, parent) => {
4224
+ var createStyler = (open6, close2, parent) => {
4225
4225
  let openAll;
4226
4226
  let closeAll;
4227
4227
  if (parent === void 0) {
4228
- openAll = open5;
4228
+ openAll = open6;
4229
4229
  closeAll = close2;
4230
4230
  } else {
4231
- openAll = parent.openAll + open5;
4231
+ openAll = parent.openAll + open6;
4232
4232
  closeAll = close2 + parent.closeAll;
4233
4233
  }
4234
4234
  return {
4235
- open: open5,
4235
+ open: open6,
4236
4236
  close: close2,
4237
4237
  openAll,
4238
4238
  closeAll,
@@ -4274,7 +4274,7 @@ var require_source = __commonJS2({
4274
4274
  return openAll + string + closeAll;
4275
4275
  };
4276
4276
  var template;
4277
- var chalkTag = (chalk115, ...strings) => {
4277
+ var chalkTag = (chalk116, ...strings) => {
4278
4278
  const [firstString] = strings;
4279
4279
  if (!isArray(firstString) || !isArray(firstString.raw)) {
4280
4280
  return strings.join(" ");
@@ -4290,14 +4290,14 @@ var require_source = __commonJS2({
4290
4290
  if (template === void 0) {
4291
4291
  template = require_templates();
4292
4292
  }
4293
- return template(chalk115, parts.join(""));
4293
+ return template(chalk116, parts.join(""));
4294
4294
  };
4295
4295
  Object.defineProperties(Chalk.prototype, styles);
4296
- var chalk114 = Chalk();
4297
- chalk114.supportsColor = stdoutColor;
4298
- chalk114.stderr = Chalk({ level: stderrColor ? stderrColor.level : 0 });
4299
- chalk114.stderr.supportsColor = stderrColor;
4300
- module2.exports = chalk114;
4296
+ var chalk115 = Chalk();
4297
+ chalk115.supportsColor = stdoutColor;
4298
+ chalk115.stderr = Chalk({ level: stderrColor ? stderrColor.level : 0 });
4299
+ chalk115.stderr.supportsColor = stderrColor;
4300
+ module2.exports = chalk115;
4301
4301
  }
4302
4302
  });
4303
4303
 
@@ -7208,14 +7208,14 @@ var require_templates2 = __commonJS2({
7208
7208
  }
7209
7209
  return results;
7210
7210
  }
7211
- function buildStyle(chalk114, styles) {
7211
+ function buildStyle(chalk115, styles) {
7212
7212
  const enabled = {};
7213
7213
  for (const layer of styles) {
7214
7214
  for (const style of layer.styles) {
7215
7215
  enabled[style[0]] = layer.inverse ? null : style.slice(1);
7216
7216
  }
7217
7217
  }
7218
- let current = chalk114;
7218
+ let current = chalk115;
7219
7219
  for (const styleName of Object.keys(enabled)) {
7220
7220
  if (Array.isArray(enabled[styleName])) {
7221
7221
  if (!(styleName in current)) {
@@ -7230,7 +7230,7 @@ var require_templates2 = __commonJS2({
7230
7230
  }
7231
7231
  return current;
7232
7232
  }
7233
- module2.exports = (chalk114, tmp) => {
7233
+ module2.exports = (chalk115, tmp) => {
7234
7234
  const styles = [];
7235
7235
  const chunks = [];
7236
7236
  let chunk = [];
@@ -7240,13 +7240,13 @@ var require_templates2 = __commonJS2({
7240
7240
  } else if (style) {
7241
7241
  const str = chunk.join("");
7242
7242
  chunk = [];
7243
- chunks.push(styles.length === 0 ? str : buildStyle(chalk114, styles)(str));
7243
+ chunks.push(styles.length === 0 ? str : buildStyle(chalk115, styles)(str));
7244
7244
  styles.push({ inverse, styles: parseStyle(style) });
7245
7245
  } else if (close2) {
7246
7246
  if (styles.length === 0) {
7247
7247
  throw new Error("Found extraneous } in Chalk template literal");
7248
7248
  }
7249
- chunks.push(buildStyle(chalk114, styles)(chunk.join("")));
7249
+ chunks.push(buildStyle(chalk115, styles)(chunk.join("")));
7250
7250
  chunk = [];
7251
7251
  styles.pop();
7252
7252
  } else {
@@ -7283,16 +7283,16 @@ var require_chalk = __commonJS2({
7283
7283
  }
7284
7284
  function Chalk(options) {
7285
7285
  if (!this || !(this instanceof Chalk) || this.template) {
7286
- const chalk114 = {};
7287
- applyOptions(chalk114, options);
7288
- chalk114.template = function() {
7286
+ const chalk115 = {};
7287
+ applyOptions(chalk115, options);
7288
+ chalk115.template = function() {
7289
7289
  const args2 = [].slice.call(arguments);
7290
- return chalkTag.apply(null, [chalk114.template].concat(args2));
7290
+ return chalkTag.apply(null, [chalk115.template].concat(args2));
7291
7291
  };
7292
- Object.setPrototypeOf(chalk114, Chalk.prototype);
7293
- Object.setPrototypeOf(chalk114.template, chalk114);
7294
- chalk114.template.constructor = Chalk;
7295
- return chalk114.template;
7292
+ Object.setPrototypeOf(chalk115, Chalk.prototype);
7293
+ Object.setPrototypeOf(chalk115.template, chalk115);
7294
+ chalk115.template.constructor = Chalk;
7295
+ return chalk115.template;
7296
7296
  }
7297
7297
  applyOptions(this, options);
7298
7298
  }
@@ -7322,9 +7322,9 @@ var require_chalk = __commonJS2({
7322
7322
  get() {
7323
7323
  const level = this.level;
7324
7324
  return function() {
7325
- const open5 = ansiStyles.color[levelMapping[level]][model].apply(null, arguments);
7325
+ const open6 = ansiStyles.color[levelMapping[level]][model].apply(null, arguments);
7326
7326
  const codes = {
7327
- open: open5,
7327
+ open: open6,
7328
7328
  close: ansiStyles.color.close,
7329
7329
  closeRe: ansiStyles.color.closeRe
7330
7330
  };
@@ -7343,9 +7343,9 @@ var require_chalk = __commonJS2({
7343
7343
  get() {
7344
7344
  const level = this.level;
7345
7345
  return function() {
7346
- const open5 = ansiStyles.bgColor[levelMapping[level]][model].apply(null, arguments);
7346
+ const open6 = ansiStyles.bgColor[levelMapping[level]][model].apply(null, arguments);
7347
7347
  const codes = {
7348
- open: open5,
7348
+ open: open6,
7349
7349
  close: ansiStyles.bgColor.close,
7350
7350
  closeRe: ansiStyles.bgColor.closeRe
7351
7351
  };
@@ -7411,7 +7411,7 @@ var require_chalk = __commonJS2({
7411
7411
  ansiStyles.dim.open = originalDim;
7412
7412
  return str;
7413
7413
  }
7414
- function chalkTag(chalk114, strings) {
7414
+ function chalkTag(chalk115, strings) {
7415
7415
  if (!Array.isArray(strings)) {
7416
7416
  return [].slice.call(arguments, 1).join(" ");
7417
7417
  }
@@ -7421,7 +7421,7 @@ var require_chalk = __commonJS2({
7421
7421
  parts.push(String(args2[i - 1]).replace(/[{}\\]/g, "\\$&"));
7422
7422
  parts.push(String(strings.raw[i]));
7423
7423
  }
7424
- return template(chalk114, parts.join(""));
7424
+ return template(chalk115, parts.join(""));
7425
7425
  }
7426
7426
  Object.defineProperties(Chalk.prototype, styles);
7427
7427
  module2.exports = Chalk();
@@ -9372,21 +9372,21 @@ var require_cli_spinners = __commonJS2({
9372
9372
  var require_log_symbols = __commonJS2({
9373
9373
  "../../node_modules/.pnpm/log-symbols@2.2.0/node_modules/log-symbols/index.js"(exports2, module2) {
9374
9374
  "use strict";
9375
- var chalk114 = require_chalk();
9375
+ var chalk115 = require_chalk();
9376
9376
  var isSupported = process.platform !== "win32" || process.env.CI || process.env.TERM === "xterm-256color";
9377
- var main15 = {
9378
- info: chalk114.blue("\u2139"),
9379
- success: chalk114.green("\u2714"),
9380
- warning: chalk114.yellow("\u26A0"),
9381
- error: chalk114.red("\u2716")
9377
+ var main14 = {
9378
+ info: chalk115.blue("\u2139"),
9379
+ success: chalk115.green("\u2714"),
9380
+ warning: chalk115.yellow("\u26A0"),
9381
+ error: chalk115.red("\u2716")
9382
9382
  };
9383
9383
  var fallbacks = {
9384
- info: chalk114.blue("i"),
9385
- success: chalk114.green("\u221A"),
9386
- warning: chalk114.yellow("\u203C"),
9387
- error: chalk114.red("\xD7")
9384
+ info: chalk115.blue("i"),
9385
+ success: chalk115.green("\u221A"),
9386
+ warning: chalk115.yellow("\u203C"),
9387
+ error: chalk115.red("\xD7")
9388
9388
  };
9389
- module2.exports = isSupported ? main15 : fallbacks;
9389
+ module2.exports = isSupported ? main14 : fallbacks;
9390
9390
  }
9391
9391
  });
9392
9392
 
@@ -9780,7 +9780,7 @@ var require_wcwidth = __commonJS2({
9780
9780
  var require_ora = __commonJS2({
9781
9781
  "../../node_modules/.pnpm/ora@3.4.0/node_modules/ora/index.js"(exports2, module2) {
9782
9782
  "use strict";
9783
- var chalk114 = require_chalk();
9783
+ var chalk115 = require_chalk();
9784
9784
  var cliCursor = require_cli_cursor();
9785
9785
  var cliSpinners = require_cli_spinners();
9786
9786
  var logSymbols = require_log_symbols();
@@ -9869,7 +9869,7 @@ var require_ora = __commonJS2({
9869
9869
  const { frames } = this.spinner;
9870
9870
  let frame = frames[this.frameIndex];
9871
9871
  if (this.color) {
9872
- frame = chalk114[this.color](frame);
9872
+ frame = chalk115[this.color](frame);
9873
9873
  }
9874
9874
  this.frameIndex = ++this.frameIndex % frames.length;
9875
9875
  const fullPrefixText = typeof this.prefixText === "string" ? this.prefixText + " " : "";
@@ -12037,7 +12037,7 @@ var require_instrument = __commonJS2({
12037
12037
  var logger = require_logger();
12038
12038
  var console2 = require_console();
12039
12039
  var dom = require_dom();
12040
- var fetch5 = require_fetch();
12040
+ var fetch6 = require_fetch();
12041
12041
  var globalError = require_globalError();
12042
12042
  var globalUnhandledRejection = require_globalUnhandledRejection();
12043
12043
  var history = require_history();
@@ -12051,7 +12051,7 @@ var require_instrument = __commonJS2({
12051
12051
  case "xhr":
12052
12052
  return xhr.addXhrInstrumentationHandler(callback);
12053
12053
  case "fetch":
12054
- return fetch5.addFetchInstrumentationHandler(callback);
12054
+ return fetch6.addFetchInstrumentationHandler(callback);
12055
12055
  case "history":
12056
12056
  return history.addHistoryInstrumentationHandler(callback);
12057
12057
  case "error":
@@ -12064,7 +12064,7 @@ var require_instrument = __commonJS2({
12064
12064
  }
12065
12065
  exports2.addConsoleInstrumentationHandler = console2.addConsoleInstrumentationHandler;
12066
12066
  exports2.addClickKeypressInstrumentationHandler = dom.addClickKeypressInstrumentationHandler;
12067
- exports2.addFetchInstrumentationHandler = fetch5.addFetchInstrumentationHandler;
12067
+ exports2.addFetchInstrumentationHandler = fetch6.addFetchInstrumentationHandler;
12068
12068
  exports2.addGlobalErrorInstrumentationHandler = globalError.addGlobalErrorInstrumentationHandler;
12069
12069
  exports2.addGlobalUnhandledRejectionInstrumentationHandler = globalUnhandledRejection.addGlobalUnhandledRejectionInstrumentationHandler;
12070
12070
  exports2.addHistoryInstrumentationHandler = history.addHistoryInstrumentationHandler;
@@ -13951,7 +13951,7 @@ var require_cjs = __commonJS2({
13951
13951
  var console2 = require_console();
13952
13952
  var dom = require_dom();
13953
13953
  var xhr = require_xhr();
13954
- var fetch5 = require_fetch();
13954
+ var fetch6 = require_fetch();
13955
13955
  var history = require_history();
13956
13956
  var globalError = require_globalError();
13957
13957
  var globalUnhandledRejection = require_globalUnhandledRejection();
@@ -14117,7 +14117,7 @@ var require_cjs = __commonJS2({
14117
14117
  exports2.addClickKeypressInstrumentationHandler = dom.addClickKeypressInstrumentationHandler;
14118
14118
  exports2.SENTRY_XHR_DATA_KEY = xhr.SENTRY_XHR_DATA_KEY;
14119
14119
  exports2.addXhrInstrumentationHandler = xhr.addXhrInstrumentationHandler;
14120
- exports2.addFetchInstrumentationHandler = fetch5.addFetchInstrumentationHandler;
14120
+ exports2.addFetchInstrumentationHandler = fetch6.addFetchInstrumentationHandler;
14121
14121
  exports2.addHistoryInstrumentationHandler = history.addHistoryInstrumentationHandler;
14122
14122
  exports2.addGlobalErrorInstrumentationHandler = globalError.addGlobalErrorInstrumentationHandler;
14123
14123
  exports2.addGlobalUnhandledRejectionInstrumentationHandler = globalUnhandledRejection.addGlobalUnhandledRejectionInstrumentationHandler;
@@ -23246,7 +23246,7 @@ var require_request = __commonJS2({
23246
23246
  Object.defineProperty(exports2, "__esModule", { value: true });
23247
23247
  var core = require_cjs2();
23248
23248
  var utils = require_cjs();
23249
- var fetch5 = require_fetch2();
23249
+ var fetch6 = require_fetch2();
23250
23250
  var instrument = require_instrument2();
23251
23251
  var types = require_types();
23252
23252
  var DEFAULT_TRACE_PROPAGATION_TARGETS = ["localhost", /^\/(?!\/)/];
@@ -23278,7 +23278,7 @@ var require_request = __commonJS2({
23278
23278
  const spans = {};
23279
23279
  if (traceFetch) {
23280
23280
  utils.addFetchInstrumentationHandler((handlerData) => {
23281
- const createdSpan = fetch5.instrumentFetchRequest(handlerData, shouldCreateSpan, shouldAttachHeadersWithTargets, spans);
23281
+ const createdSpan = fetch6.instrumentFetchRequest(handlerData, shouldCreateSpan, shouldAttachHeadersWithTargets, spans);
23282
23282
  if (createdSpan) {
23283
23283
  const fullUrl = getFullURL(handlerData.fetchData.url);
23284
23284
  const host = fullUrl ? utils.parseUrl(fullUrl).host : void 0;
@@ -24257,7 +24257,7 @@ var require_cjs3 = __commonJS2({
24257
24257
  var browserTracingIntegration = require_browserTracingIntegration();
24258
24258
  var request = require_request();
24259
24259
  var instrument = require_instrument2();
24260
- var fetch5 = require_fetch2();
24260
+ var fetch6 = require_fetch2();
24261
24261
  var extensions = require_extensions();
24262
24262
  exports2.IdleTransaction = core.IdleTransaction;
24263
24263
  exports2.Span = core.Span;
@@ -24289,8 +24289,8 @@ var require_cjs3 = __commonJS2({
24289
24289
  exports2.addFidInstrumentationHandler = instrument.addFidInstrumentationHandler;
24290
24290
  exports2.addLcpInstrumentationHandler = instrument.addLcpInstrumentationHandler;
24291
24291
  exports2.addPerformanceInstrumentationHandler = instrument.addPerformanceInstrumentationHandler;
24292
- exports2.addTracingHeadersToFetchRequest = fetch5.addTracingHeadersToFetchRequest;
24293
- exports2.instrumentFetchRequest = fetch5.instrumentFetchRequest;
24292
+ exports2.addTracingHeadersToFetchRequest = fetch6.addTracingHeadersToFetchRequest;
24293
+ exports2.instrumentFetchRequest = fetch6.instrumentFetchRequest;
24294
24294
  exports2.addExtensionMethods = extensions.addExtensionMethods;
24295
24295
  }
24296
24296
  });
@@ -33125,7 +33125,14 @@ var init_command18 = __esm({
33125
33125
  deprecated: false
33126
33126
  },
33127
33127
  { name: "gitlab", shorthand: null, type: Boolean, deprecated: false },
33128
- { name: "bitbucket", shorthand: null, type: Boolean, deprecated: false }
33128
+ { name: "bitbucket", shorthand: null, type: Boolean, deprecated: false },
33129
+ {
33130
+ name: "future",
33131
+ description: "Sign in using OAuth Device Authorization",
33132
+ shorthand: null,
33133
+ type: Boolean,
33134
+ deprecated: false
33135
+ }
33129
33136
  ],
33130
33137
  examples: [
33131
33138
  {
@@ -33160,7 +33167,15 @@ var init_command19 = __esm({
33160
33167
  aliases: [],
33161
33168
  description: "Logout the current authenticated user.",
33162
33169
  arguments: [],
33163
- options: [],
33170
+ options: [
33171
+ {
33172
+ name: "future",
33173
+ description: "Sign out by calling the Vercel OAuth Revocation Endpoint.",
33174
+ shorthand: null,
33175
+ type: Boolean,
33176
+ deprecated: false
33177
+ }
33178
+ ],
33164
33179
  examples: [
33165
33180
  {
33166
33181
  name: "Logout from the CLI",
@@ -35194,14 +35209,14 @@ var require_templates3 = __commonJS2({
35194
35209
  }
35195
35210
  return results;
35196
35211
  }
35197
- function buildStyle(chalk114, styles) {
35212
+ function buildStyle(chalk115, styles) {
35198
35213
  const enabled = {};
35199
35214
  for (const layer of styles) {
35200
35215
  for (const style of layer.styles) {
35201
35216
  enabled[style[0]] = layer.inverse ? null : style.slice(1);
35202
35217
  }
35203
35218
  }
35204
- let current = chalk114;
35219
+ let current = chalk115;
35205
35220
  for (const [styleName, styles2] of Object.entries(enabled)) {
35206
35221
  if (!Array.isArray(styles2)) {
35207
35222
  continue;
@@ -35213,7 +35228,7 @@ var require_templates3 = __commonJS2({
35213
35228
  }
35214
35229
  return current;
35215
35230
  }
35216
- module2.exports = (chalk114, temporary) => {
35231
+ module2.exports = (chalk115, temporary) => {
35217
35232
  const styles = [];
35218
35233
  const chunks = [];
35219
35234
  let chunk = [];
@@ -35223,13 +35238,13 @@ var require_templates3 = __commonJS2({
35223
35238
  } else if (style) {
35224
35239
  const string = chunk.join("");
35225
35240
  chunk = [];
35226
- chunks.push(styles.length === 0 ? string : buildStyle(chalk114, styles)(string));
35241
+ chunks.push(styles.length === 0 ? string : buildStyle(chalk115, styles)(string));
35227
35242
  styles.push({ inverse, styles: parseStyle(style) });
35228
35243
  } else if (close2) {
35229
35244
  if (styles.length === 0) {
35230
35245
  throw new Error("Found extraneous } in Chalk template literal");
35231
35246
  }
35232
- chunks.push(buildStyle(chalk114, styles)(chunk.join("")));
35247
+ chunks.push(buildStyle(chalk115, styles)(chunk.join("")));
35233
35248
  chunk = [];
35234
35249
  styles.pop();
35235
35250
  } else {
@@ -35277,16 +35292,16 @@ var require_source2 = __commonJS2({
35277
35292
  }
35278
35293
  };
35279
35294
  var chalkFactory = (options) => {
35280
- const chalk115 = {};
35281
- applyOptions(chalk115, options);
35282
- chalk115.template = (...arguments_) => chalkTag(chalk115.template, ...arguments_);
35283
- Object.setPrototypeOf(chalk115, Chalk.prototype);
35284
- Object.setPrototypeOf(chalk115.template, chalk115);
35285
- chalk115.template.constructor = () => {
35295
+ const chalk116 = {};
35296
+ applyOptions(chalk116, options);
35297
+ chalk116.template = (...arguments_) => chalkTag(chalk116.template, ...arguments_);
35298
+ Object.setPrototypeOf(chalk116, Chalk.prototype);
35299
+ Object.setPrototypeOf(chalk116.template, chalk116);
35300
+ chalk116.template.constructor = () => {
35286
35301
  throw new Error("`chalk.constructor()` is deprecated. Use `new chalk.Instance()` instead.");
35287
35302
  };
35288
- chalk115.template.Instance = ChalkClass;
35289
- return chalk115.template;
35303
+ chalk116.template.Instance = ChalkClass;
35304
+ return chalk116.template;
35290
35305
  };
35291
35306
  function Chalk(options) {
35292
35307
  return chalkFactory(options);
@@ -35344,18 +35359,18 @@ var require_source2 = __commonJS2({
35344
35359
  }
35345
35360
  }
35346
35361
  });
35347
- var createStyler = (open5, close2, parent) => {
35362
+ var createStyler = (open6, close2, parent) => {
35348
35363
  let openAll;
35349
35364
  let closeAll;
35350
35365
  if (parent === void 0) {
35351
- openAll = open5;
35366
+ openAll = open6;
35352
35367
  closeAll = close2;
35353
35368
  } else {
35354
- openAll = parent.openAll + open5;
35369
+ openAll = parent.openAll + open6;
35355
35370
  closeAll = close2 + parent.closeAll;
35356
35371
  }
35357
35372
  return {
35358
- open: open5,
35373
+ open: open6,
35359
35374
  close: close2,
35360
35375
  openAll,
35361
35376
  closeAll,
@@ -35397,7 +35412,7 @@ var require_source2 = __commonJS2({
35397
35412
  return openAll + string + closeAll;
35398
35413
  };
35399
35414
  var template;
35400
- var chalkTag = (chalk115, ...strings) => {
35415
+ var chalkTag = (chalk116, ...strings) => {
35401
35416
  const [firstString] = strings;
35402
35417
  if (!isArray(firstString) || !isArray(firstString.raw)) {
35403
35418
  return strings.join(" ");
@@ -35413,14 +35428,14 @@ var require_source2 = __commonJS2({
35413
35428
  if (template === void 0) {
35414
35429
  template = require_templates3();
35415
35430
  }
35416
- return template(chalk115, parts.join(""));
35431
+ return template(chalk116, parts.join(""));
35417
35432
  };
35418
35433
  Object.defineProperties(Chalk.prototype, styles);
35419
- var chalk114 = Chalk();
35420
- chalk114.supportsColor = stdoutColor;
35421
- chalk114.stderr = Chalk({ level: stderrColor ? stderrColor.level : 0 });
35422
- chalk114.stderr.supportsColor = stderrColor;
35423
- module2.exports = chalk114;
35434
+ var chalk115 = Chalk();
35435
+ chalk115.supportsColor = stdoutColor;
35436
+ chalk115.stderr = Chalk({ level: stderrColor ? stderrColor.level : 0 });
35437
+ chalk115.stderr.supportsColor = stderrColor;
35438
+ module2.exports = chalk115;
35424
35439
  }
35425
35440
  });
35426
35441
 
@@ -36899,7 +36914,7 @@ var require_figures = __commonJS2({
36899
36914
  "use strict";
36900
36915
  var escapeStringRegexp = require_escape_string_regexp();
36901
36916
  var { platform } = process;
36902
- var main15 = {
36917
+ var main14 = {
36903
36918
  tick: "\u2714",
36904
36919
  cross: "\u2716",
36905
36920
  star: "\u2605",
@@ -36985,12 +37000,12 @@ var require_figures = __commonJS2({
36985
37000
  hamburger: "\u2261",
36986
37001
  smiley: "\u263A",
36987
37002
  mustache: "\u250C\u2500\u2510",
36988
- heart: main15.heart,
37003
+ heart: main14.heart,
36989
37004
  nodejs: "\u2666",
36990
- arrowUp: main15.arrowUp,
36991
- arrowDown: main15.arrowDown,
36992
- arrowLeft: main15.arrowLeft,
36993
- arrowRight: main15.arrowRight,
37005
+ arrowUp: main14.arrowUp,
37006
+ arrowDown: main14.arrowDown,
37007
+ arrowLeft: main14.arrowLeft,
37008
+ arrowRight: main14.arrowRight,
36994
37009
  radioOn: "(*)",
36995
37010
  radioOff: "( )",
36996
37011
  checkboxOn: "[\xD7]",
@@ -37018,14 +37033,14 @@ var require_figures = __commonJS2({
37018
37033
  sevenEighths: "7/8"
37019
37034
  };
37020
37035
  if (platform === "linux") {
37021
- main15.questionMarkPrefix = "?";
37036
+ main14.questionMarkPrefix = "?";
37022
37037
  }
37023
- var figures4 = platform === "win32" ? windows : main15;
37038
+ var figures4 = platform === "win32" ? windows : main14;
37024
37039
  var fn2 = (string) => {
37025
- if (figures4 === main15) {
37040
+ if (figures4 === main14) {
37026
37041
  return string;
37027
37042
  }
37028
- for (const [key, value] of Object.entries(main15)) {
37043
+ for (const [key, value] of Object.entries(main14)) {
37029
37044
  if (value === figures4[key]) {
37030
37045
  continue;
37031
37046
  }
@@ -37034,7 +37049,7 @@ var require_figures = __commonJS2({
37034
37049
  return string;
37035
37050
  };
37036
37051
  module2.exports = Object.assign(fn2, figures4);
37037
- module2.exports.main = main15;
37052
+ module2.exports.main = main14;
37038
37053
  module2.exports.windows = windows;
37039
37054
  }
37040
37055
  });
@@ -40508,12 +40523,12 @@ var require_lib7 = __commonJS2({
40508
40523
  const dest = new URL$1(destination).hostname;
40509
40524
  return orig === dest || orig[orig.length - dest.length - 1] === "." && orig.endsWith(dest);
40510
40525
  };
40511
- function fetch5(url3, opts) {
40512
- if (!fetch5.Promise) {
40526
+ function fetch6(url3, opts) {
40527
+ if (!fetch6.Promise) {
40513
40528
  throw new Error("native promise missing, set fetch.Promise to your favorite alternative");
40514
40529
  }
40515
- Body.Promise = fetch5.Promise;
40516
- return new fetch5.Promise(function(resolve12, reject) {
40530
+ Body.Promise = fetch6.Promise;
40531
+ return new fetch6.Promise(function(resolve12, reject) {
40517
40532
  const request = new Request2(url3, opts);
40518
40533
  const options = getNodeRequestOptions(request);
40519
40534
  const send = (options.protocol === "https:" ? https : http3).request;
@@ -40563,7 +40578,7 @@ var require_lib7 = __commonJS2({
40563
40578
  req.on("response", function(res) {
40564
40579
  clearTimeout(reqTimeout);
40565
40580
  const headers = createHeadersLenient(res.headers);
40566
- if (fetch5.isRedirect(res.statusCode)) {
40581
+ if (fetch6.isRedirect(res.statusCode)) {
40567
40582
  const location = headers.get("Location");
40568
40583
  let locationURL = null;
40569
40584
  try {
@@ -40625,7 +40640,7 @@ var require_lib7 = __commonJS2({
40625
40640
  requestOpts.body = void 0;
40626
40641
  requestOpts.headers.delete("content-length");
40627
40642
  }
40628
- resolve12(fetch5(new Request2(locationURL, requestOpts)));
40643
+ resolve12(fetch6(new Request2(locationURL, requestOpts)));
40629
40644
  finalize();
40630
40645
  return;
40631
40646
  }
@@ -40685,11 +40700,11 @@ var require_lib7 = __commonJS2({
40685
40700
  writeToStream(req, request);
40686
40701
  });
40687
40702
  }
40688
- fetch5.isRedirect = function(code2) {
40703
+ fetch6.isRedirect = function(code2) {
40689
40704
  return code2 === 301 || code2 === 302 || code2 === 303 || code2 === 307 || code2 === 308;
40690
40705
  };
40691
- fetch5.Promise = global.Promise;
40692
- module2.exports = exports2 = fetch5;
40706
+ fetch6.Promise = global.Promise;
40707
+ module2.exports = exports2 = fetch6;
40693
40708
  Object.defineProperty(exports2, "__esModule", { value: true });
40694
40709
  exports2.default = exports2;
40695
40710
  exports2.Headers = Headers6;
@@ -41014,7 +41029,7 @@ var require_open = __commonJS2({
41014
41029
  subprocess.unref();
41015
41030
  return subprocess;
41016
41031
  };
41017
- var open5 = (target, options) => {
41032
+ var open6 = (target, options) => {
41018
41033
  if (typeof target !== "string") {
41019
41034
  throw new TypeError("Expected a `target`");
41020
41035
  }
@@ -41083,9 +41098,9 @@ var require_open = __commonJS2({
41083
41098
  }, {
41084
41099
  wsl: "/mnt/c/Program Files (x86)/Microsoft/Edge/Application/msedge.exe"
41085
41100
  }));
41086
- open5.apps = apps;
41087
- open5.openApp = openApp;
41088
- module2.exports = open5;
41101
+ open6.apps = apps;
41102
+ open6.openApp = openApp;
41103
+ module2.exports = open6;
41089
41104
  }
41090
41105
  });
41091
41106
 
@@ -43314,7 +43329,7 @@ var require_write_json_file = __commonJS2({
43314
43329
  };
43315
43330
  var readFile6 = (fp) => pify(fs15.readFile)(fp, "utf8").catch(() => {
43316
43331
  });
43317
- var main15 = (fp, data, opts) => {
43332
+ var main14 = (fp, data, opts) => {
43318
43333
  return (opts.detectIndent ? readFile6(fp) : Promise.resolve()).then((str) => {
43319
43334
  const indent = str ? detectIndent(str).indent : opts.indent;
43320
43335
  const json = JSON.stringify(data, opts.replacer, indent);
@@ -43339,7 +43354,7 @@ var require_write_json_file = __commonJS2({
43339
43354
  `, { mode: opts.mode });
43340
43355
  };
43341
43356
  module2.exports = (fp, data, opts) => {
43342
- return makeDir(path11.dirname(fp), { fs: fs15 }).then(() => init3(main15, fp, data, opts));
43357
+ return makeDir(path11.dirname(fp), { fs: fs15 }).then(() => init3(main14, fp, data, opts));
43343
43358
  };
43344
43359
  module2.exports.sync = (fp, data, opts) => {
43345
43360
  makeDir.sync(path11.dirname(fp), { fs: fs15 });
@@ -46157,7 +46172,7 @@ var require_package = __commonJS2({
46157
46172
  "../client/package.json"(exports2, module2) {
46158
46173
  module2.exports = {
46159
46174
  name: "@vercel/client",
46160
- version: "15.1.0",
46175
+ version: "15.1.2",
46161
46176
  main: "dist/index.js",
46162
46177
  typings: "dist/index.d.ts",
46163
46178
  homepage: "https://vercel.com",
@@ -46196,7 +46211,7 @@ var require_package = __commonJS2({
46196
46211
  typescript: "4.9.5"
46197
46212
  },
46198
46213
  dependencies: {
46199
- "@vercel/build-utils": "10.2.0",
46214
+ "@vercel/build-utils": "10.3.1",
46200
46215
  "@vercel/error-utils": "2.0.3",
46201
46216
  "@vercel/routing-utils": "5.0.4",
46202
46217
  "async-retry": "1.2.3",
@@ -47148,14 +47163,14 @@ var require_utils8 = __commonJS2({
47148
47163
  EVENTS: () => EVENTS,
47149
47164
  buildFileTree: () => buildFileTree2,
47150
47165
  createDebug: () => createDebug,
47151
- fetch: () => fetch5,
47166
+ fetch: () => fetch6,
47152
47167
  getApiDeploymentsUrl: () => getApiDeploymentsUrl,
47153
47168
  getVercelIgnore: () => getVercelIgnore4,
47154
47169
  parseVercelConfig: () => parseVercelConfig,
47155
47170
  prepareFiles: () => prepareFiles
47156
47171
  });
47157
47172
  module2.exports = __toCommonJS4(utils_exports);
47158
- var import_node_fetch6 = __toESM4(require_lib7());
47173
+ var import_node_fetch7 = __toESM4(require_lib7());
47159
47174
  var import_path41 = require("path");
47160
47175
  var import_url23 = require("url");
47161
47176
  var import_ignore = __toESM4(require_ignore());
@@ -47339,7 +47354,7 @@ ${clearRelative(ignoreFile)}`);
47339
47354
  function clearRelative(str) {
47340
47355
  return str.replace(/(\n|^)\.\//g, "$1");
47341
47356
  }
47342
- var fetch5 = async (url3, token, opts = {}, debugEnabled) => {
47357
+ var fetch6 = async (url3, token, opts = {}, debugEnabled) => {
47343
47358
  semaphore.acquire();
47344
47359
  const debug2 = createDebug(debugEnabled);
47345
47360
  let time;
@@ -47365,7 +47380,7 @@ ${clearRelative(ignoreFile)}`);
47365
47380
  };
47366
47381
  debug2(`${opts.method || "GET"} ${url3}`);
47367
47382
  time = Date.now();
47368
- const res = await (0, import_node_fetch6.default)(url3, opts);
47383
+ const res = await (0, import_node_fetch7.default)(url3, opts);
47369
47384
  debug2(`DONE in ${Date.now() - time}ms: ${opts.method || "GET"} ${url3}`);
47370
47385
  semaphore.release();
47371
47386
  return res;
@@ -52343,7 +52358,7 @@ var require_create_deployment = __commonJS2({
52343
52358
  var import_upload = require_upload();
52344
52359
  var import_utils4 = require_utils8();
52345
52360
  var import_errors4 = require_errors2();
52346
- var import_error_utils37 = require_dist2();
52361
+ var import_error_utils38 = require_dist2();
52347
52362
  var import_build_utils18 = require("@vercel/build-utils");
52348
52363
  var import_tar_fs2 = __toESM4(require_tar_fs());
52349
52364
  var import_zlib = require("zlib");
@@ -52425,7 +52440,7 @@ var require_create_deployment = __commonJS2({
52425
52440
  files = await (0, import_hashes.hashes)(fileList);
52426
52441
  }
52427
52442
  } catch (err) {
52428
- if (clientOptions.prebuilt && (0, import_error_utils37.isErrnoException)(err) && err.code === "ENOENT" && err.path) {
52443
+ if (clientOptions.prebuilt && (0, import_error_utils38.isErrnoException)(err) && err.code === "ENOENT" && err.path) {
52429
52444
  const errPath = (0, import_path41.relative)(workPath, err.path);
52430
52445
  err.message = `File does not exist: "${(0, import_path41.relative)(workPath, errPath)}"`;
52431
52446
  if (errPath.split(import_path41.sep).includes("node_modules")) {
@@ -88426,12 +88441,36 @@ async function getAliases(client2, deploymentId, next, limit = 20) {
88426
88441
  aliasUrl += `&until=${next}`;
88427
88442
  }
88428
88443
  const to = deploymentId ? `/now/deployments/${deploymentId}/aliases` : aliasUrl;
88429
- const payload = await client2.fetch(to);
88430
- return payload;
88444
+ try {
88445
+ const payload = await client2.fetch(to);
88446
+ return payload;
88447
+ } catch (err) {
88448
+ if (isAPIError(err)) {
88449
+ const contextName = await getScope(client2).then(
88450
+ (scope) => scope.contextName
88451
+ );
88452
+ if (err.status === 404) {
88453
+ throw new DeploymentNotFound({
88454
+ id: deploymentId,
88455
+ context: contextName
88456
+ });
88457
+ }
88458
+ if (err.status === 403 && deploymentId) {
88459
+ throw new DeploymentPermissionDenied(deploymentId, contextName);
88460
+ }
88461
+ if (err.status === 400 && err.message.includes("`id`") && deploymentId) {
88462
+ throw new InvalidDeploymentId(deploymentId);
88463
+ }
88464
+ }
88465
+ throw err;
88466
+ }
88431
88467
  }
88432
88468
  var init_get_aliases = __esm({
88433
88469
  "src/util/alias/get-aliases.ts"() {
88434
88470
  "use strict";
88471
+ init_errors_ts();
88472
+ init_errors_ts();
88473
+ init_get_scope();
88435
88474
  }
88436
88475
  });
88437
88476
 
@@ -89466,7 +89505,7 @@ async function performCreateAlias(client2, contextName, deployment, alias2) {
89466
89505
  if (err.status === 409) {
89467
89506
  return { uid: err.uid, alias: err.alias };
89468
89507
  }
89469
- if (err.code === "deployment_not_found") {
89508
+ if (err.code === "deployment_not_found" || err.code === "not_found") {
89470
89509
  return new DeploymentNotFound({
89471
89510
  context: contextName,
89472
89511
  id: deployment.id
@@ -91776,8 +91815,8 @@ var init_bisect = __esm({
91776
91815
  });
91777
91816
  }
91778
91817
  }
91779
- trackCliFlagOpen(open5) {
91780
- if (open5) {
91818
+ trackCliFlagOpen(open6) {
91819
+ if (open6) {
91781
91820
  this.trackCliFlag("open");
91782
91821
  }
91783
91822
  }
@@ -97819,14 +97858,14 @@ var require_read_config_file = __commonJS2({
97819
97858
  var import_js_yaml = __toESM4(require_js_yaml2());
97820
97859
  var import_toml = __toESM4(require_toml());
97821
97860
  var import_fs9 = require("fs");
97822
- var import_error_utils37 = require_dist2();
97861
+ var import_error_utils38 = require_dist2();
97823
97862
  var { readFile: readFile6 } = import_fs9.promises;
97824
97863
  async function readFileOrNull(file) {
97825
97864
  try {
97826
97865
  const data = await readFile6(file);
97827
97866
  return data;
97828
97867
  } catch (error3) {
97829
- if (!(0, import_error_utils37.isErrnoException)(error3)) {
97868
+ if (!(0, import_error_utils38.isErrnoException)(error3)) {
97830
97869
  throw error3;
97831
97870
  }
97832
97871
  if (error3.code !== "ENOENT") {
@@ -102628,7 +102667,7 @@ var require_local_file_system_detector = __commonJS2({
102628
102667
  var import_promises2 = __toESM4(require("fs/promises"));
102629
102668
  var import_path41 = require("path");
102630
102669
  var import_filesystem = require_filesystem();
102631
- var import_error_utils37 = require_dist2();
102670
+ var import_error_utils38 = require_dist2();
102632
102671
  var LocalFileSystemDetector5 = class _LocalFileSystemDetector extends import_filesystem.DetectorFilesystem {
102633
102672
  constructor(rootPath) {
102634
102673
  super();
@@ -102639,7 +102678,7 @@ var require_local_file_system_detector = __commonJS2({
102639
102678
  await import_promises2.default.stat(this.getFilePath(name));
102640
102679
  return true;
102641
102680
  } catch (err) {
102642
- if ((0, import_error_utils37.isErrnoException)(err) && err.code === "ENOENT") {
102681
+ if ((0, import_error_utils38.isErrnoException)(err) && err.code === "ENOENT") {
102643
102682
  return false;
102644
102683
  }
102645
102684
  throw err;
@@ -109699,8 +109738,8 @@ var require_dist21 = __commonJS2({
109699
109738
  result.push(path11);
109700
109739
  path11 = "";
109701
109740
  }
109702
- var open5 = tryConsume("OPEN");
109703
- if (open5) {
109741
+ var open6 = tryConsume("OPEN");
109742
+ if (open6) {
109704
109743
  var prefix = consumeText();
109705
109744
  var name_1 = tryConsume("NAME") || "";
109706
109745
  var pattern_1 = tryConsume("PATTERN") || "";
@@ -110087,8 +110126,8 @@ var require_dist22 = __commonJS2({
110087
110126
  result.push(path11);
110088
110127
  path11 = "";
110089
110128
  }
110090
- var open5 = tryConsume("OPEN");
110091
- if (open5) {
110129
+ var open6 = tryConsume("OPEN");
110130
+ if (open6) {
110092
110131
  var prefix = consumeText();
110093
110132
  var name_1 = tryConsume("NAME") || "";
110094
110133
  var pattern_1 = tryConsume("PATTERN") || "";
@@ -130339,7 +130378,7 @@ var require_yauzl = __commonJS2({
130339
130378
  var Transform = require("stream").Transform;
130340
130379
  var PassThrough = require("stream").PassThrough;
130341
130380
  var Writable = require("stream").Writable;
130342
- exports2.open = open5;
130381
+ exports2.open = open6;
130343
130382
  exports2.fromFd = fromFd;
130344
130383
  exports2.fromBuffer = fromBuffer;
130345
130384
  exports2.fromRandomAccessReader = fromRandomAccessReader;
@@ -130348,7 +130387,7 @@ var require_yauzl = __commonJS2({
130348
130387
  exports2.ZipFile = ZipFile;
130349
130388
  exports2.Entry = Entry;
130350
130389
  exports2.RandomAccessReader = RandomAccessReader;
130351
- function open5(path11, options, callback) {
130390
+ function open6(path11, options, callback) {
130352
130391
  if (typeof options === "function") {
130353
130392
  callback = options;
130354
130393
  options = null;
@@ -164427,8 +164466,8 @@ var init_builds = __esm({
164427
164466
  }
164428
164467
  }
164429
164468
  const corner = isLast ? "\u2514\u2500\u2500" : "\u251C\u2500\u2500";
164430
- const main15 = prefix + path11 + finalSize + finalRegion;
164431
- return `${import_chalk87.default.grey(corner)} ${color(main15)}`;
164469
+ const main14 = prefix + path11 + finalSize + finalRegion;
164470
+ return `${import_chalk87.default.grey(corner)} ${color(main14)}`;
164432
164471
  };
164433
164472
  getDirPath = (path11, level = 0, highestLevel = null) => {
164434
164473
  const parts = path11.split("/").slice(0, -1);
@@ -167546,12 +167585,353 @@ var init_login2 = __esm({
167546
167585
  }
167547
167586
  });
167548
167587
 
167588
+ // src/util/oauth.ts
167589
+ async function as() {
167590
+ if (!_as) {
167591
+ const discoveryResponse = await discoveryEndpointRequest(VERCEL_ISSUER);
167592
+ const [discoveryResponseError, as2] = await processDiscoveryEndpointResponse(discoveryResponse);
167593
+ if (discoveryResponseError) {
167594
+ throw discoveryResponseError;
167595
+ }
167596
+ _as = as2;
167597
+ }
167598
+ return _as;
167599
+ }
167600
+ async function discoveryEndpointRequest(issuer) {
167601
+ return await (0, import_node_fetch6.default)(new URL(".well-known/openid-configuration", issuer), {
167602
+ headers: { "Content-Type": "application/json", "user-agent": ua_default }
167603
+ });
167604
+ }
167605
+ async function processDiscoveryEndpointResponse(response) {
167606
+ const json = await response.json();
167607
+ if (!response.ok) {
167608
+ return [new Error("Discovery endpoint request failed")];
167609
+ }
167610
+ if (typeof json !== "object" || json === null || !canParseURL(json.issuer) || !canParseURL(json.device_authorization_endpoint) || !canParseURL(json.token_endpoint) || !canParseURL(json.revocation_endpoint) || !canParseURL(json.jwks_uri)) {
167611
+ return [new TypeError("Invalid discovery response")];
167612
+ }
167613
+ const issuer = new URL(json.issuer);
167614
+ if (issuer.href !== VERCEL_ISSUER.href) {
167615
+ return [new Error("Issuer mismatch")];
167616
+ }
167617
+ return [
167618
+ null,
167619
+ {
167620
+ issuer,
167621
+ device_authorization_endpoint: new URL(
167622
+ json.device_authorization_endpoint
167623
+ ),
167624
+ token_endpoint: new URL(json.token_endpoint),
167625
+ revocation_endpoint: new URL(json.revocation_endpoint),
167626
+ jwks_uri: new URL(json.jwks_uri)
167627
+ }
167628
+ ];
167629
+ }
167630
+ async function deviceAuthorizationRequest() {
167631
+ return await (0, import_node_fetch6.default)((await as()).device_authorization_endpoint, {
167632
+ method: "POST",
167633
+ headers: {
167634
+ "Content-Type": "application/x-www-form-urlencoded",
167635
+ "user-agent": ua_default
167636
+ },
167637
+ body: new URLSearchParams({
167638
+ client_id: VERCEL_CLI_CLIENT_ID,
167639
+ scope: "openid"
167640
+ })
167641
+ });
167642
+ }
167643
+ async function processDeviceAuthorizationResponse(response) {
167644
+ const json = await response.json();
167645
+ if (!response.ok) {
167646
+ return [new OAuthError("Device authorization request failed", json)];
167647
+ }
167648
+ if (typeof json !== "object" || json === null)
167649
+ return [new TypeError("Expected response to be an object")];
167650
+ if (!("device_code" in json) || typeof json.device_code !== "string")
167651
+ return [new TypeError("Expected `device_code` to be a string")];
167652
+ if (!("user_code" in json) || typeof json.user_code !== "string")
167653
+ return [new TypeError("Expected `user_code` to be a string")];
167654
+ if (!("verification_uri" in json) || typeof json.verification_uri !== "string" || !canParseURL(json.verification_uri)) {
167655
+ return [new TypeError("Expected `verification_uri` to be a string")];
167656
+ }
167657
+ if (!("verification_uri_complete" in json) || typeof json.verification_uri_complete !== "string" || !canParseURL(json.verification_uri_complete)) {
167658
+ return [
167659
+ new TypeError("Expected `verification_uri_complete` to be a string")
167660
+ ];
167661
+ }
167662
+ if (!("expires_in" in json) || typeof json.expires_in !== "number")
167663
+ return [new TypeError("Expected `expires_in` to be a number")];
167664
+ if (!("interval" in json) || typeof json.interval !== "number")
167665
+ return [new TypeError("Expected `interval` to be a number")];
167666
+ return [
167667
+ null,
167668
+ {
167669
+ device_code: json.device_code,
167670
+ user_code: json.user_code,
167671
+ verification_uri: json.verification_uri,
167672
+ verification_uri_complete: json.verification_uri_complete,
167673
+ expiresAt: Date.now() + json.expires_in * 1e3,
167674
+ interval: json.interval
167675
+ }
167676
+ ];
167677
+ }
167678
+ async function deviceAccessTokenRequest(options) {
167679
+ try {
167680
+ return [
167681
+ null,
167682
+ await (0, import_node_fetch6.default)((await as()).token_endpoint, {
167683
+ method: "POST",
167684
+ headers: {
167685
+ "Content-Type": "application/x-www-form-urlencoded",
167686
+ "user-agent": ua_default
167687
+ },
167688
+ body: new URLSearchParams({
167689
+ client_id: VERCEL_CLI_CLIENT_ID,
167690
+ grant_type: "urn:ietf:params:oauth:grant-type:device_code",
167691
+ ...options
167692
+ }),
167693
+ // TODO: Drop `node-fetch` and just use `signal`
167694
+ timeout: 10 * 1e3,
167695
+ // @ts-expect-error: Signal is part of `fetch` spec, should drop `node-fetch`
167696
+ signal: AbortSignal.timeout(10 * 1e3)
167697
+ })
167698
+ ];
167699
+ } catch (error3) {
167700
+ if (error3 instanceof Error)
167701
+ return [error3];
167702
+ return [
167703
+ new Error("An unknown error occurred. See the logs for details.", {
167704
+ cause: error3
167705
+ })
167706
+ ];
167707
+ }
167708
+ }
167709
+ async function processDeviceAccessTokenResponse(response) {
167710
+ const json = await response.json();
167711
+ if (!response.ok) {
167712
+ return [new OAuthError("Device access token request failed", json)];
167713
+ }
167714
+ if (typeof json !== "object" || json === null)
167715
+ return [new TypeError("Expected response to be an object")];
167716
+ if (!("access_token" in json) || typeof json.access_token !== "string")
167717
+ return [new TypeError("Expected `access_token` to be a string")];
167718
+ if (!("token_type" in json) || json.token_type !== "Bearer")
167719
+ return [new TypeError('Expected `token_type` to be "Bearer"')];
167720
+ if (!("expires_in" in json) || typeof json.expires_in !== "number")
167721
+ return [new TypeError("Expected `expires_in` to be a number")];
167722
+ if ("refresh_token" in json && (typeof json.refresh_token !== "string" || !json.refresh_token))
167723
+ return [new TypeError("Expected `refresh_token` to be a string")];
167724
+ if ("scope" in json && typeof json.scope !== "string")
167725
+ return [new TypeError("Expected `scope` to be a string")];
167726
+ return [null, json];
167727
+ }
167728
+ async function revocationRequest(options) {
167729
+ return await (0, import_node_fetch6.default)((await as()).revocation_endpoint, {
167730
+ method: "POST",
167731
+ headers: {
167732
+ "Content-Type": "application/x-www-form-urlencoded",
167733
+ "user-agent": ua_default
167734
+ },
167735
+ body: new URLSearchParams({ ...options, client_id: VERCEL_CLI_CLIENT_ID })
167736
+ });
167737
+ }
167738
+ async function processRevocationResponse(response) {
167739
+ if (response.ok)
167740
+ return [null, null];
167741
+ const json = await response.json();
167742
+ return [new OAuthError("Revocation request failed", json)];
167743
+ }
167744
+ function processOAuthErrorResponse(json) {
167745
+ if (typeof json !== "object" || json === null)
167746
+ throw new TypeError("Expected response to be an object");
167747
+ if (!("error" in json) || typeof json.error !== "string")
167748
+ throw new TypeError("Expected `error` to be a string");
167749
+ if ("error_description" in json && typeof json.error_description !== "string")
167750
+ throw new TypeError("Expected `error_description` to be a string");
167751
+ if ("error_uri" in json && typeof json.error_uri !== "string")
167752
+ throw new TypeError("Expected `error_uri` to be a string");
167753
+ return json;
167754
+ }
167755
+ function isOAuthError(error3) {
167756
+ return error3 instanceof OAuthError;
167757
+ }
167758
+ function canParseURL(url3) {
167759
+ try {
167760
+ return !!new URL(url3);
167761
+ } catch {
167762
+ return false;
167763
+ }
167764
+ }
167765
+ async function verifyJWT(token) {
167766
+ const JWKS = (0, import_jose.createRemoteJWKSet)((await as()).jwks_uri);
167767
+ const { payload } = await (0, import_jose.jwtVerify)(token, JWKS, {
167768
+ issuer: "https://vercel.com",
167769
+ audience: ["https://api.vercel.com", "https://vercel.com/api"]
167770
+ });
167771
+ return payload;
167772
+ }
167773
+ var import_node_fetch6, import_jose, VERCEL_ISSUER, VERCEL_CLI_CLIENT_ID, _as, OAuthError;
167774
+ var init_oauth2 = __esm({
167775
+ "src/util/oauth.ts"() {
167776
+ "use strict";
167777
+ import_node_fetch6 = __toESM3(require_lib7());
167778
+ import_jose = require("jose");
167779
+ init_ua();
167780
+ VERCEL_ISSUER = new URL("https://vercel.com");
167781
+ VERCEL_CLI_CLIENT_ID = "cl_HYyOPBNtFMfHhaUn9L4QPfTZz6TP47bp";
167782
+ OAuthError = class extends Error {
167783
+ constructor(message2, response) {
167784
+ const error3 = processOAuthErrorResponse(response);
167785
+ let cause = error3.error;
167786
+ if (error3.error_description)
167787
+ cause += `: ${error3.error_description}`;
167788
+ if (error3.error_uri)
167789
+ cause += ` (${error3.error_uri})`;
167790
+ super(message2, { cause });
167791
+ this.cause = new Error(cause);
167792
+ this.code = error3.error;
167793
+ }
167794
+ };
167795
+ }
167796
+ });
167797
+
167798
+ // src/commands/login/future.ts
167799
+ async function login2(client2) {
167800
+ const deviceAuthorizationResponse = await deviceAuthorizationRequest();
167801
+ output_manager_default.debug(
167802
+ `'Device Authorization response:', ${await deviceAuthorizationResponse.clone().text()}`
167803
+ );
167804
+ const [deviceAuthorizationError, deviceAuthorization] = await processDeviceAuthorizationResponse(deviceAuthorizationResponse);
167805
+ if (deviceAuthorizationError) {
167806
+ printError(deviceAuthorizationError);
167807
+ return 1;
167808
+ }
167809
+ const {
167810
+ device_code,
167811
+ user_code,
167812
+ verification_uri,
167813
+ verification_uri_complete,
167814
+ expiresAt,
167815
+ interval
167816
+ } = deviceAuthorization;
167817
+ const rl = import_node_readline.default.createInterface({
167818
+ input: process.stdin,
167819
+ output: process.stdout
167820
+ }).on("SIGINT", () => process.exit(0));
167821
+ rl.question(
167822
+ `
167823
+ \u25B2 Sign in to the Vercel CLI
167824
+
167825
+ Visit ${import_chalk98.default.bold(output_manager_default.link(verification_uri, verification_uri_complete, { color: false }))} to enter ${import_chalk98.default.bold(user_code)}
167826
+ ${import_chalk98.default.grey("Press [ENTER] to open the browser")}
167827
+ `,
167828
+ () => {
167829
+ open5.default(verification_uri_complete);
167830
+ rl.close();
167831
+ }
167832
+ );
167833
+ output_manager_default.spinner("Waiting for authentication...");
167834
+ let intervalMs = interval * 1e3;
167835
+ let error3 = new Error(
167836
+ "Timed out waiting for authentication. Please try again."
167837
+ );
167838
+ async function pollForToken() {
167839
+ while (Date.now() < expiresAt) {
167840
+ await new Promise((resolve12) => setTimeout(resolve12, intervalMs));
167841
+ const [tokenResponseError, tokenResponse] = await deviceAccessTokenRequest({ device_code });
167842
+ if (tokenResponseError) {
167843
+ if (tokenResponseError.message.includes("timeout")) {
167844
+ intervalMs *= 2;
167845
+ output_manager_default.debug(
167846
+ `Connection timeout. Slowing down, polling every ${intervalMs / 1e3}s...`
167847
+ );
167848
+ continue;
167849
+ }
167850
+ return tokenResponseError;
167851
+ }
167852
+ output_manager_default.debug(
167853
+ `'Device Access Token response:', ${await tokenResponse.clone().text()}`
167854
+ );
167855
+ const [tokenError, token] = await processDeviceAccessTokenResponse(tokenResponse);
167856
+ if (isOAuthError(tokenError)) {
167857
+ const { code: code2 } = tokenError;
167858
+ switch (code2) {
167859
+ case "authorization_pending":
167860
+ continue;
167861
+ case "slow_down":
167862
+ intervalMs += 5 * 1e3;
167863
+ output_manager_default.debug(
167864
+ `Authorization server requests to slow down. Polling every ${intervalMs / 1e3}s...`
167865
+ );
167866
+ continue;
167867
+ default:
167868
+ return tokenError.cause;
167869
+ }
167870
+ }
167871
+ if (tokenError)
167872
+ return tokenError;
167873
+ const isInitialLogin = !client2.authConfig.token;
167874
+ client2.authConfig.token = token.access_token;
167875
+ error3 = void 0;
167876
+ const { team_id } = await verifyJWT(token.access_token);
167877
+ output_manager_default.debug("access_token verified");
167878
+ if (team_id) {
167879
+ output_manager_default.debug("Current team updated");
167880
+ client2.config.currentTeam = team_id;
167881
+ } else {
167882
+ output_manager_default.debug("Current team deleted");
167883
+ delete client2.config.currentTeam;
167884
+ }
167885
+ if (isInitialLogin) {
167886
+ await updateCurrentTeamAfterLogin(client2, client2.config.currentTeam);
167887
+ }
167888
+ writeToAuthConfigFile(client2.authConfig);
167889
+ writeToConfigFile(client2.config);
167890
+ output_manager_default.debug(`Saved credentials in "${humanizePath(global_path_default())}"`);
167891
+ output_manager_default.print(`
167892
+ ${import_chalk98.default.cyan("Congratulations!")} You are now signed in. In order to deploy something, run ${getCommandName()}.
167893
+
167894
+ ${prependEmoji(
167895
+ `Connect your Git Repositories to deploy every branch push automatically (${import_chalk98.default.bold(output_manager_default.link("vercel.link/git", "https://vercel.link/git", { color: false }))}).`,
167896
+ emoji("tip")
167897
+ )}
167898
+ `);
167899
+ return;
167900
+ }
167901
+ }
167902
+ error3 = await pollForToken();
167903
+ output_manager_default.stopSpinner();
167904
+ rl.close();
167905
+ if (!error3)
167906
+ return 0;
167907
+ printError(error3);
167908
+ return 1;
167909
+ }
167910
+ var import_node_readline, import_chalk98, open5;
167911
+ var init_future = __esm({
167912
+ "src/commands/login/future.ts"() {
167913
+ "use strict";
167914
+ import_node_readline = __toESM3(require("readline"));
167915
+ import_chalk98 = __toESM3(require_source());
167916
+ open5 = __toESM3(require_open());
167917
+ init_error2();
167918
+ init_update_current_team_after_login();
167919
+ init_files();
167920
+ init_global_path();
167921
+ init_pkg_name();
167922
+ init_emoji();
167923
+ init_humanize_path();
167924
+ init_oauth2();
167925
+ init_output_manager();
167926
+ }
167927
+ });
167928
+
167549
167929
  // src/commands/login/index.ts
167550
167930
  var login_exports = {};
167551
167931
  __export3(login_exports, {
167552
- default: () => login2
167932
+ default: () => login3
167553
167933
  });
167554
- async function login2(client2) {
167934
+ async function login3(client2) {
167555
167935
  const isInitialLogin = !client2.authConfig.token;
167556
167936
  let parsedArgs = null;
167557
167937
  const flagsSpecification = getFlagsSpecification(loginCommand.options);
@@ -167566,6 +167946,9 @@ async function login2(client2) {
167566
167946
  printError(error3);
167567
167947
  return 1;
167568
167948
  }
167949
+ if (parsedArgs.flags["--future"]) {
167950
+ return await login2(client2);
167951
+ }
167569
167952
  if (parsedArgs.flags["--help"]) {
167570
167953
  telemetry2.trackCliFlagHelp("login");
167571
167954
  output_manager_default.print(help2(loginCommand, { columns: client2.stderr.columns }));
@@ -167608,7 +167991,7 @@ async function login2(client2) {
167608
167991
  writeToConfigFile(client2.config);
167609
167992
  output_manager_default.debug(`Saved credentials in "${humanizePath(global_path_default())}"`);
167610
167993
  output_manager_default.print(
167611
- `${import_chalk98.default.cyan("Congratulations!")} You are now logged in. In order to deploy something, run ${getCommandName()}.
167994
+ `${import_chalk99.default.cyan("Congratulations!")} You are now logged in. In order to deploy something, run ${getCommandName()}.
167612
167995
  `
167613
167996
  );
167614
167997
  output_manager_default.print(
@@ -167620,12 +168003,12 @@ async function login2(client2) {
167620
168003
  );
167621
168004
  return 0;
167622
168005
  }
167623
- var import_email_validator, import_chalk98;
168006
+ var import_email_validator, import_chalk99;
167624
168007
  var init_login3 = __esm({
167625
168008
  "src/commands/login/index.ts"() {
167626
168009
  "use strict";
167627
168010
  import_email_validator = __toESM3(require_email_validator());
167628
- import_chalk98 = __toESM3(require_source());
168011
+ import_chalk99 = __toESM3(require_source());
167629
168012
  init_humanize_path();
167630
168013
  init_get_args();
167631
168014
  init_prompt();
@@ -167645,6 +168028,7 @@ var init_login3 = __esm({
167645
168028
  init_error2();
167646
168029
  init_output_manager();
167647
168030
  init_login2();
168031
+ init_future();
167648
168032
  }
167649
168033
  });
167650
168034
 
@@ -167659,12 +168043,64 @@ var init_logout = __esm({
167659
168043
  }
167660
168044
  });
167661
168045
 
168046
+ // src/commands/logout/future.ts
168047
+ async function logout(client2) {
168048
+ const { config: config2, authConfig } = client2;
168049
+ if (!authConfig.token) {
168050
+ output_manager_default.note(
168051
+ `Not currently logged in, so ${getCommandName("logout --future")} did nothing`
168052
+ );
168053
+ return 0;
168054
+ }
168055
+ output_manager_default.spinner("Logging out\u2026", 200);
168056
+ const revocationResponse = await revocationRequest({
168057
+ token: authConfig.token
168058
+ });
168059
+ output_manager_default.debug(`'Revocation response:', ${await revocationResponse.clone().text()}`);
168060
+ const [revocationError] = await processRevocationResponse(revocationResponse);
168061
+ let logoutError = false;
168062
+ if (revocationError) {
168063
+ output_manager_default.error(revocationError.message);
168064
+ output_manager_default.debug(revocationError.cause);
168065
+ output_manager_default.error("Failed during logout");
168066
+ logoutError = true;
168067
+ }
168068
+ delete config2.currentTeam;
168069
+ if (config2.desktop)
168070
+ delete config2.desktop.teamOrder;
168071
+ delete authConfig.token;
168072
+ try {
168073
+ writeToConfigFile(config2);
168074
+ writeToAuthConfigFile(authConfig);
168075
+ output_manager_default.debug("Configuration has been deleted");
168076
+ if (!logoutError) {
168077
+ output_manager_default.success("Logged out!");
168078
+ return 0;
168079
+ }
168080
+ } catch (err) {
168081
+ output_manager_default.debug((0, import_error_utils30.errorToString)(err));
168082
+ output_manager_default.error("Failed during logout");
168083
+ }
168084
+ return 1;
168085
+ }
168086
+ var import_error_utils30;
168087
+ var init_future2 = __esm({
168088
+ "src/commands/logout/future.ts"() {
168089
+ "use strict";
168090
+ import_error_utils30 = __toESM3(require_dist2());
168091
+ init_files();
168092
+ init_pkg_name();
168093
+ init_oauth2();
168094
+ init_output_manager();
168095
+ }
168096
+ });
168097
+
167662
168098
  // src/commands/logout/index.ts
167663
168099
  var logout_exports = {};
167664
168100
  __export3(logout_exports, {
167665
- default: () => main11
168101
+ default: () => logout2
167666
168102
  });
167667
- async function main11(client2) {
168103
+ async function logout2(client2) {
167668
168104
  const { authConfig, config: config2 } = client2;
167669
168105
  let parsedArgs = null;
167670
168106
  const flagsSpecification = getFlagsSpecification(logoutCommand.options);
@@ -167679,6 +168115,9 @@ async function main11(client2) {
167679
168115
  printError(error3);
167680
168116
  return 1;
167681
168117
  }
168118
+ if (parsedArgs.flags["--future"]) {
168119
+ return await logout(client2);
168120
+ }
167682
168121
  if (parsedArgs.flags["--help"]) {
167683
168122
  telemetry2.trackCliFlagHelp("logout");
167684
168123
  output_manager_default.print(help2(logoutCommand, { columns: client2.stderr.columns }));
@@ -167717,7 +168156,7 @@ async function main11(client2) {
167717
168156
  writeToAuthConfigFile(authConfig);
167718
168157
  output_manager_default.debug("Configuration has been deleted");
167719
168158
  } catch (err) {
167720
- output_manager_default.debug((0, import_error_utils30.errorToString)(err));
168159
+ output_manager_default.debug((0, import_error_utils31.errorToString)(err));
167721
168160
  exitCode2 = 1;
167722
168161
  }
167723
168162
  if (exitCode2 === 0) {
@@ -167727,7 +168166,7 @@ async function main11(client2) {
167727
168166
  }
167728
168167
  return exitCode2;
167729
168168
  }
167730
- var import_error_utils30;
168169
+ var import_error_utils31;
167731
168170
  var init_logout2 = __esm({
167732
168171
  "src/commands/logout/index.ts"() {
167733
168172
  "use strict";
@@ -167736,12 +168175,13 @@ var init_logout2 = __esm({
167736
168175
  init_get_args();
167737
168176
  init_pkg_name();
167738
168177
  init_errors_ts();
167739
- import_error_utils30 = __toESM3(require_dist2());
168178
+ import_error_utils31 = __toESM3(require_dist2());
167740
168179
  init_help();
167741
168180
  init_command19();
167742
168181
  init_get_flags_specification();
167743
168182
  init_output_manager();
167744
168183
  init_logout();
168184
+ init_future2();
167745
168185
  }
167746
168186
  });
167747
168187
 
@@ -167782,12 +168222,12 @@ async function add6(client2, argv) {
167782
168222
  const { args: args2 } = parsedArgs;
167783
168223
  if (args2.length !== 1) {
167784
168224
  output_manager_default.error(
167785
- `Invalid number of arguments. Usage: ${import_chalk99.default.cyan(
168225
+ `Invalid number of arguments. Usage: ${import_chalk100.default.cyan(
167786
168226
  `${getCommandName("project add <name>")}`
167787
168227
  )}`
167788
168228
  );
167789
168229
  if (args2.length > 1) {
167790
- const example = import_chalk99.default.cyan(
168230
+ const example = import_chalk100.default.cyan(
167791
168231
  `${getCommandName(`project add "${args2.join(" ")}"`)}`
167792
168232
  );
167793
168233
  output_manager_default.log(
@@ -167815,17 +168255,17 @@ async function add6(client2, argv) {
167815
168255
  const elapsed2 = (0, import_ms20.default)(Date.now() - start);
167816
168256
  const { contextName } = await getScope(client2);
167817
168257
  output_manager_default.log(
167818
- `${import_chalk99.default.cyan("Success!")} Project ${import_chalk99.default.bold(
168258
+ `${import_chalk100.default.cyan("Success!")} Project ${import_chalk100.default.bold(
167819
168259
  name.toLowerCase()
167820
- )} added (${import_chalk99.default.bold(contextName)}) ${import_chalk99.default.gray(`[${elapsed2}]`)}`
168260
+ )} added (${import_chalk100.default.bold(contextName)}) ${import_chalk100.default.gray(`[${elapsed2}]`)}`
167821
168261
  );
167822
168262
  return 0;
167823
168263
  }
167824
- var import_chalk99, import_ms20;
168264
+ var import_chalk100, import_ms20;
167825
168265
  var init_add12 = __esm({
167826
168266
  "src/commands/project/add.ts"() {
167827
168267
  "use strict";
167828
- import_chalk99 = __toESM3(require_source());
168268
+ import_chalk100 = __toESM3(require_source());
167829
168269
  import_ms20 = __toESM3(require_ms());
167830
168270
  init_errors_ts();
167831
168271
  init_pkg_name();
@@ -167882,7 +168322,7 @@ async function list4(client2, argv) {
167882
168322
  const { args: args2, flags: opts } = parsedArgs;
167883
168323
  if (args2.length !== 0) {
167884
168324
  output_manager_default.error(
167885
- `Invalid number of arguments. Usage: ${import_chalk100.default.cyan(
168325
+ `Invalid number of arguments. Usage: ${import_chalk101.default.cyan(
167886
168326
  `${getCommandName("project ls")}`
167887
168327
  )}`
167888
168328
  );
@@ -167890,7 +168330,7 @@ async function list4(client2, argv) {
167890
168330
  }
167891
168331
  const start = Date.now();
167892
168332
  const { contextName } = await getScope(client2);
167893
- output_manager_default.spinner(`Fetching projects in ${import_chalk100.default.bold(contextName)}`);
168333
+ output_manager_default.spinner(`Fetching projects in ${import_chalk101.default.bold(contextName)}`);
167894
168334
  let projectsUrl = "/v9/projects?limit=20";
167895
168335
  const deprecated = opts["--update-required"] || false;
167896
168336
  telemetryClient.trackCliFlagUpdateRequired(deprecated);
@@ -167911,7 +168351,7 @@ async function list4(client2, argv) {
167911
168351
  output_manager_default.stopSpinner();
167912
168352
  const elapsed2 = (0, import_ms21.default)(Date.now() - start);
167913
168353
  output_manager_default.log(
167914
- `${projectList.length > 0 ? "Projects" : "No projects"} found under ${import_chalk100.default.bold(contextName)} ${deprecated ? "that are using a deprecated Node.js version" : "\b"} ${import_chalk100.default.gray(`[${elapsed2}]`)}`
168354
+ `${projectList.length > 0 ? "Projects" : "No projects"} found under ${import_chalk101.default.bold(contextName)} ${deprecated ? "that are using a deprecated Node.js version" : "\b"} ${import_chalk101.default.gray(`[${elapsed2}]`)}`
167915
168355
  );
167916
168356
  if (projectList.length > 0) {
167917
168357
  const tablePrint = table(
@@ -167921,12 +168361,12 @@ async function list4(client2, argv) {
167921
168361
  "Latest Production URL",
167922
168362
  "Updated",
167923
168363
  "Node Version"
167924
- ].map((header) => import_chalk100.default.bold(import_chalk100.default.cyan(header))),
168364
+ ].map((header) => import_chalk101.default.bold(import_chalk101.default.cyan(header))),
167925
168365
  ...projectList.flatMap((project) => [
167926
168366
  [
167927
- import_chalk100.default.bold(project.name),
168367
+ import_chalk101.default.bold(project.name),
167928
168368
  getLatestProdUrl(project),
167929
- import_chalk100.default.gray((0, import_ms21.default)(Date.now() - project.updatedAt)),
168369
+ import_chalk101.default.gray((0, import_ms21.default)(Date.now() - project.updatedAt)),
167930
168370
  project.nodeVersion ?? ""
167931
168371
  ]
167932
168372
  ])
@@ -167951,12 +168391,12 @@ function getLatestProdUrl(project) {
167951
168391
  return `https://${alias2}`;
167952
168392
  return "--";
167953
168393
  }
167954
- var import_ms21, import_chalk100;
168394
+ var import_ms21, import_chalk101;
167955
168395
  var init_list8 = __esm({
167956
168396
  "src/commands/project/list.ts"() {
167957
168397
  "use strict";
167958
168398
  import_ms21 = __toESM3(require_ms());
167959
- import_chalk100 = __toESM3(require_source());
168399
+ import_chalk101 = __toESM3(require_source());
167960
168400
  init_table();
167961
168401
  init_get_command_flags();
167962
168402
  init_pkg_name();
@@ -168007,7 +168447,7 @@ async function rm6(client2, argv) {
168007
168447
  const { args: args2 } = parsedArgs;
168008
168448
  if (args2.length !== 1) {
168009
168449
  output_manager_default.error(
168010
- `Invalid number of arguments. Usage: ${import_chalk101.default.cyan(
168450
+ `Invalid number of arguments. Usage: ${import_chalk102.default.cyan(
168011
168451
  `${getCommandName("project rm <name>")}`
168012
168452
  )}`
168013
168453
  );
@@ -168037,7 +168477,7 @@ async function rm6(client2, argv) {
168037
168477
  }
168038
168478
  const elapsed2 = (0, import_ms22.default)(Date.now() - start);
168039
168479
  output_manager_default.log(
168040
- `${import_chalk101.default.cyan("Success!")} Project ${import_chalk101.default.bold(name)} removed ${import_chalk101.default.gray(
168480
+ `${import_chalk102.default.cyan("Success!")} Project ${import_chalk102.default.bold(name)} removed ${import_chalk102.default.gray(
168041
168481
  `[${elapsed2}]`
168042
168482
  )}`
168043
168483
  );
@@ -168046,22 +168486,22 @@ async function rm6(client2, argv) {
168046
168486
  async function readConfirmation3(client2, projectName) {
168047
168487
  output_manager_default.print(
168048
168488
  prependEmoji(
168049
- `The project ${import_chalk101.default.bold(projectName)} will be removed permanently.
168489
+ `The project ${import_chalk102.default.bold(projectName)} will be removed permanently.
168050
168490
  It will also delete everything under the project including deployments.
168051
168491
  `,
168052
168492
  emoji("warning")
168053
168493
  )
168054
168494
  );
168055
168495
  return await client2.input.confirm(
168056
- `${import_chalk101.default.bold.red("Are you sure?")}`,
168496
+ `${import_chalk102.default.bold.red("Are you sure?")}`,
168057
168497
  false
168058
168498
  );
168059
168499
  }
168060
- var import_chalk101, import_ms22, e;
168500
+ var import_chalk102, import_ms22, e;
168061
168501
  var init_rm10 = __esm({
168062
168502
  "src/commands/project/rm.ts"() {
168063
168503
  "use strict";
168064
- import_chalk101 = __toESM3(require_source());
168504
+ import_chalk102 = __toESM3(require_source());
168065
168505
  import_ms22 = __toESM3(require_ms());
168066
168506
  init_emoji();
168067
168507
  init_errors_ts();
@@ -168108,9 +168548,9 @@ var init_project = __esm({
168108
168548
  // src/commands/project/index.ts
168109
168549
  var project_exports = {};
168110
168550
  __export3(project_exports, {
168111
- default: () => main12
168551
+ default: () => main11
168112
168552
  });
168113
- async function main12(client2) {
168553
+ async function main11(client2) {
168114
168554
  const telemetry2 = new ProjectTelemetryClient({
168115
168555
  opts: {
168116
168556
  store: client2.telemetryEventStore
@@ -168248,7 +168688,7 @@ async function getProjectByDeployment({
168248
168688
  let team;
168249
168689
  try {
168250
168690
  output_manager_default?.spinner(
168251
- `Fetching deployment "${deployId}" in ${import_chalk102.default.bold(contextName)}\u2026`
168691
+ `Fetching deployment "${deployId}" in ${import_chalk103.default.bold(contextName)}\u2026`
168252
168692
  );
168253
168693
  const [teamResult, deploymentResult] = await Promise.allSettled([
168254
168694
  config2.currentTeam ? getTeamById(client2, config2.currentTeam) : void 0,
@@ -168265,12 +168705,12 @@ async function getProjectByDeployment({
168265
168705
  team = teamResult.value;
168266
168706
  deployment = deploymentResult.value;
168267
168707
  output_manager_default?.log(
168268
- `Fetching deployment "${deployId}" in ${import_chalk102.default.bold(contextName)}\u2026`
168708
+ `Fetching deployment "${deployId}" in ${import_chalk103.default.bold(contextName)}\u2026`
168269
168709
  );
168270
168710
  if (deployment.team?.id) {
168271
168711
  if (!team || deployment.team.id !== team.id) {
168272
168712
  const err = new Error(
168273
- team ? `Deployment doesn't belong to current team ${import_chalk102.default.bold(
168713
+ team ? `Deployment doesn't belong to current team ${import_chalk103.default.bold(
168274
168714
  contextName
168275
168715
  )}` : `Deployment belongs to a different team`
168276
168716
  );
@@ -168279,7 +168719,7 @@ async function getProjectByDeployment({
168279
168719
  }
168280
168720
  } else if (team) {
168281
168721
  const err = new Error(
168282
- `Deployment doesn't belong to current team ${import_chalk102.default.bold(contextName)}`
168722
+ `Deployment doesn't belong to current team ${import_chalk103.default.bold(contextName)}`
168283
168723
  );
168284
168724
  err.code = "ERR_INVALID_TEAM";
168285
168725
  throw err;
@@ -168300,11 +168740,11 @@ async function getProjectByDeployment({
168300
168740
  output_manager_default?.stopSpinner();
168301
168741
  }
168302
168742
  }
168303
- var import_chalk102;
168743
+ var import_chalk103;
168304
168744
  var init_get_project_by_deployment = __esm({
168305
168745
  "src/util/projects/get-project-by-deployment.ts"() {
168306
168746
  "use strict";
168307
- import_chalk102 = __toESM3(require_source());
168747
+ import_chalk103 = __toESM3(require_source());
168308
168748
  init_get_deployment();
168309
168749
  init_get_project_by_id_or_name();
168310
168750
  init_get_scope();
@@ -168318,21 +168758,21 @@ var init_get_project_by_deployment = __esm({
168318
168758
  // src/util/alias/render-alias-status.ts
168319
168759
  function renderAliasStatus(status2) {
168320
168760
  if (status2 === "completed") {
168321
- return import_chalk103.default.green(status2);
168761
+ return import_chalk104.default.green(status2);
168322
168762
  }
168323
168763
  if (status2 === "failed") {
168324
- return import_chalk103.default.red(status2);
168764
+ return import_chalk104.default.red(status2);
168325
168765
  }
168326
168766
  if (status2 === "skipped") {
168327
- return import_chalk103.default.gray(status2);
168767
+ return import_chalk104.default.gray(status2);
168328
168768
  }
168329
- return import_chalk103.default.yellow(status2);
168769
+ return import_chalk104.default.yellow(status2);
168330
168770
  }
168331
- var import_chalk103;
168771
+ var import_chalk104;
168332
168772
  var init_render_alias_status = __esm({
168333
168773
  "src/util/alias/render-alias-status.ts"() {
168334
168774
  "use strict";
168335
- import_chalk103 = __toESM3(require_source());
168775
+ import_chalk104 = __toESM3(require_source());
168336
168776
  }
168337
168777
  });
168338
168778
 
@@ -168406,7 +168846,7 @@ async function promoteStatus({
168406
168846
  }
168407
168847
  if (requestedAt < recentThreshold || Date.now() >= promoteTimeout) {
168408
168848
  output_manager_default.log(
168409
- `The promotion exceeded its deadline - rerun ${import_chalk104.default.bold(
168849
+ `The promotion exceeded its deadline - rerun ${import_chalk105.default.bold(
168410
168850
  `${packageName} promote ${toDeploymentId}`
168411
168851
  )} to try again`
168412
168852
  );
@@ -168470,26 +168910,26 @@ async function renderJobSucceeded({
168470
168910
  let deploymentInfo = "";
168471
168911
  try {
168472
168912
  const deployment = await getDeployment(client2, contextName, toDeploymentId);
168473
- deploymentInfo = `${import_chalk104.default.bold(deployment.url)} (${toDeploymentId})`;
168913
+ deploymentInfo = `${import_chalk105.default.bold(deployment.url)} (${toDeploymentId})`;
168474
168914
  } catch (err) {
168475
168915
  output_manager_default.debug(
168476
168916
  `Failed to get deployment url for ${toDeploymentId}: ${err?.toString() || err}`
168477
168917
  );
168478
- deploymentInfo = import_chalk104.default.bold(toDeploymentId);
168918
+ deploymentInfo = import_chalk105.default.bold(toDeploymentId);
168479
168919
  }
168480
168920
  const duration = performingPromote ? elapsed(Date.now() - requestedAt) : "";
168481
168921
  output_manager_default.log(
168482
- `Success! ${import_chalk104.default.bold(
168922
+ `Success! ${import_chalk105.default.bold(
168483
168923
  project.name
168484
168924
  )} was promoted to ${deploymentInfo} ${duration}`
168485
168925
  );
168486
168926
  return 0;
168487
168927
  }
168488
- var import_chalk104, import_ms23;
168928
+ var import_chalk105, import_ms23;
168489
168929
  var init_status = __esm({
168490
168930
  "src/commands/promote/status.ts"() {
168491
168931
  "use strict";
168492
- import_chalk104 = __toESM3(require_source());
168932
+ import_chalk105 = __toESM3(require_source());
168493
168933
  init_elapsed();
168494
168934
  init_format_date();
168495
168935
  init_get_deployment();
@@ -168545,7 +168985,7 @@ async function requestPromote({
168545
168985
  }
168546
168986
  );
168547
168987
  output_manager_default.log(
168548
- `Successfully created new deployment of ${import_chalk105.default.bold(project.name)} at ${newDeployment.inspectorUrl}`
168988
+ `Successfully created new deployment of ${import_chalk106.default.bold(project.name)} at ${newDeployment.inspectorUrl}`
168549
168989
  );
168550
168990
  return 0;
168551
168991
  }
@@ -168557,7 +168997,7 @@ async function requestPromote({
168557
168997
  });
168558
168998
  if (timeout !== void 0 && (0, import_ms24.default)(timeout) === 0) {
168559
168999
  output_manager_default.log(
168560
- `Successfully requested promote of ${import_chalk105.default.bold(project.name)} to ${deployment.url} (${deployment.id})`
169000
+ `Successfully requested promote of ${import_chalk106.default.bold(project.name)} to ${deployment.url} (${deployment.id})`
168561
169001
  );
168562
169002
  output_manager_default.log(`To check promote status, run ${getCommandName("promote")}.`);
168563
169003
  return 0;
@@ -168570,11 +169010,11 @@ async function requestPromote({
168570
169010
  timeout
168571
169011
  });
168572
169012
  }
168573
- var import_chalk105, import_ms24;
169013
+ var import_chalk106, import_ms24;
168574
169014
  var init_request_promote = __esm({
168575
169015
  "src/commands/promote/request-promote.ts"() {
168576
169016
  "use strict";
168577
- import_chalk105 = __toESM3(require_source());
169017
+ import_chalk106 = __toESM3(require_source());
168578
169018
  init_pkg_name();
168579
169019
  init_get_project_by_deployment();
168580
169020
  import_ms24 = __toESM3(require_ms());
@@ -168626,7 +169066,7 @@ var promote_exports = {};
168626
169066
  __export3(promote_exports, {
168627
169067
  default: () => promote_default
168628
169068
  });
168629
- var import_ms25, import_error_utils31, promote_default;
169069
+ var import_ms25, import_error_utils32, promote_default;
168630
169070
  var init_promote2 = __esm({
168631
169071
  "src/commands/promote/index.ts"() {
168632
169072
  "use strict";
@@ -168634,7 +169074,7 @@ var init_promote2 = __esm({
168634
169074
  init_get_args();
168635
169075
  init_get_project_by_cwd_or_link();
168636
169076
  init_error2();
168637
- import_error_utils31 = __toESM3(require_dist2());
169077
+ import_error_utils32 = __toESM3(require_dist2());
168638
169078
  init_request_promote();
168639
169079
  init_status();
168640
169080
  init_command22();
@@ -168705,7 +169145,7 @@ var init_promote2 = __esm({
168705
169145
  yes
168706
169146
  });
168707
169147
  } catch (err) {
168708
- if ((0, import_error_utils31.isErrnoException)(err)) {
169148
+ if ((0, import_error_utils32.isErrnoException)(err)) {
168709
169149
  if (err.code === "ERR_CANCELED") {
168710
169150
  return 0;
168711
169151
  }
@@ -168736,7 +169176,7 @@ async function getDeploymentByIdOrURL({
168736
169176
  let team;
168737
169177
  try {
168738
169178
  output_manager_default.spinner(
168739
- `Fetching deployment "${deployIdOrUrl}" in ${import_chalk106.default.bold(contextName)}\u2026`
169179
+ `Fetching deployment "${deployIdOrUrl}" in ${import_chalk107.default.bold(contextName)}\u2026`
168740
169180
  );
168741
169181
  const [teamResult, deploymentResult] = await Promise.allSettled([
168742
169182
  config2.currentTeam ? getTeamById(client2, config2.currentTeam) : void 0,
@@ -168753,7 +169193,7 @@ async function getDeploymentByIdOrURL({
168753
169193
  team = teamResult.value;
168754
169194
  deployment = deploymentResult.value;
168755
169195
  output_manager_default.log(
168756
- `Fetching deployment "${deployIdOrUrl}" in ${import_chalk106.default.bold(contextName)}\u2026`
169196
+ `Fetching deployment "${deployIdOrUrl}" in ${import_chalk107.default.bold(contextName)}\u2026`
168757
169197
  );
168758
169198
  } finally {
168759
169199
  output_manager_default.stopSpinner();
@@ -168761,7 +169201,7 @@ async function getDeploymentByIdOrURL({
168761
169201
  if (deployment.team?.id) {
168762
169202
  if (!team || deployment.team.id !== team.id) {
168763
169203
  const err = new Error(
168764
- team ? `Deployment doesn't belong to current team ${import_chalk106.default.bold(
169204
+ team ? `Deployment doesn't belong to current team ${import_chalk107.default.bold(
168765
169205
  contextName
168766
169206
  )}` : `Deployment belongs to a different team`
168767
169207
  );
@@ -168770,18 +169210,18 @@ async function getDeploymentByIdOrURL({
168770
169210
  }
168771
169211
  } else if (team) {
168772
169212
  const err = new Error(
168773
- `Deployment doesn't belong to current team ${import_chalk106.default.bold(contextName)}`
169213
+ `Deployment doesn't belong to current team ${import_chalk107.default.bold(contextName)}`
168774
169214
  );
168775
169215
  err.code = "ERR_INVALID_TEAM";
168776
169216
  throw err;
168777
169217
  }
168778
169218
  return deployment;
168779
169219
  }
168780
- var import_chalk106;
169220
+ var import_chalk107;
168781
169221
  var init_get_deployment_by_id_or_url = __esm({
168782
169222
  "src/util/deploy/get-deployment-by-id-or-url.ts"() {
168783
169223
  "use strict";
168784
- import_chalk106 = __toESM3(require_source());
169224
+ import_chalk107 = __toESM3(require_source());
168785
169225
  init_get_deployment();
168786
169226
  init_get_team_by_id();
168787
169227
  init_is_valid_name();
@@ -168920,14 +169360,14 @@ async function redeploy(client2) {
168920
169360
  }
168921
169361
  output_manager_default.print(
168922
169362
  `${prependEmoji(
168923
- `Inspect: ${import_chalk107.default.bold(deployment.inspectorUrl)} ${deployStamp()}`,
169363
+ `Inspect: ${import_chalk108.default.bold(deployment.inspectorUrl)} ${deployStamp()}`,
168924
169364
  emoji("inspect")
168925
169365
  )}
168926
169366
  `
168927
169367
  );
168928
169368
  output_manager_default.print(
168929
169369
  prependEmoji(
168930
- `${isProdDeployment ? "Production" : "Preview"}: ${import_chalk107.default.bold(
169370
+ `${isProdDeployment ? "Production" : "Preview"}: ${import_chalk108.default.bold(
168931
169371
  previewUrl
168932
169372
  )} ${deployStamp()}`,
168933
169373
  emoji("success")
@@ -168995,19 +169435,19 @@ async function redeploy(client2) {
168995
169435
  return printDeploymentStatus(deployment, deployStamp, noWait);
168996
169436
  } catch (err) {
168997
169437
  output_manager_default.prettyError(err);
168998
- if ((0, import_error_utils32.isErrnoException)(err) && err.code === "ERR_INVALID_TEAM") {
169438
+ if ((0, import_error_utils33.isErrnoException)(err) && err.code === "ERR_INVALID_TEAM") {
168999
169439
  output_manager_default.error(
169000
- `Use ${import_chalk107.default.bold("vc switch")} to change your current team`
169440
+ `Use ${import_chalk108.default.bold("vc switch")} to change your current team`
169001
169441
  );
169002
169442
  }
169003
169443
  return 1;
169004
169444
  }
169005
169445
  }
169006
- var import_chalk107, import_client13, import_error_utils32;
169446
+ var import_chalk108, import_client13, import_error_utils33;
169007
169447
  var init_redeploy2 = __esm({
169008
169448
  "src/commands/redeploy/index.ts"() {
169009
169449
  "use strict";
169010
- import_chalk107 = __toESM3(require_source());
169450
+ import_chalk108 = __toESM3(require_source());
169011
169451
  import_client13 = __toESM3(require_dist7());
169012
169452
  init_emoji();
169013
169453
  init_get_args();
@@ -169015,7 +169455,7 @@ var init_redeploy2 = __esm({
169015
169455
  init_get_deployment_by_id_or_url();
169016
169456
  init_get_scope();
169017
169457
  init_error2();
169018
- import_error_utils32 = __toESM3(require_dist2());
169458
+ import_error_utils33 = __toESM3(require_dist2());
169019
169459
  init_util();
169020
169460
  init_print_deployment_status();
169021
169461
  init_stamp();
@@ -169214,7 +169654,7 @@ async function remove5(client2) {
169214
169654
  }
169215
169655
  const { contextName } = await getScope(client2);
169216
169656
  output_manager_default.spinner(
169217
- `Fetching deployment(s) ${ids.map((id) => `"${id}"`).join(" ")} in ${import_chalk108.default.bold(contextName)}`
169657
+ `Fetching deployment(s) ${ids.map((id) => `"${id}"`).join(" ")} in ${import_chalk109.default.bold(contextName)}`
169218
169658
  );
169219
169659
  let aliases;
169220
169660
  let projects;
@@ -169226,7 +169666,7 @@ async function remove5(client2) {
169226
169666
  );
169227
169667
  const [deploymentList, projectList] = await Promise.all([
169228
169668
  Promise.all(
169229
- ids.map((idOrHost) => {
169669
+ ids.map(async (idOrHost) => {
169230
169670
  if (!contextName) {
169231
169671
  throw new Error("Context name is not defined");
169232
169672
  }
@@ -169280,7 +169720,7 @@ async function remove5(client2) {
169280
169720
  });
169281
169721
  if (deployments.length === 0 && projects.length === 0) {
169282
169722
  const safeUnaliased = parsedArgs.flags["--safe"] ? "unaliased" : "any";
169283
- const stylizedIds = ids.map((id) => import_chalk108.default.bold(`"${id}"`)).join(", ");
169723
+ const stylizedIds = ids.map((id) => import_chalk109.default.bold(`"${id}"`)).join(", ");
169284
169724
  const commandName = getCommandName("projects ls");
169285
169725
  log2(
169286
169726
  `Could not find ${safeUnaliased} deployments or projects matching ${stylizedIds}. Run ${commandName} to list.`
@@ -169288,7 +169728,7 @@ async function remove5(client2) {
169288
169728
  return 1;
169289
169729
  }
169290
169730
  log2(
169291
- `Found ${deploymentsAndProjects(deployments, projects)} for removal in ${import_chalk108.default.bold(contextName)} ${elapsed(Date.now() - findStart)}`
169731
+ `Found ${deploymentsAndProjects(deployments, projects)} for removal in ${import_chalk109.default.bold(contextName)} ${elapsed(Date.now() - findStart)}`
169292
169732
  );
169293
169733
  if (deployments.length > 200) {
169294
169734
  output_manager_default.warn(
@@ -169315,11 +169755,11 @@ async function remove5(client2) {
169315
169755
  `Removed ${deploymentsAndProjects(deployments, projects)} ${elapsed(Date.now() - start)}`
169316
169756
  );
169317
169757
  deployments.forEach((depl) => {
169318
- output_manager_default.print(`${import_chalk108.default.gray("-")} ${import_chalk108.default.bold(depl.url)}
169758
+ output_manager_default.print(`${import_chalk109.default.gray("-")} ${import_chalk109.default.bold(depl.url)}
169319
169759
  `);
169320
169760
  });
169321
169761
  projects.forEach((project) => {
169322
- output_manager_default.print(`${import_chalk108.default.gray("-")} ${import_chalk108.default.bold(project.name)}
169762
+ output_manager_default.print(`${import_chalk109.default.gray("-")} ${import_chalk109.default.bold(project.name)}
169323
169763
  `);
169324
169764
  });
169325
169765
  return 0;
@@ -169336,8 +169776,8 @@ function readConfirmation4(deployments, projects) {
169336
169776
  );
169337
169777
  const deploymentTable = table(
169338
169778
  deployments.map((depl) => {
169339
- const time = import_chalk108.default.gray(`${(0, import_ms26.default)(Date.now() - depl.createdAt)} ago`);
169340
- const url3 = depl.url ? import_chalk108.default.underline(`https://${depl.url}`) : "";
169779
+ const time = import_chalk109.default.gray(`${(0, import_ms26.default)(Date.now() - depl.createdAt)} ago`);
169780
+ const url3 = depl.url ? import_chalk109.default.underline(`https://${depl.url}`) : "";
169341
169781
  return [` ${depl.id}`, url3, time];
169342
169782
  }),
169343
169783
  { align: ["l", "r", "l"], hsep: 6 }
@@ -169348,7 +169788,7 @@ function readConfirmation4(deployments, projects) {
169348
169788
  for (const depl of deployments) {
169349
169789
  for (const { alias: alias2 } of depl.aliases) {
169350
169790
  output_manager_default.warn(
169351
- `${import_chalk108.default.underline(`https://${alias2}`)} is an alias for ${import_chalk108.default.bold(depl.url)} and will be removed`
169791
+ `${import_chalk109.default.underline(`https://${alias2}`)} is an alias for ${import_chalk109.default.bold(depl.url)} and will be removed`
169352
169792
  );
169353
169793
  }
169354
169794
  }
@@ -169362,12 +169802,12 @@ function readConfirmation4(deployments, projects) {
169362
169802
  `
169363
169803
  );
169364
169804
  for (const project of projects) {
169365
- output_manager_default.print(`${import_chalk108.default.gray("-")} ${import_chalk108.default.bold(project.name)}
169805
+ output_manager_default.print(`${import_chalk109.default.gray("-")} ${import_chalk109.default.bold(project.name)}
169366
169806
  `);
169367
169807
  }
169368
169808
  }
169369
169809
  output_manager_default.print(
169370
- `${import_chalk108.default.bold.red("> Are you sure?")} ${import_chalk108.default.gray("(y/N) ")}`
169810
+ `${import_chalk109.default.bold.red("> Are you sure?")} ${import_chalk109.default.gray("(y/N) ")}`
169371
169811
  );
169372
169812
  process.stdin.on("data", (d) => {
169373
169813
  process.stdin.pause();
@@ -169384,11 +169824,11 @@ function deploymentsAndProjects(deployments, projects, conjunction = "and") {
169384
169824
  }
169385
169825
  return `${(0, import_pluralize11.default)("deployment", deployments.length, true)} ${conjunction} ${(0, import_pluralize11.default)("project", projects.length, true)}`;
169386
169826
  }
169387
- var import_chalk108, import_ms26, import_pluralize11;
169827
+ var import_chalk109, import_ms26, import_pluralize11;
169388
169828
  var init_remove6 = __esm({
169389
169829
  "src/commands/remove/index.ts"() {
169390
169830
  "use strict";
169391
- import_chalk108 = __toESM3(require_source());
169831
+ import_chalk109 = __toESM3(require_source());
169392
169832
  import_ms26 = __toESM3(require_ms());
169393
169833
  import_pluralize11 = __toESM3(require_pluralize());
169394
169834
  init_table();
@@ -169484,7 +169924,7 @@ async function rollbackStatus({
169484
169924
  }
169485
169925
  if (requestedAt < recentThreshold || Date.now() >= rollbackTimeout) {
169486
169926
  output_manager_default.log(
169487
- `The rollback exceeded its deadline - rerun ${import_chalk109.default.bold(
169927
+ `The rollback exceeded its deadline - rerun ${import_chalk110.default.bold(
169488
169928
  `${packageName} rollback ${toDeploymentId}`
169489
169929
  )} to try again`
169490
169930
  );
@@ -169548,26 +169988,26 @@ async function renderJobSucceeded2({
169548
169988
  let deploymentInfo = "";
169549
169989
  try {
169550
169990
  const deployment = await getDeployment(client2, contextName, toDeploymentId);
169551
- deploymentInfo = `${import_chalk109.default.bold(deployment.url)} (${toDeploymentId})`;
169991
+ deploymentInfo = `${import_chalk110.default.bold(deployment.url)} (${toDeploymentId})`;
169552
169992
  } catch (err) {
169553
169993
  output_manager_default.debug(
169554
169994
  `Failed to get deployment url for ${toDeploymentId}: ${err?.toString() || err}`
169555
169995
  );
169556
- deploymentInfo = import_chalk109.default.bold(toDeploymentId);
169996
+ deploymentInfo = import_chalk110.default.bold(toDeploymentId);
169557
169997
  }
169558
169998
  const duration = performingRollback ? elapsed(Date.now() - requestedAt) : "";
169559
169999
  output_manager_default.log(
169560
- `Success! ${import_chalk109.default.bold(
170000
+ `Success! ${import_chalk110.default.bold(
169561
170001
  project.name
169562
170002
  )} was rolled back to ${deploymentInfo} ${duration}`
169563
170003
  );
169564
170004
  return 0;
169565
170005
  }
169566
- var import_chalk109, import_ms27;
170006
+ var import_chalk110, import_ms27;
169567
170007
  var init_status2 = __esm({
169568
170008
  "src/commands/rollback/status.ts"() {
169569
170009
  "use strict";
169570
- import_chalk109 = __toESM3(require_source());
170010
+ import_chalk110 = __toESM3(require_source());
169571
170011
  init_elapsed();
169572
170012
  init_format_date();
169573
170013
  init_get_deployment();
@@ -169599,7 +170039,7 @@ async function requestRollback({
169599
170039
  });
169600
170040
  if (timeout !== void 0 && (0, import_ms28.default)(timeout) === 0) {
169601
170041
  output_manager_default.log(
169602
- `Successfully requested rollback of ${import_chalk110.default.bold(project.name)} to ${deployment.url} (${deployment.id})`
170042
+ `Successfully requested rollback of ${import_chalk111.default.bold(project.name)} to ${deployment.url} (${deployment.id})`
169603
170043
  );
169604
170044
  output_manager_default.log(`To check rollback status, run ${getCommandName("rollback")}.`);
169605
170045
  return 0;
@@ -169612,11 +170052,11 @@ async function requestRollback({
169612
170052
  timeout
169613
170053
  });
169614
170054
  }
169615
- var import_chalk110, import_ms28;
170055
+ var import_chalk111, import_ms28;
169616
170056
  var init_request_rollback = __esm({
169617
170057
  "src/commands/rollback/request-rollback.ts"() {
169618
170058
  "use strict";
169619
- import_chalk110 = __toESM3(require_source());
170059
+ import_chalk111 = __toESM3(require_source());
169620
170060
  init_pkg_name();
169621
170061
  init_get_project_by_deployment();
169622
170062
  import_ms28 = __toESM3(require_ms());
@@ -169668,14 +170108,14 @@ var rollback_exports = {};
169668
170108
  __export3(rollback_exports, {
169669
170109
  default: () => rollback_default
169670
170110
  });
169671
- var import_error_utils33, import_ms29, rollback_default;
170111
+ var import_error_utils34, import_ms29, rollback_default;
169672
170112
  var init_rollback2 = __esm({
169673
170113
  "src/commands/rollback/index.ts"() {
169674
170114
  "use strict";
169675
170115
  init_get_args();
169676
170116
  init_get_project_by_cwd_or_link();
169677
170117
  init_error2();
169678
- import_error_utils33 = __toESM3(require_dist2());
170118
+ import_error_utils34 = __toESM3(require_dist2());
169679
170119
  import_ms29 = __toESM3(require_ms());
169680
170120
  init_request_rollback();
169681
170121
  init_status2();
@@ -169744,7 +170184,7 @@ var init_rollback2 = __esm({
169744
170184
  timeout
169745
170185
  });
169746
170186
  } catch (err) {
169747
- if ((0, import_error_utils33.isErrnoException)(err)) {
170187
+ if ((0, import_error_utils34.isErrnoException)(err)) {
169748
170188
  if (err.code === "ERR_CANCELED") {
169749
170189
  return 0;
169750
170190
  }
@@ -169764,7 +170204,7 @@ async function list5(client2, argv) {
169764
170204
  const { cwd } = client2;
169765
170205
  if (argv.length !== 0) {
169766
170206
  output_manager_default.error(
169767
- `Invalid number of arguments. Usage: ${import_chalk111.default.cyan(
170207
+ `Invalid number of arguments. Usage: ${import_chalk112.default.cyan(
169768
170208
  `${getCommandName("target ls")}`
169769
170209
  )}`
169770
170210
  );
@@ -169788,12 +170228,12 @@ async function list5(client2, argv) {
169788
170228
  const elapsed2 = (0, import_ms30.default)(Date.now() - start);
169789
170229
  result = withDefaultEnvironmentsIncluded(result);
169790
170230
  output_manager_default.log(
169791
- `${result.length} Environment${result.length === 1 ? "" : "s"} found under ${projectSlugLink} ${import_chalk111.default.gray(`[${elapsed2}]`)}`
170231
+ `${result.length} Environment${result.length === 1 ? "" : "s"} found under ${projectSlugLink} ${import_chalk112.default.gray(`[${elapsed2}]`)}`
169792
170232
  );
169793
170233
  const tablePrint = table(
169794
170234
  [
169795
170235
  ["Target Name", "Target Slug", "Target ID", "Type", "Updated"].map(
169796
- (header) => import_chalk111.default.bold(import_chalk111.default.cyan(header))
170236
+ (header) => import_chalk112.default.bold(import_chalk112.default.cyan(header))
169797
170237
  ),
169798
170238
  ...result.flatMap((target) => {
169799
170239
  const type = target.type === "production" ? "Production" : target.type === "development" ? "Development" : "Preview";
@@ -169803,7 +170243,7 @@ async function list5(client2, argv) {
169803
170243
  target.slug,
169804
170244
  target.id,
169805
170245
  type,
169806
- import_chalk111.default.gray(
170246
+ import_chalk112.default.gray(
169807
170247
  target.updatedAt > 0 ? (0, import_ms30.default)(Date.now() - target.updatedAt) : "-"
169808
170248
  )
169809
170249
  ]
@@ -169850,12 +170290,12 @@ function withDefaultEnvironmentsIncluded(environments) {
169850
170290
  }
169851
170291
  ];
169852
170292
  }
169853
- var import_ms30, import_chalk111;
170293
+ var import_ms30, import_chalk112;
169854
170294
  var init_list9 = __esm({
169855
170295
  "src/commands/target/list.ts"() {
169856
170296
  "use strict";
169857
170297
  import_ms30 = __toESM3(require_ms());
169858
- import_chalk111 = __toESM3(require_source());
170298
+ import_chalk112 = __toESM3(require_source());
169859
170299
  init_table();
169860
170300
  init_command27();
169861
170301
  init_pkg_name();
@@ -169886,9 +170326,9 @@ var init_target = __esm({
169886
170326
  // src/commands/target/index.ts
169887
170327
  var target_exports = {};
169888
170328
  __export3(target_exports, {
169889
- default: () => main13
170329
+ default: () => main12
169890
170330
  });
169891
- async function main13(client2) {
170331
+ async function main12(client2) {
169892
170332
  let parsedArgs;
169893
170333
  const flagsSpecification = getFlagsSpecification(targetCommand.options);
169894
170334
  try {
@@ -170056,7 +170496,7 @@ async function list6(client2, argv) {
170056
170496
  client2.stdout.write("\n");
170057
170497
  const teamTable = table(
170058
170498
  [
170059
- ["id", "email / name"].map((str) => (0, import_chalk112.gray)(str)),
170499
+ ["id", "email / name"].map((str) => (0, import_chalk113.gray)(str)),
170060
170500
  ...teamList.map((team) => [team.value, team.name])
170061
170501
  ],
170062
170502
  { hsep: 5 }
@@ -170073,13 +170513,13 @@ async function list6(client2, argv) {
170073
170513
  }
170074
170514
  return 0;
170075
170515
  }
170076
- var import_chalk112;
170516
+ var import_chalk113;
170077
170517
  var init_list11 = __esm({
170078
170518
  "src/commands/teams/list.ts"() {
170079
170519
  "use strict";
170080
170520
  init_chars();
170081
170521
  init_table();
170082
- import_chalk112 = __toESM3(require_source());
170522
+ import_chalk113 = __toESM3(require_source());
170083
170523
  init_get_user();
170084
170524
  init_get_teams();
170085
170525
  init_pkg_name();
@@ -170174,7 +170614,7 @@ Please select a team scope using ${getCommandName(
170174
170614
  return 1;
170175
170615
  }
170176
170616
  output_manager_default.log(
170177
- introMsg || `Inviting team members to ${import_chalk113.default.bold(currentTeam.name)}`
170617
+ introMsg || `Inviting team members to ${import_chalk114.default.bold(currentTeam.name)}`
170178
170618
  );
170179
170619
  telemetry2.trackCliArgumentEmail(emails);
170180
170620
  if (emails.length > 0) {
@@ -170194,10 +170634,10 @@ Please select a team scope using ${getCommandName(
170194
170634
  throw err;
170195
170635
  }
170196
170636
  output_manager_default.log(
170197
- `${import_chalk113.default.cyan(chars_default.tick)} ${email3}${userInfo ? ` (${userInfo})` : ""} ${elapsed2()}`
170637
+ `${import_chalk114.default.cyan(chars_default.tick)} ${email3}${userInfo ? ` (${userInfo})` : ""} ${elapsed2()}`
170198
170638
  );
170199
170639
  } else {
170200
- output_manager_default.log(`${import_chalk113.default.red(`\u2716 ${email3}`)} ${import_chalk113.default.gray("[invalid]")}`);
170640
+ output_manager_default.log(`${import_chalk114.default.red(`\u2716 ${email3}`)} ${import_chalk114.default.gray("[invalid]")}`);
170201
170641
  }
170202
170642
  }
170203
170643
  return 0;
@@ -170214,7 +170654,7 @@ Please select a team scope using ${getCommandName(
170214
170654
  validate: validateEmail2
170215
170655
  });
170216
170656
  } catch (err) {
170217
- if (!(0, import_error_utils34.isError)(err) || err.message !== "USER_ABORT") {
170657
+ if (!(0, import_error_utils35.isError)(err) || err.message !== "USER_ABORT") {
170218
170658
  throw err;
170219
170659
  }
170220
170660
  }
@@ -170230,24 +170670,24 @@ Please select a team scope using ${getCommandName(
170230
170670
  );
170231
170671
  email2 = `${email2}${username ? ` (${username})` : ""} ${elapsed2()}`;
170232
170672
  emails.push(email2);
170233
- output_manager_default.log(`${import_chalk113.default.cyan(chars_default.tick)} ${sentEmailPrefix}${email2}`);
170673
+ output_manager_default.log(`${import_chalk114.default.cyan(chars_default.tick)} ${sentEmailPrefix}${email2}`);
170234
170674
  if (hasError) {
170235
170675
  hasError = false;
170236
170676
  process.stderr.write(eraseLines(emails.length + 2));
170237
170677
  output_manager_default.log(
170238
- introMsg || `Inviting team members to ${import_chalk113.default.bold(currentTeam.name)}`
170678
+ introMsg || `Inviting team members to ${import_chalk114.default.bold(currentTeam.name)}`
170239
170679
  );
170240
170680
  for (const email3 of emails) {
170241
- output_manager_default.log(`${import_chalk113.default.cyan(chars_default.tick)} ${inviteUserPrefix}${email3}`);
170681
+ output_manager_default.log(`${import_chalk114.default.cyan(chars_default.tick)} ${inviteUserPrefix}${email3}`);
170242
170682
  }
170243
170683
  }
170244
170684
  } catch (err) {
170245
170685
  output_manager_default.stopSpinner();
170246
170686
  process.stderr.write(eraseLines(emails.length + 2));
170247
- output_manager_default.error((0, import_error_utils34.errorToString)(err));
170687
+ output_manager_default.error((0, import_error_utils35.errorToString)(err));
170248
170688
  hasError = true;
170249
170689
  for (const email3 of emails) {
170250
- output_manager_default.log(`${import_chalk113.default.cyan(chars_default.tick)} ${sentEmailPrefix}${email3}`);
170690
+ output_manager_default.log(`${import_chalk114.default.cyan(chars_default.tick)} ${sentEmailPrefix}${email3}`);
170251
170691
  }
170252
170692
  }
170253
170693
  }
@@ -170260,16 +170700,16 @@ Please select a team scope using ${getCommandName(
170260
170700
  } else {
170261
170701
  output_manager_default.success(`Invited ${n} teammate${n > 1 ? "s" : ""}`);
170262
170702
  for (const email3 of emails) {
170263
- output_manager_default.log(`${import_chalk113.default.cyan(chars_default.tick)} ${inviteUserPrefix}${email3}`);
170703
+ output_manager_default.log(`${import_chalk114.default.cyan(chars_default.tick)} ${inviteUserPrefix}${email3}`);
170264
170704
  }
170265
170705
  }
170266
170706
  return 0;
170267
170707
  }
170268
- var import_chalk113, import_error_utils34, validateEmail2, domains;
170708
+ var import_chalk114, import_error_utils35, validateEmail2, domains;
170269
170709
  var init_invite2 = __esm({
170270
170710
  "src/commands/teams/invite.ts"() {
170271
170711
  "use strict";
170272
- import_chalk113 = __toESM3(require_source());
170712
+ import_chalk114 = __toESM3(require_source());
170273
170713
  init_cmd();
170274
170714
  init_stamp();
170275
170715
  init_param();
@@ -170281,7 +170721,7 @@ var init_invite2 = __esm({
170281
170721
  init_get_teams();
170282
170722
  init_invite_user_to_team();
170283
170723
  init_errors_ts();
170284
- import_error_utils34 = __toESM3(require_dist2());
170724
+ import_error_utils35 = __toESM3(require_dist2());
170285
170725
  init_invite();
170286
170726
  init_output_manager();
170287
170727
  init_get_args();
@@ -170345,7 +170785,7 @@ async function add7(client2) {
170345
170785
  let team;
170346
170786
  let elapsed2;
170347
170787
  output_manager_default.log(
170348
- `Pick a team identifier for its URL (e.g.: ${import_chalk114.default.cyan(
170788
+ `Pick a team identifier for its URL (e.g.: ${import_chalk115.default.cyan(
170349
170789
  "`vercel.com/acme`"
170350
170790
  )})`
170351
170791
  );
@@ -170357,7 +170797,7 @@ async function add7(client2) {
170357
170797
  default: slug
170358
170798
  });
170359
170799
  } catch (err) {
170360
- if ((0, import_error_utils35.isError)(err) && err.message === "USER_ABORT") {
170800
+ if ((0, import_error_utils36.isError)(err) && err.message === "USER_ABORT") {
170361
170801
  output_manager_default.log("Canceled");
170362
170802
  return 0;
170363
170803
  }
@@ -170370,13 +170810,13 @@ async function add7(client2) {
170370
170810
  } catch (err) {
170371
170811
  output_manager_default.stopSpinner();
170372
170812
  output_manager_default.print(eraseLines(2));
170373
- output_manager_default.error((0, import_error_utils35.errorToString)(err));
170813
+ output_manager_default.error((0, import_error_utils36.errorToString)(err));
170374
170814
  }
170375
170815
  } while (!team);
170376
170816
  output_manager_default.stopSpinner();
170377
170817
  process.stdout.write(eraseLines(2));
170378
170818
  output_manager_default.success(`Team created ${elapsed2()}`);
170379
- output_manager_default.log(`${import_chalk114.default.cyan(`${chars_default.tick} `) + teamUrlPrefix + slug}
170819
+ output_manager_default.log(`${import_chalk115.default.cyan(`${chars_default.tick} `) + teamUrlPrefix + slug}
170380
170820
  `);
170381
170821
  output_manager_default.log("Pick a display name for your team");
170382
170822
  let name;
@@ -170386,7 +170826,7 @@ async function add7(client2) {
170386
170826
  validate: validateName
170387
170827
  });
170388
170828
  } catch (err) {
170389
- if ((0, import_error_utils35.isError)(err) && err.message === "USER_ABORT") {
170829
+ if ((0, import_error_utils36.isError)(err) && err.message === "USER_ABORT") {
170390
170830
  output_manager_default.log("No name specified");
170391
170831
  return 2;
170392
170832
  }
@@ -170399,7 +170839,7 @@ async function add7(client2) {
170399
170839
  process.stdout.write(eraseLines(2));
170400
170840
  team = Object.assign(team, res);
170401
170841
  output_manager_default.success(`Team name saved ${elapsed2()}`);
170402
- output_manager_default.log(`${import_chalk114.default.cyan(`${chars_default.tick} `) + teamNamePrefix + team.name}
170842
+ output_manager_default.log(`${import_chalk115.default.cyan(`${chars_default.tick} `) + teamNamePrefix + team.name}
170403
170843
  `);
170404
170844
  output_manager_default.spinner("Saving");
170405
170845
  client2.config.currentTeam = team.id;
@@ -170413,11 +170853,11 @@ async function add7(client2) {
170413
170853
  });
170414
170854
  return 0;
170415
170855
  }
170416
- var import_chalk114, import_error_utils35, validateSlug, validateName, teamUrlPrefix, teamNamePrefix;
170856
+ var import_chalk115, import_error_utils36, validateSlug, validateName, teamUrlPrefix, teamNamePrefix;
170417
170857
  var init_add13 = __esm({
170418
170858
  "src/commands/teams/add.ts"() {
170419
170859
  "use strict";
170420
- import_chalk114 = __toESM3(require_source());
170860
+ import_chalk115 = __toESM3(require_source());
170421
170861
  init_stamp();
170422
170862
  init_erase_lines();
170423
170863
  init_chars();
@@ -170426,11 +170866,11 @@ var init_add13 = __esm({
170426
170866
  init_pkg_name();
170427
170867
  init_create_team();
170428
170868
  init_patch_team();
170429
- import_error_utils35 = __toESM3(require_dist2());
170869
+ import_error_utils36 = __toESM3(require_dist2());
170430
170870
  init_output_manager();
170431
170871
  validateSlug = (value) => /^[a-z]+[a-z0-9_-]*$/.test(value);
170432
170872
  validateName = (value) => /^[ a-zA-Z0-9_-]+$/.test(value);
170433
- teamUrlPrefix = "Team URL".padEnd(14) + import_chalk114.default.gray("vercel.com/");
170873
+ teamUrlPrefix = "Team URL".padEnd(14) + import_chalk115.default.gray("vercel.com/");
170434
170874
  teamNamePrefix = "Team Name".padEnd(14);
170435
170875
  }
170436
170876
  });
@@ -170489,7 +170929,7 @@ async function change(client2, argv) {
170489
170929
  let title9 = `${team.name} (${team.slug})`;
170490
170930
  const selected = team.id === currentTeam?.id;
170491
170931
  if (selected) {
170492
- title9 += ` ${import_chalk115.default.bold("(current)")}`;
170932
+ title9 += ` ${import_chalk116.default.bold("(current)")}`;
170493
170933
  }
170494
170934
  if (team.limited) {
170495
170935
  title9 += ` ${emoji("locked")}`;
@@ -170501,7 +170941,7 @@ async function change(client2, argv) {
170501
170941
  selected
170502
170942
  };
170503
170943
  });
170504
- let suffix = personalScopeSelected ? ` ${import_chalk115.default.bold("(current)")}` : "";
170944
+ let suffix = personalScopeSelected ? ` ${import_chalk116.default.bold("(current)")}` : "";
170505
170945
  if (user.limited) {
170506
170946
  suffix += ` ${emoji("locked")}`;
170507
170947
  }
@@ -170547,14 +170987,14 @@ async function change(client2, argv) {
170547
170987
  }
170548
170988
  updateCurrentTeam(config2);
170549
170989
  output_manager_default.success(
170550
- `Your account (${import_chalk115.default.bold(user.username)}) is now active!`
170990
+ `Your account (${import_chalk116.default.bold(user.username)}) is now active!`
170551
170991
  );
170552
170992
  return 0;
170553
170993
  }
170554
170994
  const newTeam = teams2.find((team) => team.slug === desiredSlug);
170555
170995
  if (!newTeam) {
170556
170996
  output_manager_default.error(
170557
- `You do not have permission to access scope ${import_chalk115.default.bold(desiredSlug)}.`
170997
+ `You do not have permission to access scope ${import_chalk116.default.bold(desiredSlug)}.`
170558
170998
  );
170559
170999
  return 1;
170560
171000
  }
@@ -170572,15 +171012,15 @@ async function change(client2, argv) {
170572
171012
  }
170573
171013
  updateCurrentTeam(config2, newTeam);
170574
171014
  output_manager_default.success(
170575
- `The team ${import_chalk115.default.bold(newTeam.name)} (${newTeam.slug}) is now active!`
171015
+ `The team ${import_chalk116.default.bold(newTeam.name)} (${newTeam.slug}) is now active!`
170576
171016
  );
170577
171017
  return 0;
170578
171018
  }
170579
- var import_chalk115, updateCurrentTeam;
171019
+ var import_chalk116, updateCurrentTeam;
170580
171020
  var init_switch2 = __esm({
170581
171021
  "src/commands/teams/switch.ts"() {
170582
171022
  "use strict";
170583
- import_chalk115 = __toESM3(require_source());
171023
+ import_chalk116 = __toESM3(require_source());
170584
171024
  init_emoji();
170585
171025
  init_get_user();
170586
171026
  init_get_teams();
@@ -170759,13 +171199,13 @@ var init_teams2 = __esm({
170759
171199
  // src/commands/telemetry/status.ts
170760
171200
  async function status(client2) {
170761
171201
  const enabled = client2.config.telemetry?.enabled !== false;
170762
- const status2 = enabled ? import_chalk116.default.green("Enabled") : import_chalk116.default.red("Disabled");
171202
+ const status2 = enabled ? import_chalk117.default.green("Enabled") : import_chalk117.default.red("Disabled");
170763
171203
  output_manager_default.print("\n");
170764
- output_manager_default.log(`${import_chalk116.default.bold("Telemetry status")}: ${status2}
171204
+ output_manager_default.log(`${import_chalk117.default.bold("Telemetry status")}: ${status2}
170765
171205
  `);
170766
171206
  const learnMoreMessage = `
170767
171207
 
170768
- Learn more: ${import_chalk116.default.cyan("https://vercel.com/docs/cli/about-telemetry")}`;
171208
+ Learn more: ${import_chalk117.default.cyan("https://vercel.com/docs/cli/about-telemetry")}`;
170769
171209
  if (enabled) {
170770
171210
  output_manager_default.log(`You have opted in to Vercel CLI telemetry${learnMoreMessage}`);
170771
171211
  } else {
@@ -170776,11 +171216,11 @@ Learn more: ${import_chalk116.default.cyan("https://vercel.com/docs/cli/about-te
170776
171216
  }
170777
171217
  return 0;
170778
171218
  }
170779
- var import_chalk116;
171219
+ var import_chalk117;
170780
171220
  var init_status3 = __esm({
170781
171221
  "src/commands/telemetry/status.ts"() {
170782
171222
  "use strict";
170783
- import_chalk116 = __toESM3(require_source());
171223
+ import_chalk117 = __toESM3(require_source());
170784
171224
  init_output_manager();
170785
171225
  }
170786
171226
  });
@@ -170961,7 +171401,7 @@ async function telemetry(client2) {
170961
171401
  default: {
170962
171402
  const errorMessage = parsedArguments.args.length !== 2 ? "Invalid number of arguments" : "Invalid subcommand";
170963
171403
  output_manager_default.print(
170964
- `${import_chalk117.default.red("Error")}: ${errorMessage}. See help instructions for usage:
171404
+ `${import_chalk118.default.red("Error")}: ${errorMessage}. See help instructions for usage:
170965
171405
  `
170966
171406
  );
170967
171407
  output_manager_default.print(help2(telemetryCommand, { columns: client2.stderr.columns }));
@@ -170969,7 +171409,7 @@ async function telemetry(client2) {
170969
171409
  }
170970
171410
  }
170971
171411
  }
170972
- var import_chalk117, COMMAND_CONFIG14;
171412
+ var import_chalk118, COMMAND_CONFIG14;
170973
171413
  var init_telemetry3 = __esm({
170974
171414
  "src/commands/telemetry/index.ts"() {
170975
171415
  "use strict";
@@ -170984,7 +171424,7 @@ var init_telemetry3 = __esm({
170984
171424
  init_command29();
170985
171425
  init_get_flags_specification();
170986
171426
  init_telemetry2();
170987
- import_chalk117 = __toESM3(require_source());
171427
+ import_chalk118 = __toESM3(require_source());
170988
171428
  init_output_manager();
170989
171429
  init_commands();
170990
171430
  COMMAND_CONFIG14 = {
@@ -171055,11 +171495,11 @@ var init_whoami2 = __esm({
171055
171495
  });
171056
171496
 
171057
171497
  // src/index.ts
171058
- var import_error_utils36 = __toESM3(require_dist2());
171498
+ var import_error_utils37 = __toESM3(require_dist2());
171059
171499
  var import_path40 = require("path");
171060
171500
  var import_fs8 = require("fs");
171061
171501
  var import_fs_extra23 = __toESM3(require_lib());
171062
- var import_chalk118 = __toESM3(require_source());
171502
+ var import_chalk119 = __toESM3(require_source());
171063
171503
  var import_epipebomb = __toESM3(require_epipebomb());
171064
171504
 
171065
171505
  // src/util/get-latest-version/index.ts
@@ -171334,7 +171774,7 @@ init_errors_ts();
171334
171774
  init_errors_ts();
171335
171775
 
171336
171776
  // src/util/constants.ts
171337
- var SENTRY_DSN = void 0;
171777
+ var SENTRY_DSN = "https://26a24e59ba954011919a524b341b6ab5@sentry.io/1323225";
171338
171778
 
171339
171779
  // src/index.ts
171340
171780
  init_get_update_command();
@@ -171847,7 +172287,7 @@ init_output_manager();
171847
172287
  try {
171848
172288
  process.cwd();
171849
172289
  } catch (err) {
171850
- if ((0, import_error_utils36.isError)(err) && err.message.includes("uv_cwd")) {
172290
+ if ((0, import_error_utils37.isError)(err) && err.message.includes("uv_cwd")) {
171851
172291
  console.error("Error: The current working directory does not exist.");
171852
172292
  process.exit(1);
171853
172293
  }
@@ -171880,7 +172320,7 @@ Sentry.init({
171880
172320
  var client;
171881
172321
  var { isTTY: isTTY2 } = process.stdout;
171882
172322
  var apiUrl = "https://api.vercel.com";
171883
- var main14 = async () => {
172323
+ var main13 = async () => {
171884
172324
  if (process.env.FORCE_TTY === "1") {
171885
172325
  isTTY2 = true;
171886
172326
  process.stdout.isTTY = true;
@@ -171931,13 +172371,13 @@ var main14 = async () => {
171931
172371
  const betaCommands = [];
171932
172372
  if (betaCommands.includes(targetOrSubcommand)) {
171933
172373
  output_manager_default.print(
171934
- `${import_chalk118.default.grey(
172374
+ `${import_chalk119.default.grey(
171935
172375
  `${getTitleName()} CLI ${pkg_default.version} ${targetOrSubcommand} (beta) \u2014 https://vercel.com/feedback`
171936
172376
  )}
171937
172377
  `
171938
172378
  );
171939
172379
  } else {
171940
- output_manager_default.print(`${import_chalk118.default.grey(`${getTitleName()} CLI ${pkg_default.version}`)}
172380
+ output_manager_default.print(`${import_chalk119.default.grey(`${getTitleName()} CLI ${pkg_default.version}`)}
171941
172381
  `);
171942
172382
  }
171943
172383
  if (!targetOrSubcommand && parsedArgs.flags["--version"]) {
@@ -171956,7 +172396,7 @@ var main14 = async () => {
171956
172396
  output_manager_default.error(
171957
172397
  `An unexpected error occurred while trying to create the global directory "${humanizePath(
171958
172398
  VERCEL_DIR3
171959
- )}" ${(0, import_error_utils36.errorToString)(err)}`
172399
+ )}" ${(0, import_error_utils37.errorToString)(err)}`
171960
172400
  );
171961
172401
  return 1;
171962
172402
  }
@@ -171964,7 +172404,7 @@ var main14 = async () => {
171964
172404
  try {
171965
172405
  config2 = readConfigFile();
171966
172406
  } catch (err) {
171967
- if ((0, import_error_utils36.isErrnoException)(err) && err.code === "ENOENT") {
172407
+ if ((0, import_error_utils37.isErrnoException)(err) && err.code === "ENOENT") {
171968
172408
  config2 = defaultGlobalConfig;
171969
172409
  try {
171970
172410
  writeToConfigFile(config2);
@@ -171972,7 +172412,7 @@ var main14 = async () => {
171972
172412
  output_manager_default.error(
171973
172413
  `An unexpected error occurred while trying to save the config to "${humanizePath(
171974
172414
  VERCEL_CONFIG_PATH
171975
- )}" ${(0, import_error_utils36.errorToString)(err2)}`
172415
+ )}" ${(0, import_error_utils37.errorToString)(err2)}`
171976
172416
  );
171977
172417
  return 1;
171978
172418
  }
@@ -171980,7 +172420,7 @@ var main14 = async () => {
171980
172420
  output_manager_default.error(
171981
172421
  `An unexpected error occurred while trying to read the config in "${humanizePath(
171982
172422
  VERCEL_CONFIG_PATH
171983
- )}" ${(0, import_error_utils36.errorToString)(err)}`
172423
+ )}" ${(0, import_error_utils37.errorToString)(err)}`
171984
172424
  );
171985
172425
  return 1;
171986
172426
  }
@@ -171989,7 +172429,7 @@ var main14 = async () => {
171989
172429
  try {
171990
172430
  authConfig = readAuthConfigFile();
171991
172431
  } catch (err) {
171992
- if ((0, import_error_utils36.isErrnoException)(err) && err.code === "ENOENT") {
172432
+ if ((0, import_error_utils37.isErrnoException)(err) && err.code === "ENOENT") {
171993
172433
  authConfig = defaultAuthConfig;
171994
172434
  try {
171995
172435
  writeToAuthConfigFile(authConfig);
@@ -171997,7 +172437,7 @@ var main14 = async () => {
171997
172437
  output_manager_default.error(
171998
172438
  `An unexpected error occurred while trying to write the auth config to "${humanizePath(
171999
172439
  VERCEL_AUTH_CONFIG_PATH
172000
- )}" ${(0, import_error_utils36.errorToString)(err2)}`
172440
+ )}" ${(0, import_error_utils37.errorToString)(err2)}`
172001
172441
  );
172002
172442
  return 1;
172003
172443
  }
@@ -172005,7 +172445,7 @@ var main14 = async () => {
172005
172445
  output_manager_default.error(
172006
172446
  `An unexpected error occurred while trying to read the auth config in "${humanizePath(
172007
172447
  VERCEL_AUTH_CONFIG_PATH
172008
- )}" ${(0, import_error_utils36.errorToString)(err)}`
172448
+ )}" ${(0, import_error_utils37.errorToString)(err)}`
172009
172449
  );
172010
172450
  return 1;
172011
172451
  }
@@ -172174,7 +172614,7 @@ var main14 = async () => {
172174
172614
  if (err instanceof Error) {
172175
172615
  output_manager_default.debug(err.stack || err.toString());
172176
172616
  }
172177
- if ((0, import_error_utils36.isErrnoException)(err) && err.code === "NOT_AUTHORIZED") {
172617
+ if ((0, import_error_utils37.isErrnoException)(err) && err.code === "NOT_AUTHORIZED") {
172178
172618
  output_manager_default.prettyError({
172179
172619
  message: `You do not have access to the specified account`,
172180
172620
  link: "https://err.sh/vercel/scope-not-accessible"
@@ -172195,14 +172635,14 @@ var main14 = async () => {
172195
172635
  try {
172196
172636
  teams2 = await getTeams(client);
172197
172637
  } catch (err) {
172198
- if ((0, import_error_utils36.isErrnoException)(err) && err.code === "not_authorized") {
172638
+ if ((0, import_error_utils37.isErrnoException)(err) && err.code === "not_authorized") {
172199
172639
  output_manager_default.prettyError({
172200
172640
  message: `You do not have access to the specified team`,
172201
172641
  link: "https://err.sh/vercel/scope-not-accessible"
172202
172642
  });
172203
172643
  return 1;
172204
172644
  }
172205
- if ((0, import_error_utils36.isErrnoException)(err) && err.code === "rate_limited") {
172645
+ if ((0, import_error_utils37.isErrnoException)(err) && err.code === "rate_limited") {
172206
172646
  output_manager_default.prettyError({
172207
172647
  message: "Rate limited. Too many requests to the same endpoint: /teams"
172208
172648
  });
@@ -172235,7 +172675,7 @@ var main14 = async () => {
172235
172675
  );
172236
172676
  telemetry2.trackCliExtension();
172237
172677
  } catch (err) {
172238
- if ((0, import_error_utils36.isErrnoException)(err) && err.code === "ENOENT") {
172678
+ if ((0, import_error_utils37.isErrnoException)(err) && err.code === "ENOENT") {
172239
172679
  targetCommand2 = subcommand = "deploy";
172240
172680
  } else {
172241
172681
  throw err;
@@ -172381,7 +172821,7 @@ var main14 = async () => {
172381
172821
  exitCode2 = await func(client);
172382
172822
  }
172383
172823
  } catch (err) {
172384
- if ((0, import_error_utils36.isErrnoException)(err) && err.code === "ENOTFOUND") {
172824
+ if ((0, import_error_utils37.isErrnoException)(err) && err.code === "ENOTFOUND") {
172385
172825
  const matches = /getaddrinfo ENOTFOUND (.*)$/.exec(err.message || "");
172386
172826
  if (matches && matches[1]) {
172387
172827
  const hostname2 = matches[1];
@@ -172396,7 +172836,7 @@ var main14 = async () => {
172396
172836
  }
172397
172837
  return 1;
172398
172838
  }
172399
- if ((0, import_error_utils36.isErrnoException)(err) && err.code === "ECONNRESET") {
172839
+ if ((0, import_error_utils37.isErrnoException)(err) && err.code === "ECONNRESET") {
172400
172840
  const matches = /request to https:\/\/(.*?)\//.exec(err.message || "");
172401
172841
  const hostname2 = matches?.[1];
172402
172842
  if (hostname2) {
@@ -172408,7 +172848,7 @@ var main14 = async () => {
172408
172848
  }
172409
172849
  return 1;
172410
172850
  }
172411
- if ((0, import_error_utils36.isErrnoException)(err) && (err.code === "NOT_AUTHORIZED" || err.code === "TEAM_DELETED")) {
172851
+ if ((0, import_error_utils37.isErrnoException)(err) && (err.code === "NOT_AUTHORIZED" || err.code === "TEAM_DELETED")) {
172412
172852
  output_manager_default.prettyError(err);
172413
172853
  return 1;
172414
172854
  }
@@ -172417,7 +172857,7 @@ var main14 = async () => {
172417
172857
  output_manager_default.prettyError(err);
172418
172858
  return 1;
172419
172859
  }
172420
- if ((0, import_error_utils36.isErrnoException)(err)) {
172860
+ if ((0, import_error_utils37.isErrnoException)(err)) {
172421
172861
  if (typeof err.stack === "string") {
172422
172862
  output_manager_default.debug(err.stack);
172423
172863
  }
@@ -172459,27 +172899,27 @@ ${err.stack}`);
172459
172899
  };
172460
172900
  process.on("unhandledRejection", handleRejection);
172461
172901
  process.on("uncaughtException", handleUnexpected);
172462
- main14().then(async (exitCode2) => {
172902
+ main13().then(async (exitCode2) => {
172463
172903
  if (isTTY2 && !process.env.NO_UPDATE_NOTIFIER) {
172464
172904
  const latest = getLatestVersion({
172465
172905
  pkg: pkg_default
172466
172906
  });
172467
172907
  if (latest) {
172468
172908
  const changelog = "https://github.com/vercel/vercel/releases";
172469
- const errorMsg = exitCode2 && exitCode2 !== 2 ? import_chalk118.default.magenta(
172909
+ const errorMsg = exitCode2 && exitCode2 !== 2 ? import_chalk119.default.magenta(
172470
172910
  `
172471
172911
 
172472
- The latest update ${import_chalk118.default.italic(
172912
+ The latest update ${import_chalk119.default.italic(
172473
172913
  "may"
172474
172914
  )} fix any errors that occurred.`
172475
172915
  ) : "";
172476
172916
  output_manager_default.print(
172477
172917
  box(
172478
- `Update available! ${import_chalk118.default.gray(`v${pkg_default.version}`)} \u226B ${import_chalk118.default.green(
172918
+ `Update available! ${import_chalk119.default.gray(`v${pkg_default.version}`)} \u226B ${import_chalk119.default.green(
172479
172919
  `v${latest}`
172480
172920
  )}
172481
172921
  Changelog: ${output_manager_default.link(changelog, changelog, { fallback: false })}
172482
- Run ${import_chalk118.default.cyan(cmd(await getUpdateCommand()))} to update.${errorMsg}`
172922
+ Run ${import_chalk119.default.cyan(cmd(await getUpdateCommand()))} to update.${errorMsg}`
172483
172923
  )
172484
172924
  );
172485
172925
  output_manager_default.print("\n\n");