Git - scaffold the git extension API (#305643)

* Git - scaffold the git extension API

* Pull request feedback
This commit is contained in:
Ladislau Szomoru
2026-03-27 13:56:36 +00:00
committed by GitHub
parent 0ed75f3304
commit bdea2b4df8
5 changed files with 46 additions and 1 deletions
+4
View File
@@ -158,6 +158,10 @@ export class ApiRepository implements Repository {
return this.#repository.clean(paths.map(p => Uri.file(p)));
}
restore(paths: string[], options?: { staged?: boolean; ref?: string }) {
return this.#repository.restore(paths.map(p => Uri.file(p)), options);
}
diff(cached?: boolean) {
return this.#repository.diff(cached);
}
+1
View File
@@ -259,6 +259,7 @@ export interface Repository {
add(paths: string[]): Promise<void>;
revert(paths: string[]): Promise<void>;
clean(paths: string[]): Promise<void>;
restore(paths: string[], options?: { staged?: boolean; ref?: string }): Promise<void>;
apply(patch: string, reverse?: boolean): Promise<void>;
apply(patch: string, options?: { allowEmpty?: boolean; reverse?: boolean; threeWay?: boolean; }): Promise<void>;