git-fs-s3 0.15.2 → 0.16.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.
- package/README.md +5 -3
- package/dist/fetch-s3.js +137 -160
- package/dist/fetch-s3.js.map +1 -1
- package/dist/http.js +905 -849
- package/dist/http.js.map +1 -1
- package/dist/index.js +624 -658
- package/dist/index.js.map +1 -1
- package/dist/memory-M2cCuVF-.js +61 -0
- package/dist/memory-M2cCuVF-.js.map +1 -0
- package/dist/node.js +75 -72
- package/dist/node.js.map +1 -1
- package/dist/object-size-BJAsnZzw.js +191 -0
- package/dist/object-size-BJAsnZzw.js.map +1 -0
- package/dist/ops.js +662 -692
- package/dist/ops.js.map +1 -1
- package/dist/refs-Cb_NfKWI.js +550 -0
- package/dist/refs-Cb_NfKWI.js.map +1 -0
- package/dist/s3.js +111 -116
- package/dist/s3.js.map +1 -1
- package/dist/semaphore-CPjn7Iqh.js +686 -0
- package/dist/semaphore-CPjn7Iqh.js.map +1 -0
- package/dist/types/cache.d.ts +9 -0
- package/dist/types/git-errors.d.ts +6 -0
- package/dist/types/http/repack.d.ts +7 -0
- package/dist/types/index.d.ts +1 -1
- package/dist/types/ops/history.d.ts +8 -0
- package/dist/types/ops/index.d.ts +1 -1
- package/package.json +8 -13
- package/dist/chunk-HLYCSNJ2.js +0 -53
- package/dist/chunk-HLYCSNJ2.js.map +0 -1
- package/dist/chunk-IAKZRWBZ.js +0 -598
- package/dist/chunk-IAKZRWBZ.js.map +0 -1
- package/dist/chunk-OKBQISUC.js +0 -442
- package/dist/chunk-OKBQISUC.js.map +0 -1
- package/dist/chunk-T5M5EYCZ.js +0 -143
- package/dist/chunk-T5M5EYCZ.js.map +0 -1
package/dist/chunk-T5M5EYCZ.js
DELETED
|
@@ -1,143 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
OBJ_OFS_DELTA,
|
|
3
|
-
OBJ_REF_DELTA,
|
|
4
|
-
OID_BYTES,
|
|
5
|
-
findPackIndexOffset,
|
|
6
|
-
inflatePrefix,
|
|
7
|
-
packFileName,
|
|
8
|
-
parsePackDirectory,
|
|
9
|
-
parsePackFileName,
|
|
10
|
-
rawFs,
|
|
11
|
-
readDeltaHeader,
|
|
12
|
-
readEntryHeader,
|
|
13
|
-
readOfsDeltaOffset
|
|
14
|
-
} from "./chunk-OKBQISUC.js";
|
|
15
|
-
|
|
16
|
-
// src/git-layout.ts
|
|
17
|
-
var HEX = new Set("0123456789abcdef");
|
|
18
|
-
function isHex(value, length) {
|
|
19
|
-
if (value.length !== length) return false;
|
|
20
|
-
for (const char of value) if (!HEX.has(char)) return false;
|
|
21
|
-
return true;
|
|
22
|
-
}
|
|
23
|
-
function classifyGitdirPath(path) {
|
|
24
|
-
const segments = path.split("/");
|
|
25
|
-
const [first, second, third, ...rest] = segments;
|
|
26
|
-
if (segments.length === 1) {
|
|
27
|
-
if (first === "HEAD") return { kind: "head" };
|
|
28
|
-
if (first === "config") return { kind: "config" };
|
|
29
|
-
if (first === "refs") return { kind: "refs", path };
|
|
30
|
-
return { kind: "other" };
|
|
31
|
-
}
|
|
32
|
-
if (first === "refs") return { kind: "refs", path };
|
|
33
|
-
if (first !== "objects" || second === void 0) return { kind: "other" };
|
|
34
|
-
if (segments.length === 2 && second === "") return { kind: "objects-dir" };
|
|
35
|
-
if (second === "pack" && third !== void 0 && rest.length === 0) {
|
|
36
|
-
if (third === "") return { kind: "pack-dir" };
|
|
37
|
-
const file = parsePackFileName(third);
|
|
38
|
-
return file ? { kind: "pack-file", file } : { kind: "other" };
|
|
39
|
-
}
|
|
40
|
-
if (third !== void 0 && rest.length === 0 && isHex(second, 2) && isHex(third, 38)) {
|
|
41
|
-
return { kind: "loose-object", oid: second + third };
|
|
42
|
-
}
|
|
43
|
-
return { kind: "other" };
|
|
44
|
-
}
|
|
45
|
-
function isMutableGitdirEntry(entry) {
|
|
46
|
-
switch (entry.kind) {
|
|
47
|
-
case "head":
|
|
48
|
-
case "refs":
|
|
49
|
-
case "objects-dir":
|
|
50
|
-
case "pack-dir":
|
|
51
|
-
return true;
|
|
52
|
-
default:
|
|
53
|
-
return false;
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
function parseLooseObjectPath(path) {
|
|
57
|
-
const segments = path.split("/");
|
|
58
|
-
if (segments.length < 3) return null;
|
|
59
|
-
const gitdirSegments = segments.slice(0, -3);
|
|
60
|
-
const entry = classifyGitdirPath(segments.slice(-3).join("/"));
|
|
61
|
-
if (entry.kind !== "loose-object") return null;
|
|
62
|
-
return { gitdir: gitdirSegments.join("/"), oid: entry.oid };
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
// src/object-size.ts
|
|
66
|
-
var ENTRY_PROBE_BYTES = 64;
|
|
67
|
-
var DELTA_PROBE_BYTES = 4 * 1024;
|
|
68
|
-
var DELTA_HEADER_MAX_BYTES = 20;
|
|
69
|
-
async function locatePackedObject(repo, oid) {
|
|
70
|
-
const fsp = rawFs(repo);
|
|
71
|
-
const packDir = `${repo.gitdir}/objects/pack`;
|
|
72
|
-
const indexes = parsePackDirectory(
|
|
73
|
-
await fsp.readdir(packDir).catch(() => [])
|
|
74
|
-
).filter((file) => file.kind === "idx");
|
|
75
|
-
for (const { base } of indexes) {
|
|
76
|
-
const idx = await fsp.readFile(`${packDir}/${packFileName(base, "idx")}`);
|
|
77
|
-
if (!(idx instanceof Uint8Array)) continue;
|
|
78
|
-
const offset = findPackIndexOffset(idx, oid);
|
|
79
|
-
if (offset !== null) {
|
|
80
|
-
return { packName: packFileName(base, "pack"), offset };
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
return null;
|
|
84
|
-
}
|
|
85
|
-
function rangeReader(repo) {
|
|
86
|
-
const promises = rawFs(repo);
|
|
87
|
-
if (!promises.getRange) return null;
|
|
88
|
-
return (key, start, end) => {
|
|
89
|
-
if (!promises.getRange) return Promise.resolve(null);
|
|
90
|
-
return promises.getRange(key, start, end);
|
|
91
|
-
};
|
|
92
|
-
}
|
|
93
|
-
async function deltaResultSize(read, packKey, dataStart) {
|
|
94
|
-
const compressed = await read(
|
|
95
|
-
packKey,
|
|
96
|
-
dataStart,
|
|
97
|
-
dataStart + DELTA_PROBE_BYTES - 1
|
|
98
|
-
);
|
|
99
|
-
if (!compressed || compressed.byteLength === 0) return null;
|
|
100
|
-
const inflated = await inflatePrefix(
|
|
101
|
-
new Uint8Array(compressed),
|
|
102
|
-
DELTA_HEADER_MAX_BYTES
|
|
103
|
-
);
|
|
104
|
-
if (!inflated) return null;
|
|
105
|
-
const header = readDeltaHeader(inflated, 0);
|
|
106
|
-
return header.length <= inflated.byteLength ? header.resultSize : null;
|
|
107
|
-
}
|
|
108
|
-
async function getObjectSize(repo, oid) {
|
|
109
|
-
const read = rangeReader(repo);
|
|
110
|
-
if (!read) return null;
|
|
111
|
-
const located = await locatePackedObject(repo, oid);
|
|
112
|
-
if (!located) return null;
|
|
113
|
-
const packKey = `${repo.gitdir}/objects/pack/${located.packName}`;
|
|
114
|
-
const probe = await read(
|
|
115
|
-
packKey,
|
|
116
|
-
located.offset,
|
|
117
|
-
located.offset + ENTRY_PROBE_BYTES - 1
|
|
118
|
-
);
|
|
119
|
-
if (!probe || probe.byteLength === 0) return null;
|
|
120
|
-
const header = readEntryHeader(probe, 0);
|
|
121
|
-
if (header.length > probe.byteLength) return null;
|
|
122
|
-
if (header.type !== OBJ_OFS_DELTA && header.type !== OBJ_REF_DELTA) {
|
|
123
|
-
return header.size;
|
|
124
|
-
}
|
|
125
|
-
const bodyStart = located.offset + header.length;
|
|
126
|
-
let dataStart;
|
|
127
|
-
if (header.type === OBJ_REF_DELTA) {
|
|
128
|
-
dataStart = bodyStart + OID_BYTES;
|
|
129
|
-
} else {
|
|
130
|
-
const base = readOfsDeltaOffset(probe, header.length);
|
|
131
|
-
if (header.length + base.length > probe.byteLength) return null;
|
|
132
|
-
dataStart = bodyStart + base.length;
|
|
133
|
-
}
|
|
134
|
-
return deltaResultSize(read, packKey, dataStart);
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
export {
|
|
138
|
-
classifyGitdirPath,
|
|
139
|
-
isMutableGitdirEntry,
|
|
140
|
-
parseLooseObjectPath,
|
|
141
|
-
getObjectSize
|
|
142
|
-
};
|
|
143
|
-
//# sourceMappingURL=chunk-T5M5EYCZ.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/git-layout.ts","../src/object-size.ts"],"sourcesContent":["/**\n * Typed classification of paths inside a git directory, so callers can\n * reason about \"a ref\", \"a loose object\" or \"the pack listing\" as values\n * instead of matching path strings against patterns.\n *\n * Edge-compatible: no node: imports.\n */\n\nimport { type PackFileName, parsePackFileName } from \"./pack-files.js\";\n\n/** What a gitdir-relative path refers to. Listing prefixes end in `/`. */\nexport type GitdirEntry =\n\t| { readonly kind: \"head\" }\n\t| { readonly kind: \"config\" }\n\t/** A ref file (`refs/heads/main`) or a refs listing (`refs/heads/`). */\n\t| { readonly kind: \"refs\"; readonly path: string }\n\t/** The `objects/` listing. */\n\t| { readonly kind: \"objects-dir\" }\n\t/** The `objects/pack/` listing. */\n\t| { readonly kind: \"pack-dir\" }\n\t| { readonly kind: \"pack-file\"; readonly file: PackFileName }\n\t| { readonly kind: \"loose-object\"; readonly oid: string }\n\t| { readonly kind: \"other\" };\n\nconst HEX = new Set(\"0123456789abcdef\");\n\nfunction isHex(value: string, length: number): boolean {\n\tif (value.length !== length) return false;\n\tfor (const char of value) if (!HEX.has(char)) return false;\n\treturn true;\n}\n\n/** Classify a path relative to a gitdir (no leading slash). */\nexport function classifyGitdirPath(path: string): GitdirEntry {\n\tconst segments = path.split(\"/\");\n\tconst [first, second, third, ...rest] = segments;\n\tif (segments.length === 1) {\n\t\tif (first === \"HEAD\") return { kind: \"head\" };\n\t\tif (first === \"config\") return { kind: \"config\" };\n\t\tif (first === \"refs\") return { kind: \"refs\", path };\n\t\treturn { kind: \"other\" };\n\t}\n\tif (first === \"refs\") return { kind: \"refs\", path };\n\tif (first !== \"objects\" || second === undefined) return { kind: \"other\" };\n\tif (segments.length === 2 && second === \"\") return { kind: \"objects-dir\" };\n\tif (second === \"pack\" && third !== undefined && rest.length === 0) {\n\t\tif (third === \"\") return { kind: \"pack-dir\" };\n\t\tconst file = parsePackFileName(third);\n\t\treturn file ? { kind: \"pack-file\", file } : { kind: \"other\" };\n\t}\n\tif (\n\t\tthird !== undefined &&\n\t\trest.length === 0 &&\n\t\tisHex(second, 2) &&\n\t\tisHex(third, 38)\n\t) {\n\t\treturn { kind: \"loose-object\", oid: second + third };\n\t}\n\treturn { kind: \"other\" };\n}\n\n/**\n * Whether reads of this entry can change between pushes: refs, `HEAD`, and\n * the object/pack listings. Everything else is content-addressed (objects)\n * or written once (config, a given pack file name).\n */\nexport function isMutableGitdirEntry(entry: GitdirEntry): boolean {\n\tswitch (entry.kind) {\n\t\tcase \"head\":\n\t\tcase \"refs\":\n\t\tcase \"objects-dir\":\n\t\tcase \"pack-dir\":\n\t\t\treturn true;\n\t\tdefault:\n\t\t\treturn false;\n\t}\n}\n\n/**\n * A loose-object path anywhere in the fs, split into its gitdir and oid —\n * for callers that don't know where the gitdir boundary is: a loose object\n * is always `<gitdir>/objects/<2 hex>/<38 hex>`.\n */\nexport function parseLooseObjectPath(\n\tpath: string,\n): { readonly gitdir: string; readonly oid: string } | null {\n\tconst segments = path.split(\"/\");\n\tif (segments.length < 3) return null;\n\tconst gitdirSegments = segments.slice(0, -3);\n\tconst entry = classifyGitdirPath(segments.slice(-3).join(\"/\"));\n\tif (entry.kind !== \"loose-object\") return null;\n\treturn { gitdir: gitdirSegments.join(\"/\"), oid: entry.oid };\n}\n","/**\n * An object's size without reading (or inflating) the object.\n *\n * Why this exists: a git object's length lives in its pack entry, but the only\n * way isomorphic-git will hand you an object's bytes is by inflating the whole\n * thing — so \"is this blob too large to render or diff\" could only be asked\n * *after* loading it, which is exactly the cost a size limit is meant to avoid.\n * A 500 MB blob committed to a public repository would be materialised in\n * memory by a single page view before any limit could reject it.\n *\n * Reading the answer is cheap but not trivial, because git stores an object two\n * ways:\n *\n * - **whole** — the entry header records the size, so a small range read at the\n * entry's offset answers it;\n * - **as a delta** — the entry header records the size of the *delta stream*,\n * and the reconstructed size is the second varint inside the delta data, which\n * is itself deflated. Only a bounded prefix of that stream is needed, so\n * {@link inflatePrefix} recovers it without inflating the object.\n *\n * Either way the answer is exact, which matters because it decides whether a\n * caller may load the object at all. The cost is one `.idx` read (served from\n * the fs cache after the first) plus one or two small range reads of the pack,\n * so a caller can ask about a hundred objects without fetching a pack.\n *\n * `null` means \"not a packed object whose size could be read\" — a loose object,\n * a genuinely absent one, an unreadable index, a store without range reads, or\n * a delta prefix too short to yield its header. A caller must then read the\n * object rather than treating `null` as \"too large\"; see the call sites.\n */\nimport { inflatePrefix } from \"./edge-utils.js\";\nimport { rawFs } from \"./http/types.js\";\nimport type { Repo } from \"./ops/types.js\";\nimport {\n\tOBJ_OFS_DELTA,\n\tOBJ_REF_DELTA,\n\tOID_BYTES,\n\treadDeltaHeader,\n\treadEntryHeader,\n\treadOfsDeltaOffset,\n} from \"./pack-entry.js\";\nimport { packFileName, parsePackDirectory } from \"./pack-files.js\";\nimport { findPackIndexOffset } from \"./pack-index.js\";\n\n/**\n * Bytes fetched at an entry's offset. The entry header itself is at most 10\n * bytes for a 64-bit length, a `REF_DELTA`'s base id is 20, and an `OFS_DELTA`'s\n * base offset at most 10 — 40 bytes, so 64 answers the layout without a second\n * request.\n */\nconst ENTRY_PROBE_BYTES = 64;\n\n/**\n * Compressed bytes fetched from a delta's data. A delta header is two varints\n * (at most 10 bytes each) whose compressed form is smaller still, so this is\n * generous by orders of magnitude while staying a bounded read.\n */\nconst DELTA_PROBE_BYTES = 4 * 1024;\n\n/** The most a delta header can occupy once inflated: two 10-byte varints. */\nconst DELTA_HEADER_MAX_BYTES = 20;\n\n/** The pack holding `oid`, with the offset of its entry. */\nasync function locatePackedObject(\n\trepo: Repo,\n\toid: string,\n): Promise<{ packName: string; offset: number } | null> {\n\tconst fsp = rawFs(repo);\n\tconst packDir = `${repo.gitdir}/objects/pack`;\n\tconst indexes = parsePackDirectory(\n\t\tawait fsp.readdir(packDir).catch(() => [] as string[]),\n\t).filter((file) => file.kind === \"idx\");\n\n\tfor (const { base } of indexes) {\n\t\tconst idx = await fsp.readFile(`${packDir}/${packFileName(base, \"idx\")}`);\n\t\tif (!(idx instanceof Uint8Array)) continue;\n\t\tconst offset = findPackIndexOffset(idx, oid);\n\t\tif (offset !== null) {\n\t\t\treturn { packName: packFileName(base, \"pack\"), offset };\n\t\t}\n\t}\n\treturn null;\n}\n\n/** The store's range reader, or `null` when it has none. */\nfunction rangeReader(repo: Repo) {\n\tconst promises = rawFs(repo) as {\n\t\tgetRange?: (\n\t\t\tkey: string,\n\t\t\tstart: number,\n\t\t\tend: number,\n\t\t) => Promise<Uint8Array | null>;\n\t};\n\tif (!promises.getRange) return null;\n\treturn (key: string, start: number, end: number) => {\n\t\tif (!promises.getRange) return Promise.resolve(null);\n\t\treturn promises.getRange(key, start, end);\n\t};\n}\n\n/**\n * A delta entry's reconstructed size, read from the header its deflated data\n * opens with. `null` when the bounded prefix doesn't yield a complete header.\n */\nasync function deltaResultSize(\n\tread: NonNullable<ReturnType<typeof rangeReader>>,\n\tpackKey: string,\n\tdataStart: number,\n): Promise<number | null> {\n\tconst compressed = await read(\n\t\tpackKey,\n\t\tdataStart,\n\t\tdataStart + DELTA_PROBE_BYTES - 1,\n\t);\n\tif (!compressed || compressed.byteLength === 0) return null;\n\n\tconst inflated = await inflatePrefix(\n\t\tnew Uint8Array(compressed),\n\t\tDELTA_HEADER_MAX_BYTES,\n\t);\n\tif (!inflated) return null;\n\n\tconst header = readDeltaHeader(inflated, 0);\n\treturn header.length <= inflated.byteLength ? header.resultSize : null;\n}\n\n/**\n * `oid`'s size in bytes, or `null` when it isn't a packed object this can read\n * (see the module comment for what that means to a caller).\n */\nexport async function getObjectSize(\n\trepo: Repo,\n\toid: string,\n): Promise<number | null> {\n\t// Without range reads the pack would have to be fetched whole, which is the\n\t// cost this exists to avoid — so report \"unknown\" and let the caller read.\n\tconst read = rangeReader(repo);\n\tif (!read) return null;\n\n\tconst located = await locatePackedObject(repo, oid);\n\tif (!located) return null;\n\n\tconst packKey = `${repo.gitdir}/objects/pack/${located.packName}`;\n\tconst probe = await read(\n\t\tpackKey,\n\t\tlocated.offset,\n\t\tlocated.offset + ENTRY_PROBE_BYTES - 1,\n\t);\n\tif (!probe || probe.byteLength === 0) return null;\n\n\tconst header = readEntryHeader(probe, 0);\n\t// A header that ran off the end of the probe is a header this read, not one\n\t// it can interpret.\n\tif (header.length > probe.byteLength) return null;\n\tif (header.type !== OBJ_OFS_DELTA && header.type !== OBJ_REF_DELTA) {\n\t\treturn header.size;\n\t}\n\n\t// The base reference sits between the entry header and the deflated delta\n\t// data: 20 bytes of oid for `REF_DELTA`, or a backwards offset for\n\t// `OFS_DELTA`.\n\tconst bodyStart = located.offset + header.length;\n\tlet dataStart: number;\n\tif (header.type === OBJ_REF_DELTA) {\n\t\tdataStart = bodyStart + OID_BYTES;\n\t} else {\n\t\tconst base = readOfsDeltaOffset(probe, header.length);\n\t\tif (header.length + base.length > probe.byteLength) return null;\n\t\tdataStart = bodyStart + base.length;\n\t}\n\treturn deltaResultSize(read, packKey, dataStart);\n}\n"],"mappings":";;;;;;;;;;;;;;;;AAwBA,IAAM,MAAM,IAAI,IAAI,kBAAkB;AAEtC,SAAS,MAAM,OAAe,QAAyB;AACtD,MAAI,MAAM,WAAW,OAAQ,QAAO;AACpC,aAAW,QAAQ,MAAO,KAAI,CAAC,IAAI,IAAI,IAAI,EAAG,QAAO;AACrD,SAAO;AACR;AAGO,SAAS,mBAAmB,MAA2B;AAC7D,QAAM,WAAW,KAAK,MAAM,GAAG;AAC/B,QAAM,CAAC,OAAO,QAAQ,OAAO,GAAG,IAAI,IAAI;AACxC,MAAI,SAAS,WAAW,GAAG;AAC1B,QAAI,UAAU,OAAQ,QAAO,EAAE,MAAM,OA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