feat(ext/sw): extend GitHost interface with putBlob/getBlob/deleteBlob
Adds the three blob ops to the interface and a BLOB_THRESHOLD_BYTES constant. Both GitHubHost and GiteaHost ship temporary stubs so the build stays green until tasks 3-4 fill in real implementations. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -105,4 +105,16 @@ export class GitHubHost implements GitHost {
|
||||
if (!Array.isArray(json)) return [];
|
||||
return json.map((item: { name: string }) => item.name);
|
||||
}
|
||||
|
||||
async putBlob(_path: string, _content: Uint8Array, _message: string): Promise<string> {
|
||||
throw new Error(`GitHubHost.putBlob not implemented — Task 3`);
|
||||
}
|
||||
|
||||
async getBlob(path: string): Promise<Uint8Array> {
|
||||
return this.readFile(path);
|
||||
}
|
||||
|
||||
async deleteBlob(path: string, message: string): Promise<void> {
|
||||
return this.deleteFile(path, message);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user