Versions 116 to 318
new file, 108 lines
3+
6+ "CREATE TABLE IF NOT EXISTS git_fs_meta (scope TEXT, path TEXT, bytes INTEGER, PRIMARY KEY(scope,path))",
9+ "CREATE TABLE IF NOT EXISTS git_fs_chunks (scope TEXT, path TEXT, part INTEGER, data BLOB NOT NULL, PRIMARY KEY(scope,path,part))",
11+ storage.sql.exec("CREATE TABLE IF NOT EXISTS git_fs_budget (scope TEXT PRIMARY KEY, bytes INTEGER NOT NULL)");
13+
14+/** One Git operation's scratch files. Reads materialize one file, never the whole filesystem. */
19+ for (const table of ["git_fs_chunks", "git_fs_meta", "git_fs_budget"]) storage.sql.exec(`DELETE FROM ${table}`);
50+ const rows = this.storage.sql.exec("SELECT bytes FROM git_fs_budget WHERE scope = ?", this.scope).toArray() as {
57+ this.storage.sql.exec("DELETE FROM git_fs_chunks WHERE scope = ? AND path = ?", this.scope, path);
66+ this.storage.sql.exec("INSERT OR REPLACE INTO git_fs_meta VALUES (?, ?, ?)", this.scope, path, bytes.byteLength);
78+ .exec("SELECT data FROM git_fs_chunks WHERE scope = ? AND path = ? AND part = ?", this.scope, path, at / 65536)
92+ this.storage.sql.exec("DELETE FROM git_fs_chunks WHERE scope = ? AND path = ?", this.scope, path);
93+ this.storage.sql.exec("DELETE FROM git_fs_meta WHERE scope = ? AND path = ?", this.scope, path);
94+ this.storage.sql.exec("UPDATE git_fs_budget SET bytes = bytes - ? WHERE scope = ?", size, this.scope);
- MCP
- compare on this site's /mcp
- CLI
- abso diff 116 318 server/src/git-file-contents.ts --json
- JSON
- /christopher/abso-core/compare/116..318?file=server%2Fsrc%2Fgit-file-contents.ts&format=json