vercel 54.17.1 → 54.17.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunks/{add-QQY6QOTO.js → add-PQWZCK7O.js} +5 -5
- package/dist/chunks/{chunk-MS3WAXLU.js → chunk-2CYJVSAM.js} +1 -1
- package/dist/chunks/{chunk-NRIXI6V5.js → chunk-4FG6Q2EM.js} +1 -1
- package/dist/chunks/{chunk-DDTKG4J3.js → chunk-5FAPBIX6.js} +1 -1
- package/dist/chunks/{chunk-2F6JT2OC.js → chunk-6V37RSQB.js} +1 -1
- package/dist/chunks/{chunk-YW7AYO7N.js → chunk-ATBH7KGL.js} +1 -1
- package/dist/chunks/{chunk-KTX4RQFM.js → chunk-BHMMV3HE.js} +67 -30
- package/dist/chunks/{chunk-V7JDSYIZ.js → chunk-FMBDRMTZ.js} +4 -4
- package/dist/chunks/{chunk-HJ2TEW5Y.js → chunk-G4YL2LRL.js} +2 -2
- package/dist/chunks/{chunk-A4B4JQVP.js → chunk-HCJRHKSM.js} +2 -2
- package/dist/chunks/{chunk-7B44AIGE.js → chunk-IAOBSXJ5.js} +3 -3
- package/dist/chunks/{chunk-LGR4JRFA.js → chunk-JKIM3UW3.js} +4 -4
- package/dist/chunks/{chunk-7AQDR2RX.js → chunk-MB63D7UN.js} +1 -1
- package/dist/chunks/{chunk-4D42VZRX.js → chunk-NRP6ZKXJ.js} +1 -1
- package/dist/chunks/{chunk-DWA63R5L.js → chunk-OSXRHH6W.js} +51 -44
- package/dist/chunks/{chunk-MLVCDMCS.js → chunk-OYQKUG4C.js} +4 -4
- package/dist/chunks/{chunk-WJPWCLMH.js → chunk-QM7D5H2G.js} +2 -2
- package/dist/chunks/{chunk-P5AZW6W6.js → chunk-QMMMXYOY.js} +3 -3
- package/dist/chunks/{chunk-E6FCE2XJ.js → chunk-SBYEIQ32.js} +1 -1
- package/dist/chunks/{chunk-VO7PRFFG.js → chunk-UXP2N2WD.js} +70 -4
- package/dist/chunks/{chunk-NHGCQRK5.js → chunk-X5UROEGN.js} +12 -0
- package/dist/chunks/{compile-vercel-config-D2OQCK4B.js → compile-vercel-config-45XN4U4D.js} +2 -2
- package/dist/chunks/{delete-VMW7FORM.js → delete-RQYOSBNO.js} +3 -3
- package/dist/chunks/{disable-BDFZELDL.js → disable-RRGOZIA7.js} +3 -3
- package/dist/chunks/{discard-WIN3BOXR.js → discard-X2NIGII5.js} +3 -3
- package/dist/chunks/{edit-IZQX4XAG.js → edit-QV3Y6IUT.js} +4 -4
- package/dist/chunks/{enable-RFODZ2L7.js → enable-UQAJJKCG.js} +3 -3
- package/dist/chunks/{export-5CCLXZYT.js → export-D4YNS2G5.js} +3 -3
- package/dist/chunks/{inspect-GEUUTDBY.js → inspect-FHB3H3NA.js} +4 -4
- package/dist/chunks/{list-H35AGNO2.js → list-6RAHTDT2.js} +3 -3
- package/dist/chunks/{list-JIYDXQDJ.js → list-QYUCZR26.js} +4 -4
- package/dist/chunks/{ls-WPNFJAS6.js → ls-GKWWEHQS.js} +5 -5
- package/dist/chunks/{publish-K7OPKXYC.js → publish-UTKKRA4P.js} +3 -3
- package/dist/chunks/{query-IIUJIRHR.js → query-NM7MXRFW.js} +3 -3
- package/dist/chunks/{reorder-GQ7BOQA7.js → reorder-ZLVQQBMG.js} +3 -3
- package/dist/chunks/{restore-MODYFJSP.js → restore-SDTDA4A6.js} +3 -3
- package/dist/chunks/{rm-A45OKS6U.js → rm-65PQY7XN.js} +5 -5
- package/dist/chunks/{rule-inspect-HJCERQHK.js → rule-inspect-JFKSPCDU.js} +5 -5
- package/dist/chunks/{rules-UNL3IB4P.js → rules-6672IXZE.js} +7 -7
- package/dist/chunks/{schema-EUH7PJEX.js → schema-DC2LLUHD.js} +3 -3
- package/dist/chunks/{update-MOM4T2RN.js → update-7VFELUTD.js} +5 -5
- package/dist/commands/build/index.js +10 -10
- package/dist/commands/deploy/index.js +11 -11
- package/dist/commands/dev/index.js +10 -10
- package/dist/commands/env/index.js +5 -5
- package/dist/commands/link/index.js +8 -8
- package/dist/commands/list/index.js +4 -4
- package/dist/commands-bulk.js +1536 -1116
- package/dist/index.js +9 -9
- package/dist/version.mjs +1 -1
- package/package.json +15 -15
|
@@ -9,8 +9,8 @@ import {
|
|
|
9
9
|
handleRulesApiError,
|
|
10
10
|
parseRulesFlagsAndScope,
|
|
11
11
|
rulesCollectionPath
|
|
12
|
-
} from "./chunk-
|
|
13
|
-
import "./chunk-
|
|
12
|
+
} from "./chunk-G4YL2LRL.js";
|
|
13
|
+
import "./chunk-IAOBSXJ5.js";
|
|
14
14
|
import "./chunk-D7MGZH35.js";
|
|
15
15
|
import {
|
|
16
16
|
validateJsonOutput
|
|
@@ -21,13 +21,13 @@ import {
|
|
|
21
21
|
import {
|
|
22
22
|
AGENT_REASON
|
|
23
23
|
} from "./chunk-QH7WYDEP.js";
|
|
24
|
-
import "./chunk-
|
|
25
|
-
import "./chunk-
|
|
24
|
+
import "./chunk-6V37RSQB.js";
|
|
25
|
+
import "./chunk-BHMMV3HE.js";
|
|
26
26
|
import "./chunk-Q77ALSXR.js";
|
|
27
27
|
import {
|
|
28
28
|
buildCommandWithGlobalFlags,
|
|
29
29
|
outputAgentError
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-X5UROEGN.js";
|
|
31
31
|
import "./chunk-N2T234LO.js";
|
|
32
32
|
import "./chunk-GGP5R3FU.js";
|
|
33
33
|
import {
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
getPreservedArgsForEnvPull,
|
|
15
15
|
outputActionRequired,
|
|
16
16
|
outputAgentError
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-X5UROEGN.js";
|
|
18
18
|
import {
|
|
19
19
|
require_end_of_stream,
|
|
20
20
|
require_lib as require_lib2,
|
|
@@ -21125,7 +21125,7 @@ var require_superstatic = __commonJS({
|
|
|
21125
21125
|
if (typeof r.destination === "string") {
|
|
21126
21126
|
route = { src, dest: interpolate(r.destination), check: true };
|
|
21127
21127
|
} else {
|
|
21128
|
-
const destination = { ...r.destination };
|
|
21128
|
+
const destination = { ...r.destination, type: "service" };
|
|
21129
21129
|
if (typeof destination.path === "string") {
|
|
21130
21130
|
destination.path = interpolate(destination.path);
|
|
21131
21131
|
}
|
|
@@ -21788,13 +21788,13 @@ var require_schemas = __commonJS({
|
|
|
21788
21788
|
pattern: "^[a-zA-Z]([a-zA-Z0-9_-]*[a-zA-Z0-9])?$"
|
|
21789
21789
|
};
|
|
21790
21790
|
var serviceDestinationSchema = {
|
|
21791
|
-
description: "A service-targeted destination that delegates routing into a named service from `services`.",
|
|
21791
|
+
description: "A service-targeted destination that delegates routing into a named service from `services`. Identified by the presence of `service`.",
|
|
21792
21792
|
type: "object",
|
|
21793
21793
|
additionalProperties: false,
|
|
21794
|
-
required: ["
|
|
21794
|
+
required: ["service"],
|
|
21795
21795
|
properties: {
|
|
21796
21796
|
type: {
|
|
21797
|
-
description: "
|
|
21797
|
+
description: "Optional explicit format marker. The destination shape is identified by the `service` property, so `type` is no longer required. When present it must be `service`.",
|
|
21798
21798
|
type: "string",
|
|
21799
21799
|
enum: ["service"]
|
|
21800
21800
|
},
|
|
@@ -22618,6 +22618,8 @@ var require_dist5 = __commonJS({
|
|
|
22618
22618
|
if (typeof route.destination === "string") {
|
|
22619
22619
|
route.dest = route.destination;
|
|
22620
22620
|
delete route.destination;
|
|
22621
|
+
} else if (typeof route.destination.service === "string") {
|
|
22622
|
+
route.destination = { ...route.destination, type: "service" };
|
|
22621
22623
|
}
|
|
22622
22624
|
}
|
|
22623
22625
|
if (route.statusCode !== void 0) {
|
|
@@ -29922,7 +29924,7 @@ var require_detect_builders = __commonJS({
|
|
|
29922
29924
|
}
|
|
29923
29925
|
}
|
|
29924
29926
|
}
|
|
29925
|
-
if (frontendBuilder && ((0, import_is_official_runtime.isOfficialRuntime)("express", frontendBuilder.use) || (0, import_is_official_runtime.isOfficialRuntime)("hono", frontendBuilder.use) || (0, import_is_official_runtime.isOfficialRuntime)("backends", frontendBuilder.use))) {
|
|
29927
|
+
if (frontendBuilder && ((0, import_is_official_runtime.isOfficialRuntime)("express", frontendBuilder.use) || (0, import_is_official_runtime.isOfficialRuntime)("hono", frontendBuilder.use) || (0, import_is_official_runtime.isOfficialRuntime)("python", frontendBuilder.use) || (0, import_is_official_runtime.isOfficialRuntime)("backends", frontendBuilder.use))) {
|
|
29926
29928
|
return null;
|
|
29927
29929
|
}
|
|
29928
29930
|
if (unusedFunctions.size) {
|
|
@@ -37310,9 +37312,17 @@ var require_hashes = __commonJS({
|
|
|
37310
37312
|
var import_crypto = __require("crypto");
|
|
37311
37313
|
var import_fs_extra9 = __toESM2(require_lib6());
|
|
37312
37314
|
var import_async_sema = require_lib7();
|
|
37315
|
+
var MAX_BUFFER_FILE_SIZE = 2 ** 31 - 1;
|
|
37313
37316
|
function hash(buf) {
|
|
37314
37317
|
return (0, import_crypto.createHash)("sha1").update(Uint8Array.from(buf)).digest("hex");
|
|
37315
37318
|
}
|
|
37319
|
+
async function hashFile(path) {
|
|
37320
|
+
const digest = (0, import_crypto.createHash)("sha1");
|
|
37321
|
+
for await (const chunk of import_fs_extra9.default.createReadStream(path)) {
|
|
37322
|
+
digest.update(Uint8Array.from(chunk));
|
|
37323
|
+
}
|
|
37324
|
+
return digest.digest("hex");
|
|
37325
|
+
}
|
|
37316
37326
|
var mapToObject = (map) => {
|
|
37317
37327
|
const obj = {};
|
|
37318
37328
|
for (const [key, value] of map) {
|
|
@@ -37330,16 +37340,23 @@ var require_hashes = __commonJS({
|
|
|
37330
37340
|
const stat2 = await import_fs_extra9.default.lstat(name);
|
|
37331
37341
|
const mode = stat2.mode;
|
|
37332
37342
|
let data;
|
|
37343
|
+
let size;
|
|
37333
37344
|
const isDirectory2 = stat2.isDirectory();
|
|
37334
37345
|
let h;
|
|
37335
37346
|
if (!isDirectory2) {
|
|
37336
37347
|
if (stat2.isSymbolicLink()) {
|
|
37337
37348
|
const link = await import_fs_extra9.default.readlink(name);
|
|
37338
37349
|
data = Buffer.from(link, "utf8");
|
|
37350
|
+
size = data.length;
|
|
37351
|
+
h = hash(data);
|
|
37352
|
+
} else if (stat2.size > MAX_BUFFER_FILE_SIZE) {
|
|
37353
|
+
size = stat2.size;
|
|
37354
|
+
h = await hashFile(name);
|
|
37339
37355
|
} else {
|
|
37340
37356
|
data = await import_fs_extra9.default.readFile(name);
|
|
37357
|
+
size = data.length;
|
|
37358
|
+
h = hash(data);
|
|
37341
37359
|
}
|
|
37342
|
-
h = hash(data);
|
|
37343
37360
|
}
|
|
37344
37361
|
const entry = map.get(h);
|
|
37345
37362
|
if (entry) {
|
|
@@ -37347,7 +37364,7 @@ var require_hashes = __commonJS({
|
|
|
37347
37364
|
names.add(name);
|
|
37348
37365
|
entry.names = [...names];
|
|
37349
37366
|
} else {
|
|
37350
|
-
map.set(h, { names: [name], data, mode });
|
|
37367
|
+
map.set(h, { names: [name], data, mode, size });
|
|
37351
37368
|
}
|
|
37352
37369
|
semaphore.release();
|
|
37353
37370
|
})
|
|
@@ -37780,7 +37797,7 @@ var require_package = __commonJS({
|
|
|
37780
37797
|
"../client/package.json"(exports, module) {
|
|
37781
37798
|
module.exports = {
|
|
37782
37799
|
name: "@vercel/client",
|
|
37783
|
-
version: "17.6.
|
|
37800
|
+
version: "17.6.2",
|
|
37784
37801
|
main: "dist/index.js",
|
|
37785
37802
|
typings: "dist/index.d.ts",
|
|
37786
37803
|
homepage: "https://vercel.com",
|
|
@@ -45998,7 +46015,7 @@ ${clearRelative(ignoreFile)}`);
|
|
|
45998
46015
|
}
|
|
45999
46016
|
preparedFiles.push({
|
|
46000
46017
|
file: isWin ? fileName.replace(/\\/g, "/") : fileName,
|
|
46001
|
-
size: file.data?.byteLength
|
|
46018
|
+
size: file.data?.byteLength ?? file.size,
|
|
46002
46019
|
mode: file.mode,
|
|
46003
46020
|
sha: sha || void 0
|
|
46004
46021
|
});
|
|
@@ -46787,6 +46804,7 @@ var require_upload = __commonJS({
|
|
|
46787
46804
|
module.exports = __toCommonJS2(upload_exports);
|
|
46788
46805
|
var import_http = __toESM2(__require("http"));
|
|
46789
46806
|
var import_https = __toESM2(__require("https"));
|
|
46807
|
+
var import_fs4 = __require("fs");
|
|
46790
46808
|
var import_stream = __require("stream");
|
|
46791
46809
|
var import_node_events = __require("events");
|
|
46792
46810
|
var import_async_retry = __toESM2(require_lib8());
|
|
@@ -46889,27 +46907,46 @@ var require_upload = __commonJS({
|
|
|
46889
46907
|
semaphore.release();
|
|
46890
46908
|
return bail(new Error("Upload aborted"));
|
|
46891
46909
|
}
|
|
46892
|
-
const { data } = file;
|
|
46893
|
-
if (typeof data === "undefined") {
|
|
46894
|
-
return;
|
|
46895
|
-
}
|
|
46910
|
+
const { data, size, names } = file;
|
|
46896
46911
|
uploadProgress.bytesUploaded = 0;
|
|
46897
|
-
|
|
46898
|
-
|
|
46899
|
-
|
|
46900
|
-
|
|
46901
|
-
|
|
46902
|
-
|
|
46903
|
-
|
|
46912
|
+
let body;
|
|
46913
|
+
let contentLength;
|
|
46914
|
+
if (typeof data !== "undefined") {
|
|
46915
|
+
contentLength = data.length;
|
|
46916
|
+
const buffered = new import_stream.Readable();
|
|
46917
|
+
const originalRead = buffered.read.bind(buffered);
|
|
46918
|
+
buffered.read = function(...args) {
|
|
46919
|
+
const chunk = originalRead(...args);
|
|
46920
|
+
if (chunk) {
|
|
46921
|
+
uploadProgress.bytesUploaded += chunk.length;
|
|
46922
|
+
uploadProgress.emit("progress");
|
|
46923
|
+
}
|
|
46924
|
+
return chunk;
|
|
46925
|
+
};
|
|
46926
|
+
const chunkSize = 16384;
|
|
46927
|
+
for (let i = 0; i < data.length; i += chunkSize) {
|
|
46928
|
+
const chunk = data.slice(i, i + chunkSize);
|
|
46929
|
+
buffered.push(chunk);
|
|
46904
46930
|
}
|
|
46905
|
-
|
|
46906
|
-
|
|
46907
|
-
|
|
46908
|
-
|
|
46909
|
-
const
|
|
46910
|
-
|
|
46931
|
+
buffered.push(null);
|
|
46932
|
+
body = buffered;
|
|
46933
|
+
} else if (typeof size === "number") {
|
|
46934
|
+
contentLength = size;
|
|
46935
|
+
const fileStream = (0, import_fs4.createReadStream)(names[0]);
|
|
46936
|
+
const counter = new import_stream.Transform({
|
|
46937
|
+
transform(chunk, _encoding, callback) {
|
|
46938
|
+
uploadProgress.bytesUploaded += chunk.length;
|
|
46939
|
+
uploadProgress.emit("progress");
|
|
46940
|
+
callback(null, chunk);
|
|
46941
|
+
}
|
|
46942
|
+
});
|
|
46943
|
+
fileStream.on("error", (err2) => counter.destroy(err2));
|
|
46944
|
+
counter.on("close", () => fileStream.destroy());
|
|
46945
|
+
body = fileStream.pipe(counter);
|
|
46946
|
+
} else {
|
|
46947
|
+
semaphore.release();
|
|
46948
|
+
return;
|
|
46911
46949
|
}
|
|
46912
|
-
body.push(null);
|
|
46913
46950
|
let err;
|
|
46914
46951
|
let result;
|
|
46915
46952
|
const abortController = new AbortController();
|
|
@@ -46923,9 +46960,9 @@ var require_upload = __commonJS({
|
|
|
46923
46960
|
method: "POST",
|
|
46924
46961
|
headers: {
|
|
46925
46962
|
"Content-Type": "application/octet-stream",
|
|
46926
|
-
"Content-Length":
|
|
46963
|
+
"Content-Length": contentLength,
|
|
46927
46964
|
"x-now-digest": sha,
|
|
46928
|
-
"x-now-size":
|
|
46965
|
+
"x-now-size": contentLength
|
|
46929
46966
|
},
|
|
46930
46967
|
body,
|
|
46931
46968
|
teamId: options.teamId,
|
|
@@ -10,10 +10,10 @@ import {
|
|
|
10
10
|
} from "./chunk-QH7WYDEP.js";
|
|
11
11
|
import {
|
|
12
12
|
getLocalPathConfig
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-2CYJVSAM.js";
|
|
14
14
|
import {
|
|
15
15
|
getScope
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-6V37RSQB.js";
|
|
17
17
|
import {
|
|
18
18
|
VERCEL_DIR_PROJECT,
|
|
19
19
|
VERCEL_DIR_README,
|
|
@@ -48,12 +48,12 @@ import {
|
|
|
48
48
|
selectAndParseRemoteUrl,
|
|
49
49
|
selectOrg,
|
|
50
50
|
writeServicesConfig
|
|
51
|
-
} from "./chunk-
|
|
51
|
+
} from "./chunk-BHMMV3HE.js";
|
|
52
52
|
import {
|
|
53
53
|
buildCommandWithGlobalFlags,
|
|
54
54
|
outputAgentError,
|
|
55
55
|
shouldEmitNonInteractiveCommandError
|
|
56
|
-
} from "./chunk-
|
|
56
|
+
} from "./chunk-X5UROEGN.js";
|
|
57
57
|
import {
|
|
58
58
|
table
|
|
59
59
|
} from "./chunk-LYCSVJIX.js";
|
|
@@ -6,7 +6,7 @@ const __filename = __fileURLToPath(import.meta.url);
|
|
|
6
6
|
const __dirname = __dirname_(__filename);
|
|
7
7
|
import {
|
|
8
8
|
resolveAlertsScope
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-IAOBSXJ5.js";
|
|
10
10
|
import {
|
|
11
11
|
handleValidationError,
|
|
12
12
|
outputError,
|
|
@@ -18,7 +18,7 @@ import {
|
|
|
18
18
|
import {
|
|
19
19
|
buildCommandWithGlobalFlags,
|
|
20
20
|
outputAgentError
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-X5UROEGN.js";
|
|
22
22
|
|
|
23
23
|
// src/commands/alerts/rules/parse-scope.ts
|
|
24
24
|
async function parseRulesFlagsAndScope(client, flags, jsonOutput) {
|
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
} from "./chunk-V5P25P7F.js";
|
|
10
10
|
import {
|
|
11
11
|
getLocalPathConfig
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-2CYJVSAM.js";
|
|
13
13
|
import {
|
|
14
14
|
DEFAULT_VERCEL_CONFIG_FILENAME,
|
|
15
15
|
VERCEL_CONFIG_EXTENSIONS,
|
|
@@ -36,7 +36,7 @@ import {
|
|
|
36
36
|
useKeypress,
|
|
37
37
|
usePrefix,
|
|
38
38
|
useState
|
|
39
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-BHMMV3HE.js";
|
|
40
40
|
import {
|
|
41
41
|
require_load_json_file
|
|
42
42
|
} from "./chunk-Q77ALSXR.js";
|
|
@@ -12,15 +12,15 @@ import {
|
|
|
12
12
|
} from "./chunk-QH7WYDEP.js";
|
|
13
13
|
import {
|
|
14
14
|
getScope
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-6V37RSQB.js";
|
|
16
16
|
import {
|
|
17
17
|
getLinkedProject,
|
|
18
18
|
getProjectByNameOrId
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-BHMMV3HE.js";
|
|
20
20
|
import {
|
|
21
21
|
buildCommandWithGlobalFlags,
|
|
22
22
|
outputAgentError
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-X5UROEGN.js";
|
|
24
24
|
import {
|
|
25
25
|
ProjectNotFound,
|
|
26
26
|
isAPIError
|
|
@@ -6,7 +6,7 @@ const __filename = __fileURLToPath(import.meta.url);
|
|
|
6
6
|
const __dirname = __dirname_(__filename);
|
|
7
7
|
import {
|
|
8
8
|
writeProjectSettings
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-4FG6Q2EM.js";
|
|
10
10
|
import {
|
|
11
11
|
autoInstallVercelPlugin
|
|
12
12
|
} from "./chunk-BRQ6PX3U.js";
|
|
@@ -15,10 +15,10 @@ import {
|
|
|
15
15
|
} from "./chunk-64IF634X.js";
|
|
16
16
|
import {
|
|
17
17
|
ensureLink
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-QMMMXYOY.js";
|
|
19
19
|
import {
|
|
20
20
|
pullCommand
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-ATBH7KGL.js";
|
|
22
22
|
import {
|
|
23
23
|
help
|
|
24
24
|
} from "./chunk-3NR6OYDV.js";
|
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
envPullCommandLogic,
|
|
29
29
|
humanizePath,
|
|
30
30
|
parseTarget
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-BHMMV3HE.js";
|
|
32
32
|
import {
|
|
33
33
|
TelemetryClient
|
|
34
34
|
} from "./chunk-Q77ALSXR.js";
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
progress,
|
|
11
11
|
require_dist as require_dist2,
|
|
12
12
|
sleep
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-HCJRHKSM.js";
|
|
14
14
|
import {
|
|
15
15
|
suggestNextCommands
|
|
16
16
|
} from "./chunk-LKBI43XK.js";
|
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
} from "./chunk-TCF6MGBY.js";
|
|
21
21
|
import {
|
|
22
22
|
CommandTimeout
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-UXP2N2WD.js";
|
|
24
24
|
import {
|
|
25
25
|
showPluginTipIfNeeded
|
|
26
26
|
} from "./chunk-BRQ6PX3U.js";
|
|
@@ -29,7 +29,7 @@ import {
|
|
|
29
29
|
} from "./chunk-64IF634X.js";
|
|
30
30
|
import {
|
|
31
31
|
getScope
|
|
32
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-6V37RSQB.js";
|
|
33
33
|
import {
|
|
34
34
|
getProjectByNameOrId,
|
|
35
35
|
param,
|
|
@@ -37,7 +37,7 @@ import {
|
|
|
37
37
|
require_dist as require_dist3,
|
|
38
38
|
require_pluralize,
|
|
39
39
|
ua_default
|
|
40
|
-
} from "./chunk-
|
|
40
|
+
} from "./chunk-BHMMV3HE.js";
|
|
41
41
|
import {
|
|
42
42
|
require_lib
|
|
43
43
|
} from "./chunk-N2T234LO.js";
|
|
@@ -2018,7 +2018,10 @@ async function processDeployment({
|
|
|
2018
2018
|
if (event.type === "file-count") {
|
|
2019
2019
|
const { total, missing, uploads } = event.payload;
|
|
2020
2020
|
output_manager_default.debug(`Total files ${total.size}, ${missing.length} changed`);
|
|
2021
|
-
const missingSize = missing.map((sha) =>
|
|
2021
|
+
const missingSize = missing.map((sha) => {
|
|
2022
|
+
const file = total.get(sha);
|
|
2023
|
+
return file?.data?.length ?? file?.size ?? 0;
|
|
2024
|
+
}).reduce((a, b) => a + b, 0);
|
|
2022
2025
|
const totalSizeHuman = import_bytes.default.format(missingSize, { decimalPlaces: 1 });
|
|
2023
2026
|
let nextStep = 0;
|
|
2024
2027
|
const stepSize = now._client.stderr.isTTY ? 0 : 0.25;
|
|
@@ -2050,9 +2053,10 @@ async function processDeployment({
|
|
|
2050
2053
|
updateProgress();
|
|
2051
2054
|
}
|
|
2052
2055
|
if (event.type === "file-uploaded") {
|
|
2056
|
+
const { file } = event.payload;
|
|
2053
2057
|
output_manager_default.debug(
|
|
2054
|
-
`Uploaded: ${
|
|
2055
|
-
|
|
2058
|
+
`Uploaded: ${file.names.join(" ")} (${(0, import_bytes.default)(
|
|
2059
|
+
file.data?.length ?? file.size ?? 0
|
|
2056
2060
|
)})`
|
|
2057
2061
|
);
|
|
2058
2062
|
}
|
|
@@ -2204,7 +2208,10 @@ function handleErrorSolvableWithArchive(error) {
|
|
|
2204
2208
|
if ((0, import_error_utils.isErrorLike)(error)) {
|
|
2205
2209
|
const isUploadRateLimit = "errorName" in error && typeof error.errorName === "string" && error.errorName.startsWith("api-upload-");
|
|
2206
2210
|
const isTooManyFilesLimit = "code" in error && error.code === "too_many_files";
|
|
2207
|
-
|
|
2211
|
+
const isEntityTooLarge = /entity too large|payload too large/i.test(
|
|
2212
|
+
error.message
|
|
2213
|
+
);
|
|
2214
|
+
if (isUploadRateLimit || isTooManyFilesLimit || isEntityTooLarge) {
|
|
2208
2215
|
return new UploadErrorMissingArchive(
|
|
2209
2216
|
`${error.message}
|
|
2210
2217
|
${archiveSuggestionText}`
|
|
@@ -2909,12 +2916,45 @@ async function createCertForCns(client, cns, context) {
|
|
|
2909
2916
|
}
|
|
2910
2917
|
}
|
|
2911
2918
|
|
|
2912
|
-
// src/util/domains/
|
|
2919
|
+
// src/util/domains/add-domain.ts
|
|
2913
2920
|
var import_chalk8 = __toESM(require_source(), 1);
|
|
2921
|
+
var import_async_retry4 = __toESM(require_dist2(), 1);
|
|
2922
|
+
async function addDomain(client, domain, contextName) {
|
|
2923
|
+
output_manager_default.spinner(`Adding domain ${domain} under ${import_chalk8.default.bold(contextName)}`);
|
|
2924
|
+
const addedDomain = await performAddRequest(client, domain);
|
|
2925
|
+
return addedDomain;
|
|
2926
|
+
}
|
|
2927
|
+
async function performAddRequest(client, domainName) {
|
|
2928
|
+
return (0, import_async_retry4.default)(
|
|
2929
|
+
async () => {
|
|
2930
|
+
try {
|
|
2931
|
+
const { domain } = await client.fetch("/v4/domains", {
|
|
2932
|
+
body: { name: domainName },
|
|
2933
|
+
method: "POST"
|
|
2934
|
+
});
|
|
2935
|
+
return domain;
|
|
2936
|
+
} catch (err) {
|
|
2937
|
+
if (isAPIError(err)) {
|
|
2938
|
+
if (err.code === "invalid_name") {
|
|
2939
|
+
return new InvalidDomain(domainName);
|
|
2940
|
+
}
|
|
2941
|
+
if (err.code === "domain_already_exists") {
|
|
2942
|
+
return new DomainAlreadyExists(domainName);
|
|
2943
|
+
}
|
|
2944
|
+
}
|
|
2945
|
+
throw err;
|
|
2946
|
+
}
|
|
2947
|
+
},
|
|
2948
|
+
{ retries: 5, maxTimeout: 8e3 }
|
|
2949
|
+
);
|
|
2950
|
+
}
|
|
2951
|
+
|
|
2952
|
+
// src/util/domains/get-domain-by-name.ts
|
|
2953
|
+
var import_chalk9 = __toESM(require_source(), 1);
|
|
2914
2954
|
async function getDomainByName(client, contextName, domainName, options = {}) {
|
|
2915
2955
|
if (!options.ignoreWait) {
|
|
2916
2956
|
output_manager_default.spinner(
|
|
2917
|
-
`Fetching domain ${domainName} under ${
|
|
2957
|
+
`Fetching domain ${domainName} under ${import_chalk9.default.bold(contextName)}`
|
|
2918
2958
|
);
|
|
2919
2959
|
}
|
|
2920
2960
|
try {
|
|
@@ -2944,39 +2984,6 @@ function isWildcardAlias(alias) {
|
|
|
2944
2984
|
// src/util/domains/setup-domain.ts
|
|
2945
2985
|
var import_tldts = __toESM(require_cjs(), 1);
|
|
2946
2986
|
|
|
2947
|
-
// src/util/domains/add-domain.ts
|
|
2948
|
-
var import_chalk9 = __toESM(require_source(), 1);
|
|
2949
|
-
var import_async_retry4 = __toESM(require_dist2(), 1);
|
|
2950
|
-
async function addDomain(client, domain, contextName) {
|
|
2951
|
-
output_manager_default.spinner(`Adding domain ${domain} under ${import_chalk9.default.bold(contextName)}`);
|
|
2952
|
-
const addedDomain = await performAddRequest(client, domain);
|
|
2953
|
-
return addedDomain;
|
|
2954
|
-
}
|
|
2955
|
-
async function performAddRequest(client, domainName) {
|
|
2956
|
-
return (0, import_async_retry4.default)(
|
|
2957
|
-
async () => {
|
|
2958
|
-
try {
|
|
2959
|
-
const { domain } = await client.fetch("/v4/domains", {
|
|
2960
|
-
body: { name: domainName },
|
|
2961
|
-
method: "POST"
|
|
2962
|
-
});
|
|
2963
|
-
return domain;
|
|
2964
|
-
} catch (err) {
|
|
2965
|
-
if (isAPIError(err)) {
|
|
2966
|
-
if (err.code === "invalid_name") {
|
|
2967
|
-
return new InvalidDomain(domainName);
|
|
2968
|
-
}
|
|
2969
|
-
if (err.code === "domain_already_exists") {
|
|
2970
|
-
return new DomainAlreadyExists(domainName);
|
|
2971
|
-
}
|
|
2972
|
-
}
|
|
2973
|
-
throw err;
|
|
2974
|
-
}
|
|
2975
|
-
},
|
|
2976
|
-
{ retries: 5, maxTimeout: 8e3 }
|
|
2977
|
-
);
|
|
2978
|
-
}
|
|
2979
|
-
|
|
2980
2987
|
// src/util/domains/maybe-get-domain-by-name.ts
|
|
2981
2988
|
async function maybeGetDomainByName(client, contextName, domainName) {
|
|
2982
2989
|
const maybeDomain = await getDomainByName(client, contextName, domainName);
|
|
@@ -3057,11 +3064,11 @@ export {
|
|
|
3057
3064
|
Now,
|
|
3058
3065
|
require_cjs,
|
|
3059
3066
|
createCertForCns,
|
|
3067
|
+
addDomain,
|
|
3060
3068
|
getDomainByName,
|
|
3061
3069
|
getDomainPrice,
|
|
3062
3070
|
getDomainStatus,
|
|
3063
3071
|
pollForOrder,
|
|
3064
|
-
getDomain,
|
|
3065
3072
|
purchaseDomain,
|
|
3066
3073
|
collectContactInformation,
|
|
3067
3074
|
purchaseDomainIfAvailable,
|
|
@@ -7,17 +7,17 @@ const __dirname = __dirname_(__filename);
|
|
|
7
7
|
import {
|
|
8
8
|
getUpdateCommandInfo,
|
|
9
9
|
isGlobal
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-SBYEIQ32.js";
|
|
11
11
|
import {
|
|
12
12
|
getGlobalPathConfig,
|
|
13
13
|
progress,
|
|
14
14
|
writeToConfigFile
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-HCJRHKSM.js";
|
|
16
16
|
import {
|
|
17
17
|
apiCommand,
|
|
18
18
|
listSubcommand2 as listSubcommand,
|
|
19
19
|
loginCommand
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-UXP2N2WD.js";
|
|
21
21
|
import {
|
|
22
22
|
require_semver
|
|
23
23
|
} from "./chunk-IB5L4LKZ.js";
|
|
@@ -26,7 +26,7 @@ import {
|
|
|
26
26
|
} from "./chunk-3NR6OYDV.js";
|
|
27
27
|
import {
|
|
28
28
|
login
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-BHMMV3HE.js";
|
|
30
30
|
import {
|
|
31
31
|
TelemetryClient,
|
|
32
32
|
isNativeBinaryInstall
|
|
@@ -10,11 +10,11 @@ import {
|
|
|
10
10
|
} from "./chunk-QH7WYDEP.js";
|
|
11
11
|
import {
|
|
12
12
|
getLinkedProject
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-BHMMV3HE.js";
|
|
14
14
|
import {
|
|
15
15
|
buildCommandWithYes,
|
|
16
16
|
outputAgentError
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-X5UROEGN.js";
|
|
18
18
|
import {
|
|
19
19
|
getFlagsSpecification,
|
|
20
20
|
getGlobalFlagsOnlyFromArgs,
|
|
@@ -7,16 +7,16 @@ const __dirname = __dirname_(__filename);
|
|
|
7
7
|
import {
|
|
8
8
|
printProjectNotFoundError,
|
|
9
9
|
setupAndLink
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-FMBDRMTZ.js";
|
|
11
11
|
import {
|
|
12
12
|
getLinkedProject,
|
|
13
13
|
param,
|
|
14
14
|
resolveProjectCwd
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-BHMMV3HE.js";
|
|
16
16
|
import {
|
|
17
17
|
buildCommandWithYes,
|
|
18
18
|
outputActionRequired
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-X5UROEGN.js";
|
|
20
20
|
import {
|
|
21
21
|
getCommandName,
|
|
22
22
|
getCommandNamePlain
|