@gitkraken/core-gitlens 0.55.0 → 0.56.1
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/CHANGELOG.md +20 -1
- package/dist/git/cache.js +3 -0
- package/dist/git/cache.js.map +1 -1
- package/dist/git-cli/providers/pausedOperations.d.ts +2 -0
- package/dist/git-cli/providers/pausedOperations.js +104 -40
- package/dist/git-cli/providers/pausedOperations.js.map +1 -1
- package/dist/plus/integrations/index.d.ts +2 -1
- package/dist/plus/integrations/index.js.map +1 -1
- package/dist/plus/integrations/integrationService.d.ts +9 -0
- package/dist/plus/integrations/integrationService.js +75 -3
- package/dist/plus/integrations/integrationService.js.map +1 -1
- package/dist/plus/integrations/manager.d.ts +10 -0
- package/dist/plus/integrations/models/bitbucketPullRequestWrites.d.ts +217 -0
- package/dist/plus/integrations/models/bitbucketPullRequestWrites.js +0 -0
- package/dist/plus/integrations/models/integration.d.ts +2 -1
- package/dist/plus/integrations/models/integration.js +6 -0
- package/dist/plus/integrations/models/integration.js.map +1 -1
- package/dist/plus/integrations/models/publicIntegration.d.ts +0 -1
- package/dist/plus/integrations/providers/azure/writeIdentity.d.ts +0 -3
- package/dist/plus/integrations/providers/azure/writeIdentity.js +4 -12
- package/dist/plus/integrations/providers/azure/writeIdentity.js.map +1 -1
- package/dist/plus/integrations/providers/azureDevOps.d.ts +0 -2
- package/dist/plus/integrations/providers/azureDevOps.js +1 -7
- package/dist/plus/integrations/providers/azureDevOps.js.map +1 -1
- package/dist/plus/integrations/providers/azurePullRequestWrites.js +24 -26
- package/dist/plus/integrations/providers/azurePullRequestWrites.js.map +1 -1
- package/dist/plus/integrations/providers/azureWorkItemWriteErrors.js +4 -3
- package/dist/plus/integrations/providers/azureWorkItemWriteErrors.js.map +1 -1
- package/dist/plus/integrations/providers/azureWorkItemWrites.js +22 -21
- package/dist/plus/integrations/providers/azureWorkItemWrites.js.map +1 -1
- package/dist/plus/integrations/providers/bitbucket.d.ts +4 -0
- package/dist/plus/integrations/providers/bitbucket.js +8 -0
- package/dist/plus/integrations/providers/bitbucket.js.map +1 -1
- package/dist/plus/integrations/providers/bitbucketPullRequestWriteErrors.d.ts +13 -0
- package/dist/plus/integrations/providers/bitbucketPullRequestWriteErrors.js +88 -0
- package/dist/plus/integrations/providers/bitbucketPullRequestWriteErrors.js.map +1 -0
- package/dist/plus/integrations/providers/bitbucketPullRequestWriteLedger.d.ts +14 -0
- package/dist/plus/integrations/providers/bitbucketPullRequestWriteLedger.js +36 -0
- package/dist/plus/integrations/providers/bitbucketPullRequestWriteLedger.js.map +1 -0
- package/dist/plus/integrations/providers/bitbucketPullRequestWrites.d.ts +47 -0
- package/dist/plus/integrations/providers/bitbucketPullRequestWrites.js +796 -0
- package/dist/plus/integrations/providers/bitbucketPullRequestWrites.js.map +1 -0
- package/dist/plus/integrations/providers/issueSorts.d.ts +0 -1
- package/dist/plus/integrations/providers/providersApi.d.ts +4 -0
- package/dist/plus/integrations/providers/providersApi.js +5 -0
- package/dist/plus/integrations/providers/providersApi.js.map +1 -1
- package/dist/plus/integrations/providers/utils/writeInputs.d.ts +7 -0
- package/dist/plus/integrations/providers/utils/writeInputs.js +17 -0
- package/dist/plus/integrations/providers/utils/writeInputs.js.map +1 -0
- package/dist/plus/integrations/reads/drains.d.ts +0 -1
- package/docs/integrations.md +155 -0
- package/package.json +1 -1
|
@@ -24,7 +24,9 @@ export declare class PausedOperationsGitSubProvider implements GitPausedOperatio
|
|
|
24
24
|
getPausedOperationStatus(repoPath: string, options?: {
|
|
25
25
|
force?: boolean;
|
|
26
26
|
}, cancellation?: AbortSignal): Promise<GitPausedOperationStatus | undefined>;
|
|
27
|
+
private readonly _fingerprints;
|
|
27
28
|
private readPausedOperationStatus;
|
|
29
|
+
private readFingerprint;
|
|
28
30
|
/** Memoized per repo by sha — forced status re-reads on FS noise (every file save while resolving
|
|
29
31
|
* conflicts) would otherwise re-spawn `git log` for an unchanging commit. */
|
|
30
32
|
private readonly _commitMessageCache;
|
|
@@ -22,6 +22,38 @@ const orderedOperations = [
|
|
|
22
22
|
"revert",
|
|
23
23
|
"sequencer"
|
|
24
24
|
];
|
|
25
|
+
const rebaseStepFiles = {
|
|
26
|
+
"rebase-apply": {
|
|
27
|
+
number: "next",
|
|
28
|
+
total: "last"
|
|
29
|
+
},
|
|
30
|
+
"rebase-merge": {
|
|
31
|
+
number: "msgnum",
|
|
32
|
+
total: "end"
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
const fingerprintFiles = {
|
|
36
|
+
"cherry-pick": [["CHERRY_PICK_HEAD"]],
|
|
37
|
+
merge: [["MERGE_HEAD"]],
|
|
38
|
+
revert: [["REVERT_HEAD"]],
|
|
39
|
+
"rebase-apply": [
|
|
40
|
+
["REBASE_HEAD"],
|
|
41
|
+
["rebase-apply", "next"],
|
|
42
|
+
["rebase-apply", "last"],
|
|
43
|
+
["rebase-apply", "onto"],
|
|
44
|
+
["rebase-apply", "head-name"],
|
|
45
|
+
["rebase-apply", "orig-head"]
|
|
46
|
+
],
|
|
47
|
+
"rebase-merge": [
|
|
48
|
+
["REBASE_HEAD"],
|
|
49
|
+
["rebase-merge", "msgnum"],
|
|
50
|
+
["rebase-merge", "end"],
|
|
51
|
+
["rebase-merge", "onto"],
|
|
52
|
+
["rebase-merge", "head-name"],
|
|
53
|
+
["rebase-merge", "orig-head"]
|
|
54
|
+
],
|
|
55
|
+
sequencer: []
|
|
56
|
+
};
|
|
25
57
|
var PausedOperationsGitSubProvider = class {
|
|
26
58
|
context;
|
|
27
59
|
git;
|
|
@@ -90,17 +122,25 @@ var PausedOperationsGitSubProvider = class {
|
|
|
90
122
|
const validation = options?.force ? void 0 : this.cache.validateBeforeRead(repoPath);
|
|
91
123
|
return validation != null ? validation.then(() => this.readPausedOperationStatus(repoPath, options, scope, cancellation)) : this.readPausedOperationStatus(repoPath, options, scope, cancellation);
|
|
92
124
|
}
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
125
|
+
_fingerprints = /* @__PURE__ */ new WeakMap();
|
|
126
|
+
async readPausedOperationStatus(repoPath, options, scope, cancellation) {
|
|
127
|
+
const map = this.cache.pausedOperationStatus;
|
|
128
|
+
let gitDir;
|
|
129
|
+
let operations;
|
|
130
|
+
try {
|
|
131
|
+
gitDir = await this.provider.config.getGitDir(repoPath);
|
|
132
|
+
operations = await this.scanGitDir(gitDir);
|
|
133
|
+
} catch {
|
|
134
|
+
map.delete(repoPath);
|
|
135
|
+
return;
|
|
136
|
+
}
|
|
137
|
+
if (!operations.size) {
|
|
138
|
+
map.delete(repoPath);
|
|
139
|
+
return;
|
|
140
|
+
}
|
|
141
|
+
const fingerprint = await this.readFingerprint(gitDir, operations);
|
|
142
|
+
if (cancellation?.aborted) throw new CancellationError();
|
|
143
|
+
const read = async (cacheable, signal) => {
|
|
104
144
|
const sortedOperations = [...operations].sort((a, b) => orderedOperations.indexOf(a) - orderedOperations.indexOf(b));
|
|
105
145
|
scope?.info(`Detected paused operations: ${sortedOperations.join(", ")}`);
|
|
106
146
|
const operation = sortedOperations[0];
|
|
@@ -108,21 +148,22 @@ var PausedOperationsGitSubProvider = class {
|
|
|
108
148
|
case "cherry-pick": {
|
|
109
149
|
const result = await this.git.run({
|
|
110
150
|
cwd: repoPath,
|
|
111
|
-
cancellation,
|
|
151
|
+
cancellation: signal,
|
|
112
152
|
errors: "ignore"
|
|
113
153
|
}, "rev-parse", "--quiet", "--verify", "CHERRY_PICK_HEAD");
|
|
114
|
-
if (result.completion.status === "cancelled" ||
|
|
154
|
+
if (result.completion.status === "cancelled" || signal?.aborted) throw new CancellationError();
|
|
115
155
|
const cherryPickHead = result.stdout.trim();
|
|
116
156
|
if (!cherryPickHead) {
|
|
117
157
|
scope?.addExitInfo("No CHERRY_PICK_HEAD found");
|
|
158
|
+
cacheable.invalidate();
|
|
118
159
|
return;
|
|
119
160
|
}
|
|
120
161
|
const [branchResult, mergeBaseResult, messageResult] = await Promise.allSettled([
|
|
121
|
-
this.provider.branches.getCurrentBranchReference(repoPath,
|
|
122
|
-
this.provider.refs.getMergeBase(repoPath, "CHERRY_PICK_HEAD", "HEAD", void 0,
|
|
123
|
-
this.getCommitMessage(repoPath, cherryPickHead,
|
|
162
|
+
this.provider.branches.getCurrentBranchReference(repoPath, signal),
|
|
163
|
+
this.provider.refs.getMergeBase(repoPath, "CHERRY_PICK_HEAD", "HEAD", void 0, signal),
|
|
164
|
+
this.getCommitMessage(repoPath, cherryPickHead, signal)
|
|
124
165
|
]);
|
|
125
|
-
if (
|
|
166
|
+
if (signal?.aborted) throw new CancellationError();
|
|
126
167
|
const current = getSettledValue(branchResult);
|
|
127
168
|
const mergeBase = getSettledValue(mergeBaseResult);
|
|
128
169
|
const message = getSettledValue(messageResult);
|
|
@@ -144,24 +185,25 @@ var PausedOperationsGitSubProvider = class {
|
|
|
144
185
|
case "merge": {
|
|
145
186
|
const result = await this.git.run({
|
|
146
187
|
cwd: repoPath,
|
|
147
|
-
cancellation,
|
|
188
|
+
cancellation: signal,
|
|
148
189
|
errors: "ignore"
|
|
149
190
|
}, "rev-parse", "--quiet", "--verify", "MERGE_HEAD");
|
|
150
|
-
if (result.completion.status === "cancelled" ||
|
|
191
|
+
if (result.completion.status === "cancelled" || signal?.aborted) throw new CancellationError();
|
|
151
192
|
const mergeHead = result.stdout.trim();
|
|
152
193
|
if (!mergeHead) {
|
|
153
194
|
scope?.addExitInfo("No MERGE_HEAD found");
|
|
195
|
+
cacheable.invalidate();
|
|
154
196
|
return;
|
|
155
197
|
}
|
|
156
198
|
const [branchResult, mergeBaseResult, possibleSourceBranchesResult] = await Promise.allSettled([
|
|
157
|
-
this.provider.branches.getCurrentBranchReference(repoPath,
|
|
158
|
-
this.provider.refs.getMergeBase(repoPath, "MERGE_HEAD", "HEAD", void 0,
|
|
199
|
+
this.provider.branches.getCurrentBranchReference(repoPath, signal),
|
|
200
|
+
this.provider.refs.getMergeBase(repoPath, "MERGE_HEAD", "HEAD", void 0, signal),
|
|
159
201
|
this.provider.branches.getBranchesWithCommits(repoPath, ["MERGE_HEAD"], void 0, {
|
|
160
202
|
all: true,
|
|
161
203
|
mode: "pointsAt"
|
|
162
|
-
},
|
|
204
|
+
}, signal)
|
|
163
205
|
]);
|
|
164
|
-
if (
|
|
206
|
+
if (signal?.aborted) throw new CancellationError();
|
|
165
207
|
const current = getSettledValue(branchResult);
|
|
166
208
|
const mergeBase = getSettledValue(mergeBaseResult);
|
|
167
209
|
const possibleSourceBranches = getSettledValue(possibleSourceBranchesResult);
|
|
@@ -181,21 +223,22 @@ var PausedOperationsGitSubProvider = class {
|
|
|
181
223
|
case "revert": {
|
|
182
224
|
const result = await this.git.run({
|
|
183
225
|
cwd: repoPath,
|
|
184
|
-
cancellation,
|
|
226
|
+
cancellation: signal,
|
|
185
227
|
errors: "ignore"
|
|
186
228
|
}, "rev-parse", "--quiet", "--verify", "REVERT_HEAD");
|
|
187
|
-
if (result.completion.status === "cancelled" ||
|
|
229
|
+
if (result.completion.status === "cancelled" || signal?.aborted) throw new CancellationError();
|
|
188
230
|
const revertHead = result.stdout.trim();
|
|
189
231
|
if (!revertHead) {
|
|
190
232
|
scope?.addExitInfo("No REVERT_HEAD found");
|
|
233
|
+
cacheable.invalidate();
|
|
191
234
|
return;
|
|
192
235
|
}
|
|
193
236
|
const [branchResult, mergeBaseResult, messageResult] = await Promise.allSettled([
|
|
194
|
-
this.provider.branches.getCurrentBranchReference(repoPath,
|
|
195
|
-
this.provider.refs.getMergeBase(repoPath, "REVERT_HEAD", "HEAD", void 0,
|
|
196
|
-
this.getCommitMessage(repoPath, revertHead,
|
|
237
|
+
this.provider.branches.getCurrentBranchReference(repoPath, signal),
|
|
238
|
+
this.provider.refs.getMergeBase(repoPath, "REVERT_HEAD", "HEAD", void 0, signal),
|
|
239
|
+
this.getCommitMessage(repoPath, revertHead, signal)
|
|
197
240
|
]);
|
|
198
|
-
if (
|
|
241
|
+
if (signal?.aborted) throw new CancellationError();
|
|
199
242
|
const current = getSettledValue(branchResult);
|
|
200
243
|
const mergeBase = getSettledValue(mergeBaseResult);
|
|
201
244
|
const message = getSettledValue(messageResult);
|
|
@@ -219,39 +262,41 @@ var PausedOperationsGitSubProvider = class {
|
|
|
219
262
|
let branch = await this.readDotGitFile(gitDir, [operation, "head-name"]);
|
|
220
263
|
if (!branch) {
|
|
221
264
|
scope?.addExitInfo(`No '${operation}/head-name' found`);
|
|
265
|
+
cacheable.invalidate();
|
|
222
266
|
return;
|
|
223
267
|
}
|
|
224
268
|
const [rebaseHeadResult, origHeadResult, ontoResult, stepsNumberResult, stepsTotalResult, stepsMessageResult, isInteractiveResult] = await Promise.allSettled([
|
|
225
269
|
this.git.run({
|
|
226
270
|
cwd: repoPath,
|
|
227
|
-
cancellation,
|
|
271
|
+
cancellation: signal,
|
|
228
272
|
errors: "ignore"
|
|
229
273
|
}, "rev-parse", "--quiet", "--verify", "REBASE_HEAD"),
|
|
230
274
|
this.readDotGitFile(gitDir, [operation, "orig-head"]),
|
|
231
275
|
this.readDotGitFile(gitDir, [operation, "onto"]),
|
|
232
|
-
this.readDotGitFile(gitDir, [operation,
|
|
233
|
-
this.readDotGitFile(gitDir, [operation,
|
|
276
|
+
this.readDotGitFile(gitDir, [operation, rebaseStepFiles[operation].number], { numeric: true }),
|
|
277
|
+
this.readDotGitFile(gitDir, [operation, rebaseStepFiles[operation].total], { numeric: true }),
|
|
234
278
|
this.readDotGitFile(gitDir, [operation, "message"], { throw: true }).catch(() => this.readDotGitFile(gitDir, [operation, "message-squashed"])),
|
|
235
279
|
stat(joinPaths(gitDir.uri.fsPath, operation, "interactive")).then(() => true, () => false)
|
|
236
280
|
]);
|
|
237
|
-
if (
|
|
281
|
+
if (signal?.aborted) throw new CancellationError();
|
|
238
282
|
const origHead = getSettledValue(origHeadResult);
|
|
239
283
|
const onto = getSettledValue(ontoResult);
|
|
240
284
|
if (origHead == null || onto == null) {
|
|
241
285
|
scope?.addExitInfo(`Neither '${operation}/orig-head' nor '${operation}/onto' found`);
|
|
286
|
+
cacheable.invalidate();
|
|
242
287
|
return;
|
|
243
288
|
}
|
|
244
289
|
const rebaseHead = getSettledValue(rebaseHeadResult)?.stdout.trim();
|
|
245
290
|
if (branch.startsWith("refs/heads/")) branch = branch.substring(11).trim();
|
|
246
291
|
const [mergeBaseResult, branchTipsResult, tagTipsResult] = await Promise.allSettled([
|
|
247
|
-
rebaseHead ? this.provider.refs.getMergeBase(repoPath, rebaseHead, "HEAD", void 0,
|
|
292
|
+
rebaseHead ? this.provider.refs.getMergeBase(repoPath, rebaseHead, "HEAD", void 0, signal) : this.provider.refs.getMergeBase(repoPath, onto, origHead, void 0, signal),
|
|
248
293
|
this.provider.branches.getBranchesWithCommits(repoPath, [onto], void 0, {
|
|
249
294
|
all: true,
|
|
250
295
|
mode: "pointsAt"
|
|
251
|
-
},
|
|
252
|
-
this.provider.tags.getTagsWithCommit(repoPath, onto, { mode: "pointsAt" },
|
|
296
|
+
}, signal),
|
|
297
|
+
this.provider.tags.getTagsWithCommit(repoPath, onto, { mode: "pointsAt" }, signal)
|
|
253
298
|
]);
|
|
254
|
-
if (
|
|
299
|
+
if (signal?.aborted) throw new CancellationError();
|
|
255
300
|
const mergeBase = getSettledValue(mergeBaseResult);
|
|
256
301
|
const branchTips = getSettledValue(branchTipsResult);
|
|
257
302
|
const tagTips = getSettledValue(tagTipsResult);
|
|
@@ -306,28 +351,32 @@ var PausedOperationsGitSubProvider = class {
|
|
|
306
351
|
const todoContent = await this.readDotGitFile(gitDir, ["sequencer", "todo"]);
|
|
307
352
|
if (!todoContent) {
|
|
308
353
|
scope?.addExitInfo("No sequencer/todo file found");
|
|
354
|
+
cacheable.invalidate();
|
|
309
355
|
return;
|
|
310
356
|
}
|
|
311
357
|
const firstLine = todoContent.split("\n")[0]?.trim();
|
|
312
358
|
if (!firstLine) {
|
|
313
359
|
scope?.addExitInfo("Empty sequencer/todo file");
|
|
360
|
+
cacheable.invalidate();
|
|
314
361
|
return;
|
|
315
362
|
}
|
|
316
363
|
const isCherryPick = /^p(?:ick)?\s/.test(firstLine);
|
|
317
364
|
const isRevert = /^revert\s/.test(firstLine);
|
|
318
365
|
if (!isCherryPick && !isRevert) {
|
|
319
366
|
scope?.addExitInfo(`Unknown sequencer command: ${firstLine}`);
|
|
367
|
+
cacheable.invalidate();
|
|
320
368
|
return;
|
|
321
369
|
}
|
|
322
370
|
const match = firstLine.match(todoCommitRegex);
|
|
323
371
|
const currentCommitSha = match?.[1];
|
|
324
372
|
if (!currentCommitSha) {
|
|
325
373
|
scope?.addExitInfo("Could not parse commit sha from sequencer/todo");
|
|
374
|
+
cacheable.invalidate();
|
|
326
375
|
return;
|
|
327
376
|
}
|
|
328
377
|
const message = match?.[2]?.trim() || void 0;
|
|
329
|
-
const [branchResult, mergeBaseResult] = await Promise.allSettled([this.provider.branches.getCurrentBranchReference(repoPath,
|
|
330
|
-
if (
|
|
378
|
+
const [branchResult, mergeBaseResult] = await Promise.allSettled([this.provider.branches.getCurrentBranchReference(repoPath, signal), this.provider.refs.getMergeBase(repoPath, currentCommitSha, "HEAD", void 0, signal)]);
|
|
379
|
+
if (signal?.aborted) throw new CancellationError();
|
|
331
380
|
const current = getSettledValue(branchResult);
|
|
332
381
|
const mergeBase = getSettledValue(mergeBaseResult);
|
|
333
382
|
if (isCherryPick) return {
|
|
@@ -360,7 +409,22 @@ var PausedOperationsGitSubProvider = class {
|
|
|
360
409
|
};
|
|
361
410
|
}
|
|
362
411
|
}
|
|
363
|
-
}
|
|
412
|
+
};
|
|
413
|
+
const cached = map.get(repoPath);
|
|
414
|
+
if (cached != null && (options?.force || this._fingerprints.get(cached) !== fingerprint)) map.delete(repoPath);
|
|
415
|
+
const status = map.getOrCreate(repoPath, read, cancellation);
|
|
416
|
+
const entry = map.get(repoPath);
|
|
417
|
+
if (entry != null && !this._fingerprints.has(entry)) this._fingerprints.set(entry, fingerprint);
|
|
418
|
+
return status;
|
|
419
|
+
}
|
|
420
|
+
async readFingerprint(gitDir, operations) {
|
|
421
|
+
const sortedOperations = [...operations].sort();
|
|
422
|
+
const [todo, ...files] = await Promise.all([operations.has("sequencer") ? this.readDotGitFile(gitDir, ["sequencer", "todo"]) : void 0, ...sortedOperations.flatMap((operation) => fingerprintFiles[operation].map((pathParts) => this.readDotGitFile(gitDir, pathParts)))]);
|
|
423
|
+
return [
|
|
424
|
+
sortedOperations.join(","),
|
|
425
|
+
todo?.split("\n", 1)[0]?.trim() ?? "",
|
|
426
|
+
...files.map((contents) => contents ?? "")
|
|
427
|
+
].join("\0");
|
|
364
428
|
}
|
|
365
429
|
/** Memoized per repo by sha — forced status re-reads on FS noise (every file save while resolving
|
|
366
430
|
* conflicts) would otherwise re-spawn `git log` for an unchanging commit. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pausedOperations.js","names":[],"sources":["../../../../git-cli/src/providers/pausedOperations.ts"],"sourcesContent":["import { readdir } from 'fs';\nimport { readFile, stat } from 'fs/promises';\nimport * as l10n from '@vscode/l10n';\nimport type { Cache } from '@gitlens/git/cache.js';\nimport type { GitServiceContext } from '@gitlens/git/context.js';\nimport { PausedOperationAbortError, PausedOperationContinueError } from '@gitlens/git/errors.js';\nimport type {\n\tGitCherryPickStatus,\n\tGitMergeStatus,\n\tGitPausedOperationStatus,\n\tGitRebaseStatus,\n\tGitRevertStatus,\n} from '@gitlens/git/models/pausedOperationStatus.js';\nimport type { GitBranchReference, GitTagReference } from '@gitlens/git/models/reference.js';\nimport type { GitDir } from '@gitlens/git/models/repository.js';\nimport type { GitPausedOperationsSubProvider } from '@gitlens/git/providers/pausedOperations.js';\nimport { createReference } from '@gitlens/git/utils/reference.utils.js';\nimport { CancellationError } from '@gitlens/utils/cancellation.js';\nimport { gate } from '@gitlens/utils/decorators/gate.js';\nimport { debug } from '@gitlens/utils/decorators/log.js';\nimport type { ScopedLogger } from '@gitlens/utils/logger.scoped.js';\nimport { getScopedLogger } from '@gitlens/utils/logger.scoped.js';\nimport { joinPaths } from '@gitlens/utils/path.js';\nimport { getSettledValue } from '@gitlens/utils/promise.js';\nimport type { CliGitProviderInternal } from '../cliGitProvider.js';\nimport type { Git } from '../exec/git.js';\nimport { getGitCommandError } from '../exec/git.js';\nimport type { IndexRefresher } from '../exec/indexRefresh.js';\nimport { refreshIndexAfter } from '../exec/indexRefresh.js';\n\nconst todoCommitRegex = /^(?:p(?:ick)?|revert)\\s+([a-f0-9]+)(?:\\s+(.+))?$/i;\n\ntype Operation = 'cherry-pick' | 'merge' | 'rebase-apply' | 'rebase-merge' | 'revert' | 'sequencer';\n\n// Note: 'sequencer' is checked after specific HEAD files since those take precedence\n// The sequencer directory is used for multi-commit cherry-picks/reverts\nconst orderedOperations: Operation[] = ['rebase-apply', 'rebase-merge', 'merge', 'cherry-pick', 'revert', 'sequencer'];\n\nexport class PausedOperationsGitSubProvider implements GitPausedOperationsSubProvider {\n\tconstructor(\n\t\tprivate readonly context: GitServiceContext,\n\t\tprivate readonly git: Git,\n\t\tprivate readonly cache: Cache,\n\t\tprivate readonly provider: CliGitProviderInternal,\n\t\tprivate readonly indexRefresher?: IndexRefresher,\n\t) {}\n\n\t/**\n\t * Whether git's dir holds a sentinel of an in-progress operation (presence only — no content is parsed,\n\t * so it also answers `true` for states `getPausedOperationStatus` can't describe, e.g. a stopped `git am`).\n\t * Rejects when git's dir can't be resolved or read\n\t */\n\t@debug({ quiet: true })\n\tasync hasPausedOperation(repoPath: string, cancellation?: AbortSignal): Promise<boolean> {\n\t\tconst gitDir = await this.provider.config.getGitDir(repoPath);\n\t\tconst operations = await this.scanGitDir(gitDir);\n\t\tif (cancellation?.aborted) throw new CancellationError();\n\n\t\tfor (const operation of operations) {\n\t\t\t// A bare leftover `sequencer` dir isn't in progress; git itself checks for `sequencer/todo`\n\t\t\tif (operation !== 'sequencer') return true;\n\t\t}\n\t\tif (!operations.has('sequencer')) return false;\n\n\t\ttry {\n\t\t\tawait stat(joinPaths(gitDir.uri.fsPath, 'sequencer', 'todo'));\n\t\t\treturn true;\n\t\t} catch (ex) {\n\t\t\tif ((ex as NodeJS.ErrnoException).code === 'ENOENT') return false;\n\t\t\tthrow ex;\n\t\t}\n\t}\n\n\t/** Lists the operation sentinels in git's dir; rejects if the dir can't be read */\n\tprivate scanGitDir(gitDir: GitDir): Promise<Set<Operation>> {\n\t\treturn new Promise<Set<Operation>>((resolve, reject) => {\n\t\t\treaddir(gitDir.uri.fsPath, { withFileTypes: true }, (err, entries) => {\n\t\t\t\tif (err != null) {\n\t\t\t\t\treject(err);\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tconst operations = new Set<Operation>();\n\t\t\t\tfor (const entry of entries) {\n\t\t\t\t\tif (entry.isFile()) {\n\t\t\t\t\t\tswitch (entry.name) {\n\t\t\t\t\t\t\tcase 'CHERRY_PICK_HEAD':\n\t\t\t\t\t\t\t\toperations.add('cherry-pick');\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'MERGE_HEAD':\n\t\t\t\t\t\t\t\toperations.add('merge');\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'REVERT_HEAD':\n\t\t\t\t\t\t\t\toperations.add('revert');\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t} else if (entry.isDirectory()) {\n\t\t\t\t\t\tswitch (entry.name) {\n\t\t\t\t\t\t\tcase 'rebase-apply':\n\t\t\t\t\t\t\t\toperations.add('rebase-apply');\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'rebase-merge':\n\t\t\t\t\t\t\t\toperations.add('rebase-merge');\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'sequencer':\n\t\t\t\t\t\t\t\t// The sequencer directory is used for multi-commit cherry-picks/reverts\n\t\t\t\t\t\t\t\t// We'll determine the type by reading the todo file later\n\t\t\t\t\t\t\t\toperations.add('sequencer');\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tresolve(operations);\n\t\t\t});\n\t\t});\n\t}\n\n\t@debug({ quiet: true })\n\tgetPausedOperationStatus(\n\t\trepoPath: string,\n\t\toptions?: { force?: boolean },\n\t\tcancellation?: AbortSignal,\n\t): Promise<GitPausedOperationStatus | undefined> {\n\t\tconst scope = getScopedLogger();\n\n\t\t// A forced read drops the cached status and reads it again anyway, so it has nothing to wait for\n\t\tconst validation = options?.force ? undefined : this.cache.validateBeforeRead(repoPath);\n\t\treturn validation != null\n\t\t\t? validation.then(() => this.readPausedOperationStatus(repoPath, options, scope, cancellation))\n\t\t\t: this.readPausedOperationStatus(repoPath, options, scope, cancellation);\n\t}\n\n\tprivate readPausedOperationStatus(\n\t\trepoPath: string,\n\t\toptions: { force?: boolean } | undefined,\n\t\tscope: ScopedLogger | undefined,\n\t\tcancellation: AbortSignal | undefined,\n\t): Promise<GitPausedOperationStatus | undefined> {\n\t\t// Self-heal callers (WIP refresh) bypass the cache so a missed `'pausedOp'` FS-watcher\n\t\t// event (CLI-driven completion, torn-down secondary-worktree watcher) can't leave the\n\t\t// status stuck — the readdir-based detection is cheap enough to repeat on every tick.\n\t\tif (options?.force) {\n\t\t\tthis.cache.pausedOperationStatus.delete(repoPath);\n\t\t}\n\n\t\tconst status = this.cache.pausedOperationStatus.getOrCreate(repoPath, async cacheable => {\n\t\t\t// An unresolved or unreadable git dir reads as \"nothing paused\" here — the status is best-effort and self-heals.\n\t\t\t// Neither is kept, since this cache has no expiry and a paused operation would read as none until cleared\n\t\t\tconst gitDir = await this.provider.config.getGitDir(repoPath).catch(() => undefined);\n\t\t\tconst operations = gitDir != null ? await this.scanGitDir(gitDir).catch(() => undefined) : undefined;\n\t\t\tif (gitDir == null || operations == null) {\n\t\t\t\tcacheable.invalidate();\n\t\t\t\treturn undefined;\n\t\t\t}\n\n\t\t\tif (!operations.size) return undefined;\n\t\t\tif (cancellation?.aborted) throw new CancellationError();\n\n\t\t\tconst sortedOperations = [...operations].sort(\n\t\t\t\t(a, b) => orderedOperations.indexOf(a) - orderedOperations.indexOf(b),\n\t\t\t);\n\t\t\tscope?.info(`Detected paused operations: ${sortedOperations.join(', ')}`);\n\n\t\t\tconst operation = sortedOperations[0];\n\t\t\tswitch (operation) {\n\t\t\t\tcase 'cherry-pick': {\n\t\t\t\t\tconst result = await this.git.run(\n\t\t\t\t\t\t{ cwd: repoPath, cancellation: cancellation, errors: 'ignore' },\n\t\t\t\t\t\t'rev-parse',\n\t\t\t\t\t\t'--quiet',\n\t\t\t\t\t\t'--verify',\n\t\t\t\t\t\t'CHERRY_PICK_HEAD',\n\t\t\t\t\t);\n\t\t\t\t\tif (result.completion.status === 'cancelled' || cancellation?.aborted) {\n\t\t\t\t\t\tthrow new CancellationError();\n\t\t\t\t\t}\n\n\t\t\t\t\tconst cherryPickHead = result.stdout.trim();\n\t\t\t\t\tif (!cherryPickHead) {\n\t\t\t\t\t\tscope?.addExitInfo('No CHERRY_PICK_HEAD found');\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\tconst [branchResult, mergeBaseResult, messageResult] = await Promise.allSettled([\n\t\t\t\t\t\tthis.provider.branches.getCurrentBranchReference(repoPath, cancellation),\n\t\t\t\t\t\tthis.provider.refs.getMergeBase(repoPath, 'CHERRY_PICK_HEAD', 'HEAD', undefined, cancellation),\n\t\t\t\t\t\tthis.getCommitMessage(repoPath, cherryPickHead, cancellation),\n\t\t\t\t\t]);\n\t\t\t\t\tif (cancellation?.aborted) throw new CancellationError();\n\n\t\t\t\t\tconst current = getSettledValue(branchResult)!;\n\t\t\t\t\tconst mergeBase = getSettledValue(mergeBaseResult);\n\t\t\t\t\t// Names the commit being applied, so consumers can say which one a skip would drop\n\t\t\t\t\tconst message = getSettledValue(messageResult);\n\n\t\t\t\t\treturn {\n\t\t\t\t\t\ttype: 'cherry-pick',\n\t\t\t\t\t\trepoPath: repoPath,\n\t\t\t\t\t\tmergeBase: mergeBase,\n\t\t\t\t\t\tHEAD: createReference(cherryPickHead, repoPath, { refType: 'revision', message: message }),\n\t\t\t\t\t\tcurrent: current,\n\t\t\t\t\t\tincoming: createReference(cherryPickHead, repoPath, { refType: 'revision', message: message }),\n\t\t\t\t\t} satisfies GitCherryPickStatus;\n\t\t\t\t}\n\t\t\t\tcase 'merge': {\n\t\t\t\t\tconst result = await this.git.run(\n\t\t\t\t\t\t{ cwd: repoPath, cancellation: cancellation, errors: 'ignore' },\n\t\t\t\t\t\t'rev-parse',\n\t\t\t\t\t\t'--quiet',\n\t\t\t\t\t\t'--verify',\n\t\t\t\t\t\t'MERGE_HEAD',\n\t\t\t\t\t);\n\t\t\t\t\tif (result.completion.status === 'cancelled' || cancellation?.aborted) {\n\t\t\t\t\t\tthrow new CancellationError();\n\t\t\t\t\t}\n\n\t\t\t\t\tconst mergeHead = result.stdout.trim();\n\t\t\t\t\tif (!mergeHead) {\n\t\t\t\t\t\tscope?.addExitInfo('No MERGE_HEAD found');\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\tconst [branchResult, mergeBaseResult, possibleSourceBranchesResult] = await Promise.allSettled([\n\t\t\t\t\t\tthis.provider.branches.getCurrentBranchReference(repoPath, cancellation),\n\t\t\t\t\t\tthis.provider.refs.getMergeBase(repoPath, 'MERGE_HEAD', 'HEAD', undefined, cancellation),\n\t\t\t\t\t\tthis.provider.branches.getBranchesWithCommits(\n\t\t\t\t\t\t\trepoPath,\n\t\t\t\t\t\t\t['MERGE_HEAD'],\n\t\t\t\t\t\t\tundefined,\n\t\t\t\t\t\t\t{ all: true, mode: 'pointsAt' },\n\t\t\t\t\t\t\tcancellation,\n\t\t\t\t\t\t),\n\t\t\t\t\t]);\n\n\t\t\t\t\tif (cancellation?.aborted) throw new CancellationError();\n\n\t\t\t\t\tconst current = getSettledValue(branchResult)!;\n\t\t\t\t\tconst mergeBase = getSettledValue(mergeBaseResult);\n\t\t\t\t\tconst possibleSourceBranches = getSettledValue(possibleSourceBranchesResult);\n\n\t\t\t\t\treturn {\n\t\t\t\t\t\ttype: 'merge',\n\t\t\t\t\t\trepoPath: repoPath,\n\t\t\t\t\t\tmergeBase: mergeBase,\n\t\t\t\t\t\tHEAD: createReference(mergeHead, repoPath, { refType: 'revision' }),\n\t\t\t\t\t\tcurrent: current,\n\t\t\t\t\t\tincoming:\n\t\t\t\t\t\t\tpossibleSourceBranches?.length === 1\n\t\t\t\t\t\t\t\t? createReference(possibleSourceBranches[0], repoPath, {\n\t\t\t\t\t\t\t\t\t\trefType: 'branch',\n\t\t\t\t\t\t\t\t\t\tname: possibleSourceBranches[0],\n\t\t\t\t\t\t\t\t\t\tremote: false,\n\t\t\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t\t: createReference(mergeHead, repoPath, { refType: 'revision' }),\n\t\t\t\t\t} satisfies GitMergeStatus;\n\t\t\t\t}\n\t\t\t\tcase 'revert': {\n\t\t\t\t\tconst result = await this.git.run(\n\t\t\t\t\t\t{ cwd: repoPath, cancellation: cancellation, errors: 'ignore' },\n\t\t\t\t\t\t'rev-parse',\n\t\t\t\t\t\t'--quiet',\n\t\t\t\t\t\t'--verify',\n\t\t\t\t\t\t'REVERT_HEAD',\n\t\t\t\t\t);\n\t\t\t\t\tif (result.completion.status === 'cancelled' || cancellation?.aborted) {\n\t\t\t\t\t\tthrow new CancellationError();\n\t\t\t\t\t}\n\n\t\t\t\t\tconst revertHead = result.stdout.trim();\n\t\t\t\t\tif (!revertHead) {\n\t\t\t\t\t\tscope?.addExitInfo('No REVERT_HEAD found');\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\tconst [branchResult, mergeBaseResult, messageResult] = await Promise.allSettled([\n\t\t\t\t\t\tthis.provider.branches.getCurrentBranchReference(repoPath, cancellation),\n\t\t\t\t\t\tthis.provider.refs.getMergeBase(repoPath, 'REVERT_HEAD', 'HEAD', undefined, cancellation),\n\t\t\t\t\t\tthis.getCommitMessage(repoPath, revertHead, cancellation),\n\t\t\t\t\t]);\n\t\t\t\t\tif (cancellation?.aborted) throw new CancellationError();\n\n\t\t\t\t\tconst current = getSettledValue(branchResult)!;\n\t\t\t\t\tconst mergeBase = getSettledValue(mergeBaseResult);\n\t\t\t\t\t// Names the commit being reverted, so consumers can say which one a skip would drop\n\t\t\t\t\tconst message = getSettledValue(messageResult);\n\n\t\t\t\t\treturn {\n\t\t\t\t\t\ttype: 'revert',\n\t\t\t\t\t\trepoPath: repoPath,\n\t\t\t\t\t\tmergeBase: mergeBase,\n\t\t\t\t\t\tHEAD: createReference(revertHead, repoPath, { refType: 'revision', message: message }),\n\t\t\t\t\t\tcurrent: current,\n\t\t\t\t\t\tincoming: createReference(revertHead, repoPath, { refType: 'revision', message: message }),\n\t\t\t\t\t} satisfies GitRevertStatus;\n\t\t\t\t}\n\t\t\t\tcase 'rebase-apply':\n\t\t\t\tcase 'rebase-merge': {\n\t\t\t\t\tlet branch = await this.readDotGitFile(gitDir, [operation, 'head-name']);\n\t\t\t\t\tif (!branch) {\n\t\t\t\t\t\tscope?.addExitInfo(`No '${operation}/head-name' found`);\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\tconst [\n\t\t\t\t\t\trebaseHeadResult,\n\t\t\t\t\t\torigHeadResult,\n\t\t\t\t\t\tontoResult,\n\t\t\t\t\t\tstepsNumberResult,\n\t\t\t\t\t\tstepsTotalResult,\n\t\t\t\t\t\tstepsMessageResult,\n\t\t\t\t\t\tisInteractiveResult,\n\t\t\t\t\t] = await Promise.allSettled([\n\t\t\t\t\t\tthis.git.run(\n\t\t\t\t\t\t\t{ cwd: repoPath, cancellation: cancellation, errors: 'ignore' },\n\t\t\t\t\t\t\t'rev-parse',\n\t\t\t\t\t\t\t'--quiet',\n\t\t\t\t\t\t\t'--verify',\n\t\t\t\t\t\t\t'REBASE_HEAD',\n\t\t\t\t\t\t),\n\t\t\t\t\t\tthis.readDotGitFile(gitDir, [operation, 'orig-head']),\n\t\t\t\t\t\tthis.readDotGitFile(gitDir, [operation, 'onto']),\n\t\t\t\t\t\tthis.readDotGitFile(gitDir, [operation, 'msgnum'], { numeric: true }),\n\t\t\t\t\t\tthis.readDotGitFile(gitDir, [operation, 'end'], { numeric: true }),\n\t\t\t\t\t\tthis.readDotGitFile(gitDir, [operation, 'message'], { throw: true }).catch(() =>\n\t\t\t\t\t\t\tthis.readDotGitFile(gitDir, [operation, 'message-squashed']),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tstat(joinPaths(gitDir.uri.fsPath, operation, 'interactive')).then(\n\t\t\t\t\t\t\t() => true,\n\t\t\t\t\t\t\t() => false,\n\t\t\t\t\t\t),\n\t\t\t\t\t]);\n\n\t\t\t\t\tif (cancellation?.aborted) throw new CancellationError();\n\n\t\t\t\t\tconst origHead = getSettledValue(origHeadResult);\n\t\t\t\t\tconst onto = getSettledValue(ontoResult);\n\t\t\t\t\tif (origHead == null || onto == null) {\n\t\t\t\t\t\tscope?.addExitInfo(`Neither '${operation}/orig-head' nor '${operation}/onto' found`);\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\tconst rebaseHead = getSettledValue(rebaseHeadResult)?.stdout.trim();\n\n\t\t\t\t\tif (branch.startsWith('refs/heads/')) {\n\t\t\t\t\t\tbranch = branch.substring(11).trim();\n\t\t\t\t\t}\n\n\t\t\t\t\tconst [mergeBaseResult, branchTipsResult, tagTipsResult] = await Promise.allSettled([\n\t\t\t\t\t\trebaseHead\n\t\t\t\t\t\t\t? this.provider.refs.getMergeBase(repoPath, rebaseHead, 'HEAD', undefined, cancellation)\n\t\t\t\t\t\t\t: this.provider.refs.getMergeBase(repoPath, onto, origHead, undefined, cancellation),\n\t\t\t\t\t\tthis.provider.branches.getBranchesWithCommits(\n\t\t\t\t\t\t\trepoPath,\n\t\t\t\t\t\t\t[onto],\n\t\t\t\t\t\t\tundefined,\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tall: true,\n\t\t\t\t\t\t\t\tmode: 'pointsAt',\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\tcancellation,\n\t\t\t\t\t\t),\n\t\t\t\t\t\tthis.provider.tags.getTagsWithCommit(repoPath, onto, { mode: 'pointsAt' }, cancellation),\n\t\t\t\t\t]);\n\n\t\t\t\t\tif (cancellation?.aborted) throw new CancellationError();\n\n\t\t\t\t\tconst mergeBase = getSettledValue(mergeBaseResult);\n\t\t\t\t\tconst branchTips = getSettledValue(branchTipsResult);\n\t\t\t\t\tconst tagTips = getSettledValue(tagTipsResult);\n\n\t\t\t\t\tlet ontoRef: GitBranchReference | GitTagReference | undefined;\n\t\t\t\t\tif (branchTips != null) {\n\t\t\t\t\t\tfor (const ref of branchTips) {\n\t\t\t\t\t\t\tif (ref.startsWith('(no branch, rebasing')) continue;\n\n\t\t\t\t\t\t\tontoRef = createReference(ref, repoPath, {\n\t\t\t\t\t\t\t\trefType: 'branch',\n\t\t\t\t\t\t\t\tname: ref,\n\t\t\t\t\t\t\t\tremote: false,\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif (ontoRef == null && tagTips != null) {\n\t\t\t\t\t\tfor (const ref of tagTips) {\n\t\t\t\t\t\t\tif (ref.startsWith('(no branch, rebasing')) continue;\n\n\t\t\t\t\t\t\tontoRef = createReference(ref, repoPath, {\n\t\t\t\t\t\t\t\trefType: 'tag',\n\t\t\t\t\t\t\t\tname: ref,\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tconst stepsNumber = getSettledValue(stepsNumberResult) ?? 0;\n\n\t\t\t\t\treturn {\n\t\t\t\t\t\ttype: 'rebase',\n\t\t\t\t\t\trepoPath: repoPath,\n\t\t\t\t\t\tmergeBase: mergeBase,\n\t\t\t\t\t\tHEAD: createReference(rebaseHead ?? origHead, repoPath, { refType: 'revision' }),\n\t\t\t\t\t\tonto: createReference(onto, repoPath, { refType: 'revision' }),\n\t\t\t\t\t\tsource: createReference(origHead, repoPath, { refType: 'revision' }),\n\t\t\t\t\t\tcurrent: ontoRef,\n\t\t\t\t\t\tincoming: createReference(branch, repoPath, {\n\t\t\t\t\t\t\trefType: 'branch',\n\t\t\t\t\t\t\tname: branch,\n\t\t\t\t\t\t\tremote: false,\n\t\t\t\t\t\t}),\n\t\t\t\t\t\tsteps: {\n\t\t\t\t\t\t\tcurrent: {\n\t\t\t\t\t\t\t\tnumber: stepsNumber,\n\t\t\t\t\t\t\t\tcommit: rebaseHead\n\t\t\t\t\t\t\t\t\t? createReference(rebaseHead, repoPath, {\n\t\t\t\t\t\t\t\t\t\t\trefType: 'revision',\n\t\t\t\t\t\t\t\t\t\t\tmessage: getSettledValue(stepsMessageResult),\n\t\t\t\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t\t\t: undefined,\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\ttotal: getSettledValue(stepsTotalResult) ?? 0,\n\t\t\t\t\t\t},\n\t\t\t\t\t\thasStarted: stepsNumber > 0,\n\t\t\t\t\t\t// REBASE_HEAD only exists when git is paused and waiting for user action\n\t\t\t\t\t\tisPaused: stepsNumber > 0 && rebaseHead != null,\n\t\t\t\t\t\t// 'interactive' file exists for `git rebase -i`, absent for `git pull --rebase`\n\t\t\t\t\t\tisInteractive: getSettledValue(isInteractiveResult) ?? false,\n\t\t\t\t\t} satisfies GitRebaseStatus;\n\t\t\t\t}\n\t\t\t\tcase 'sequencer': {\n\t\t\t\t\t// Used for multi-commit cherry-picks/reverts when CHERRY_PICK_HEAD/REVERT_HEAD don't exist\n\t\t\t\t\tconst todoContent = await this.readDotGitFile(gitDir, ['sequencer', 'todo']);\n\t\t\t\t\tif (!todoContent) {\n\t\t\t\t\t\tscope?.addExitInfo('No sequencer/todo file found');\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\t// Get the first line and determine if it's a cherry-pick or revert\n\t\t\t\t\tconst firstLine = todoContent.split('\\n')[0]?.trim();\n\t\t\t\t\tif (!firstLine) {\n\t\t\t\t\t\tscope?.addExitInfo('Empty sequencer/todo file');\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\t// Check if it's a pick (cherry-pick) or revert command\n\t\t\t\t\t// Format: \"pick <sha> <message>\" or \"p <sha> <message>\" or \"revert <sha> <message>\"\n\t\t\t\t\tconst isCherryPick = /^p(?:ick)?\\s/.test(firstLine);\n\t\t\t\t\tconst isRevert = /^revert\\s/.test(firstLine);\n\n\t\t\t\t\tif (!isCherryPick && !isRevert) {\n\t\t\t\t\t\tscope?.addExitInfo(`Unknown sequencer command: ${firstLine}`);\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\t// Parse the commit sha being applied from the todo file\n\t\t\t\t\tconst match = firstLine.match(todoCommitRegex);\n\t\t\t\t\tconst currentCommitSha = match?.[1];\n\t\t\t\t\tif (!currentCommitSha) {\n\t\t\t\t\t\tscope?.addExitInfo('Could not parse commit sha from sequencer/todo');\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\t// The todo line carries only the commit's SUBJECT (the other producers carry the full\n\t\t\t\t\t// message) — good enough to name the commit a skip would drop, without another git call\n\t\t\t\t\tconst message = match?.[2]?.trim() || undefined;\n\n\t\t\t\t\tconst [branchResult, mergeBaseResult] = await Promise.allSettled([\n\t\t\t\t\t\tthis.provider.branches.getCurrentBranchReference(repoPath, cancellation),\n\t\t\t\t\t\tthis.provider.refs.getMergeBase(repoPath, currentCommitSha, 'HEAD', undefined, cancellation),\n\t\t\t\t\t]);\n\t\t\t\t\tif (cancellation?.aborted) throw new CancellationError();\n\n\t\t\t\t\tconst current = getSettledValue(branchResult)!;\n\t\t\t\t\tconst mergeBase = getSettledValue(mergeBaseResult);\n\n\t\t\t\t\tif (isCherryPick) {\n\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\ttype: 'cherry-pick',\n\t\t\t\t\t\t\trepoPath: repoPath,\n\t\t\t\t\t\t\tmergeBase: mergeBase,\n\t\t\t\t\t\t\tHEAD: createReference(currentCommitSha, repoPath, {\n\t\t\t\t\t\t\t\trefType: 'revision',\n\t\t\t\t\t\t\t\tmessage: message,\n\t\t\t\t\t\t\t}),\n\t\t\t\t\t\t\tcurrent: current,\n\t\t\t\t\t\t\tincoming: createReference(currentCommitSha, repoPath, {\n\t\t\t\t\t\t\t\trefType: 'revision',\n\t\t\t\t\t\t\t\tmessage: message,\n\t\t\t\t\t\t\t}),\n\t\t\t\t\t\t} satisfies GitCherryPickStatus;\n\t\t\t\t\t}\n\n\t\t\t\t\treturn {\n\t\t\t\t\t\ttype: 'revert',\n\t\t\t\t\t\trepoPath: repoPath,\n\t\t\t\t\t\tmergeBase: mergeBase,\n\t\t\t\t\t\tHEAD: createReference(currentCommitSha, repoPath, { refType: 'revision', message: message }),\n\t\t\t\t\t\tcurrent: current,\n\t\t\t\t\t\tincoming: createReference(currentCommitSha, repoPath, {\n\t\t\t\t\t\t\trefType: 'revision',\n\t\t\t\t\t\t\tmessage: message,\n\t\t\t\t\t\t}),\n\t\t\t\t\t} satisfies GitRevertStatus;\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\n\t\treturn status;\n\t}\n\n\t/** Memoized per repo by sha — forced status re-reads on FS noise (every file save while resolving\n\t * conflicts) would otherwise re-spawn `git log` for an unchanging commit. */\n\tprivate readonly _commitMessageCache = new Map<string, { sha: string; message: string | undefined }>();\n\n\tprivate async getCommitMessage(\n\t\trepoPath: string,\n\t\tsha: string,\n\t\tcancellation?: AbortSignal,\n\t): Promise<string | undefined> {\n\t\tconst cached = this._commitMessageCache.get(repoPath);\n\t\tif (cached?.sha === sha) return cached.message;\n\n\t\tconst result = await this.git.run(\n\t\t\t{ cwd: repoPath, cancellation: cancellation, errors: 'ignore' },\n\t\t\t'log',\n\t\t\t'-1',\n\t\t\t'--format=%B',\n\t\t\tsha,\n\t\t);\n\t\tconst message = result.stdout.trim() || undefined;\n\t\t// Don't cache a miss — a transient failure would otherwise stick for the operation's lifetime\n\t\tif (message != null) {\n\t\t\tthis._commitMessageCache.set(repoPath, { sha: sha, message: message });\n\t\t}\n\t\treturn message;\n\t}\n\n\tprivate async readDotGitFile(\n\t\tgitDir: GitDir,\n\t\tpathParts: string[],\n\t\toptions?: { numeric?: false; throw?: boolean; trim?: boolean },\n\t): Promise<string | undefined>;\n\tprivate async readDotGitFile(\n\t\tgitDir: GitDir,\n\t\tpathParts: string[],\n\t\toptions?: { numeric: true; throw?: boolean; trim?: boolean },\n\t): Promise<number | undefined>;\n\tprivate async readDotGitFile(\n\t\tgitDir: GitDir,\n\t\tpathParts: string[],\n\t\toptions?: { numeric?: boolean; throw?: boolean; trim?: boolean },\n\t): Promise<string | number | undefined> {\n\t\ttry {\n\t\t\tconst filePath = joinPaths(gitDir.uri.fsPath, ...pathParts);\n\t\t\tconst bytes = await readFile(filePath);\n\t\t\tlet contents = new TextDecoder('utf8').decode(bytes);\n\t\t\tcontents = (options?.trim ?? true) ? contents.trim() : contents;\n\n\t\t\tif (options?.numeric) {\n\t\t\t\tconst number = Number.parseInt(contents, 10);\n\t\t\t\treturn isNaN(number) ? undefined : number;\n\t\t\t}\n\n\t\t\treturn contents;\n\t\t} catch (ex) {\n\t\t\tif (options?.throw) throw ex;\n\n\t\t\treturn undefined;\n\t\t}\n\t}\n\n\t@gate((rp, o) => `${rp ?? ''}:${o?.quit ?? false}`)\n\t@debug()\n\tasync abortPausedOperation(repoPath: string, options?: { quit?: boolean }): Promise<void> {\n\t\tconst scope = getScopedLogger();\n\n\t\tconst status = await this.getPausedOperationStatus(repoPath);\n\t\tif (status == null) return;\n\n\t\tconst args = [status.type, options?.quit ? '--quit' : '--abort'];\n\n\t\ttry {\n\t\t\t// Unbounded like the operations it undoes — an abort of a large rebase can outrun the default\n\t\t\t// command timeout, and being SIGTERM'd partway through would leave the repo mid-abort.\n\t\t\tawait refreshIndexAfter(this.indexRefresher, repoPath, () =>\n\t\t\t\tthis.git.run({ cwd: repoPath, errors: 'throw', timeout: 0 }, ...args),\n\t\t\t);\n\t\t} catch (ex) {\n\t\t\tscope?.error(ex);\n\t\t\tthrow getGitCommandError(\n\t\t\t\t'paused-operation-abort',\n\t\t\t\tex,\n\t\t\t\treason =>\n\t\t\t\t\tnew PausedOperationAbortError(\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treason: reason,\n\t\t\t\t\t\t\toperation: status,\n\t\t\t\t\t\t\tgitCommand: { repoPath: repoPath, args: args },\n\t\t\t\t\t\t},\n\t\t\t\t\t\tex,\n\t\t\t\t\t),\n\t\t\t);\n\t\t} finally {\n\t\t\t// An abort that fails or is cancelled partway can still have moved HEAD or reset the working tree\n\t\t\tthis.context.hooks?.cache?.onReset?.(repoPath, 'branches', 'status');\n\t\t\tthis.context.hooks?.repository?.onChanged?.(repoPath, ['head', 'heads', 'index']);\n\t\t}\n\t}\n\n\t@debug()\n\tasync continuePausedOperation(\n\t\trepoPath: string,\n\t\toptions?: {\n\t\t\tallowEmpty?: boolean;\n\t\t\tskip?: boolean;\n\t\t\tmessageEditor?: string;\n\t\t\teditorEnv?: Record<string, string>;\n\t\t},\n\t): Promise<void> {\n\t\tconst scope = getScopedLogger();\n\n\t\tconst status = await this.getPausedOperationStatus(repoPath);\n\t\tif (status == null) return;\n\n\t\tif (status.type === 'merge' && options?.skip) {\n\t\t\tthrow new Error(l10n.t('Skipping a merge is not supported'));\n\t\t}\n\n\t\tconst args = [status.type, options?.skip ? '--skip' : '--continue'];\n\n\t\t// Continuing after a conflicted step can open the commit-message editor (merge-backend rebases,\n\t\t// cherry-picks, and reverts). `GIT_EDITOR` is what git honors for that step, so set it on the\n\t\t// environment; also set `core.editor` config as a fallback.\n\t\tconst configs: string[] = [];\n\t\tlet env: Record<string, string | undefined> | undefined;\n\t\tif (options?.messageEditor) {\n\t\t\tconfigs.push('-c', `core.editor=${options.messageEditor}`);\n\t\t\tenv = { ...options.editorEnv, GIT_EDITOR: options.messageEditor };\n\t\t}\n\n\t\ttry {\n\t\t\tif (options?.allowEmpty) {\n\t\t\t\tconst commitArgs = ['commit', '--allow-empty', '--no-edit'];\n\t\t\t\ttry {\n\t\t\t\t\t// Git won't record the empty commit on its own; making it explicitly (`--no-edit` reuses the\n\t\t\t\t\t// message git already prepared) is what lets the operation move past it.\n\t\t\t\t\tawait this.git.run({ cwd: repoPath, errors: 'throw' }, ...commitArgs);\n\t\t\t\t} catch (ex) {\n\t\t\t\t\tscope?.error(ex);\n\t\t\t\t\t// Same reason taxonomy, but attributed to the commit that actually failed\n\t\t\t\t\tthrow getGitCommandError(\n\t\t\t\t\t\t'paused-operation-continue',\n\t\t\t\t\t\tex,\n\t\t\t\t\t\treason =>\n\t\t\t\t\t\t\tnew PausedOperationContinueError(\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\treason: reason,\n\t\t\t\t\t\t\t\t\toperation: status,\n\t\t\t\t\t\t\t\t\tskip: false,\n\t\t\t\t\t\t\t\t\tgitCommand: { repoPath: repoPath, args: commitArgs },\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\tex,\n\t\t\t\t\t\t\t),\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tawait refreshIndexAfter(this.indexRefresher, repoPath, () =>\n\t\t\t\tthis.git.run(\n\t\t\t\t\t{\n\t\t\t\t\t\tcwd: repoPath,\n\t\t\t\t\t\terrors: 'throw',\n\t\t\t\t\t\tconfigs: configs,\n\t\t\t\t\t\tenv: env,\n\t\t\t\t\t\t// A `--continue` that opens the commit-message editor blocks for as long as the user leaves\n\t\t\t\t\t\t// that tab open, which is unbounded — the default `advanced.git.timeout` would SIGTERM it\n\t\t\t\t\t\t// mid-operation. The start paths (merge/rebase/revert) opt out for the same reason.\n\t\t\t\t\t\ttimeout: 0,\n\t\t\t\t\t\t// The runner dedups in-flight commands by args only — it ignores per-call `configs`/`env`.\n\t\t\t\t\t\t// A headless continue (with `GIT_EDITOR`) and a plain `--continue` would therefore collapse\n\t\t\t\t\t\t// into one execution, so the plain one could silently run headless (auto-accepting a commit\n\t\t\t\t\t\t// message) or the headless one could ride a plain continue and open an editor that hangs the\n\t\t\t\t\t\t// loop. Tag the headless variant so it can't share a pending command with the plain one.\n\t\t\t\t\t\tcorrelationKey: options?.messageEditor ? 'paused-op-continue-headless' : undefined,\n\t\t\t\t\t},\n\t\t\t\t\t...args,\n\t\t\t\t),\n\t\t\t);\n\t\t} catch (ex) {\n\t\t\tif (PausedOperationContinueError.is(ex)) throw ex;\n\n\t\t\tconst error = getGitCommandError(\n\t\t\t\t'paused-operation-continue',\n\t\t\t\tex,\n\t\t\t\treason =>\n\t\t\t\t\tnew PausedOperationContinueError(\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treason: reason,\n\t\t\t\t\t\t\toperation: status,\n\t\t\t\t\t\t\tskip: options?.skip ?? false,\n\t\t\t\t\t\t\tgitCommand: { repoPath: repoPath, args: args },\n\t\t\t\t\t\t},\n\t\t\t\t\t\tex,\n\t\t\t\t\t),\n\t\t\t);\n\n\t\t\t// An empty commit concludes a single-commit cherry-pick/revert outright, leaving its\n\t\t\t// `--continue` nothing to continue — the operation finished either way.\n\t\t\tif (!options?.allowEmpty || !PausedOperationContinueError.is(error, 'nothingToContinue')) {\n\t\t\t\tscope?.error(ex);\n\t\t\t\tthrow error;\n\t\t\t}\n\t\t} finally {\n\t\t\t// Notify unconditionally rather than only on success: a throwing `--continue` can still have\n\t\t\t// mutated the repo (committing the resolved step, then stopping on the NEXT step's conflict or\n\t\t\t// empty commit), and the error alone can't distinguish that from a no-op failure. Invalidating\n\t\t\t// after a genuine no-op only costs a re-read; not invalidating after a real advance leaves\n\t\t\t// consumers rendering a stale step.\n\t\t\tthis.context.hooks?.cache?.onReset?.(repoPath, 'branches', 'status');\n\t\t\tthis.context.hooks?.repository?.onChanged?.(repoPath, ['head', 'heads', 'index']);\n\t\t}\n\t}\n}\n"],"mappings":";;;;;;;;;;;;;;;AA8BA,MAAM,kBAAkB;AAMxB,MAAM,oBAAiC;CAAC;CAAgB;CAAgB;CAAS;CAAe;CAAU;AAAW;AAErH,IAAa,iCAAb,MAAsF;CAEnE;CACA;CACA;CACA;CACA;CALlB,YACC,SACA,KACA,OACA,UACA,gBACC;EALgB,KAAA,UAAA;EACA,KAAA,MAAA;EACA,KAAA,QAAA;EACA,KAAA,WAAA;EACA,KAAA,iBAAA;CACf;;;;;;CAOH,MACM,mBAAmB,UAAkB,cAA8C;EACxF,MAAM,SAAS,MAAM,KAAK,SAAS,OAAO,UAAU,QAAQ;EAC5D,MAAM,aAAa,MAAM,KAAK,WAAW,MAAM;EAC/C,IAAI,cAAc,SAAS,MAAM,IAAI,kBAAkB;EAEvD,KAAK,MAAM,aAAa,YAEvB,IAAI,cAAc,aAAa,OAAO;EAEvC,IAAI,CAAC,WAAW,IAAI,WAAW,GAAG,OAAO;EAEzC,IAAI;GACH,MAAM,KAAK,UAAU,OAAO,IAAI,QAAQ,aAAa,MAAM,CAAC;GAC5D,OAAO;EACR,SAAS,IAAI;GACZ,IAAK,GAA6B,SAAS,UAAU,OAAO;GAC5D,MAAM;EACP;CACD;;CAGA,WAAmB,QAAyC;EAC3D,OAAO,IAAI,SAAyB,SAAS,WAAW;GACvD,QAAQ,OAAO,IAAI,QAAQ,EAAE,eAAe,KAAK,IAAI,KAAK,YAAY;IACrE,IAAI,OAAO,MAAM;KAChB,OAAO,GAAG;KACV;IACD;IAEA,MAAM,6BAAa,IAAI,IAAe;IACtC,KAAK,MAAM,SAAS,SACnB,IAAI,MAAM,OAAO,GAChB,QAAQ,MAAM,MAAd;KACC,KAAK;MACJ,WAAW,IAAI,aAAa;MAC5B;KACD,KAAK;MACJ,WAAW,IAAI,OAAO;MACtB;KACD,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,OAAO,GACjD,MAAM,CAAA,GAAA,+BAAA,WAAA,wBAAA,IAAA;AAqCN,WAAA,CAAA,MAAM,CAAA,GAAA,+BAAA,WAAA,2BAAA,IAAA"}
|
|
1
|
+
{"version":3,"file":"pausedOperations.js","names":[],"sources":["../../../../git-cli/src/providers/pausedOperations.ts"],"sourcesContent":["import { readdir } from 'fs';\nimport { readFile, stat } from 'fs/promises';\nimport * as l10n from '@vscode/l10n';\nimport type { Cache } from '@gitlens/git/cache.js';\nimport type { GitServiceContext } from '@gitlens/git/context.js';\nimport { PausedOperationAbortError, PausedOperationContinueError } from '@gitlens/git/errors.js';\nimport type {\n\tGitCherryPickStatus,\n\tGitMergeStatus,\n\tGitPausedOperationStatus,\n\tGitRebaseStatus,\n\tGitRevertStatus,\n} from '@gitlens/git/models/pausedOperationStatus.js';\nimport type { GitBranchReference, GitTagReference } from '@gitlens/git/models/reference.js';\nimport type { GitDir } from '@gitlens/git/models/repository.js';\nimport type { GitPausedOperationsSubProvider } from '@gitlens/git/providers/pausedOperations.js';\nimport { createReference } from '@gitlens/git/utils/reference.utils.js';\nimport { CancellationError } from '@gitlens/utils/cancellation.js';\nimport { gate } from '@gitlens/utils/decorators/gate.js';\nimport { debug } from '@gitlens/utils/decorators/log.js';\nimport type { ScopedLogger } from '@gitlens/utils/logger.scoped.js';\nimport { getScopedLogger } from '@gitlens/utils/logger.scoped.js';\nimport { joinPaths } from '@gitlens/utils/path.js';\nimport { getSettledValue } from '@gitlens/utils/promise.js';\nimport type { CacheController } from '@gitlens/utils/promiseCache.js';\nimport type { CliGitProviderInternal } from '../cliGitProvider.js';\nimport type { Git } from '../exec/git.js';\nimport { getGitCommandError } from '../exec/git.js';\nimport type { IndexRefresher } from '../exec/indexRefresh.js';\nimport { refreshIndexAfter } from '../exec/indexRefresh.js';\n\nconst todoCommitRegex = /^(?:p(?:ick)?|revert)\\s+([a-f0-9]+)(?:\\s+(.+))?$/i;\n\ntype Operation = 'cherry-pick' | 'merge' | 'rebase-apply' | 'rebase-merge' | 'revert' | 'sequencer';\n\n// Note: 'sequencer' is checked after specific HEAD files since those take precedence\n// The sequencer directory is used for multi-commit cherry-picks/reverts\nconst orderedOperations: Operation[] = ['rebase-apply', 'rebase-merge', 'merge', 'cherry-pick', 'revert', 'sequencer'];\n\nconst rebaseStepFiles = {\n\t'rebase-apply': { number: 'next', total: 'last' },\n\t'rebase-merge': { number: 'msgnum', total: 'end' },\n} as const;\n\nconst fingerprintFiles: Record<Operation, string[][]> = {\n\t'cherry-pick': [['CHERRY_PICK_HEAD']],\n\tmerge: [['MERGE_HEAD']],\n\trevert: [['REVERT_HEAD']],\n\t'rebase-apply': [\n\t\t['REBASE_HEAD'],\n\t\t['rebase-apply', 'next'],\n\t\t['rebase-apply', 'last'],\n\t\t['rebase-apply', 'onto'],\n\t\t['rebase-apply', 'head-name'],\n\t\t['rebase-apply', 'orig-head'],\n\t],\n\t'rebase-merge': [\n\t\t['REBASE_HEAD'],\n\t\t['rebase-merge', 'msgnum'],\n\t\t['rebase-merge', 'end'],\n\t\t['rebase-merge', 'onto'],\n\t\t['rebase-merge', 'head-name'],\n\t\t['rebase-merge', 'orig-head'],\n\t],\n\tsequencer: [],\n};\n\nexport class PausedOperationsGitSubProvider implements GitPausedOperationsSubProvider {\n\tconstructor(\n\t\tprivate readonly context: GitServiceContext,\n\t\tprivate readonly git: Git,\n\t\tprivate readonly cache: Cache,\n\t\tprivate readonly provider: CliGitProviderInternal,\n\t\tprivate readonly indexRefresher?: IndexRefresher,\n\t) {}\n\n\t/**\n\t * Whether git's dir holds a sentinel of an in-progress operation (presence only — no content is parsed,\n\t * so it also answers `true` for states `getPausedOperationStatus` can't describe, e.g. a stopped `git am`).\n\t * Rejects when git's dir can't be resolved or read\n\t */\n\t@debug({ quiet: true })\n\tasync hasPausedOperation(repoPath: string, cancellation?: AbortSignal): Promise<boolean> {\n\t\tconst gitDir = await this.provider.config.getGitDir(repoPath);\n\t\tconst operations = await this.scanGitDir(gitDir);\n\t\tif (cancellation?.aborted) throw new CancellationError();\n\n\t\tfor (const operation of operations) {\n\t\t\t// A bare leftover `sequencer` dir isn't in progress; git itself checks for `sequencer/todo`\n\t\t\tif (operation !== 'sequencer') return true;\n\t\t}\n\t\tif (!operations.has('sequencer')) return false;\n\n\t\ttry {\n\t\t\tawait stat(joinPaths(gitDir.uri.fsPath, 'sequencer', 'todo'));\n\t\t\treturn true;\n\t\t} catch (ex) {\n\t\t\tif ((ex as NodeJS.ErrnoException).code === 'ENOENT') return false;\n\t\t\tthrow ex;\n\t\t}\n\t}\n\n\t/** Lists the operation sentinels in git's dir; rejects if the dir can't be read */\n\tprivate scanGitDir(gitDir: GitDir): Promise<Set<Operation>> {\n\t\treturn new Promise<Set<Operation>>((resolve, reject) => {\n\t\t\treaddir(gitDir.uri.fsPath, { withFileTypes: true }, (err, entries) => {\n\t\t\t\tif (err != null) {\n\t\t\t\t\treject(err);\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tconst operations = new Set<Operation>();\n\t\t\t\tfor (const entry of entries) {\n\t\t\t\t\tif (entry.isFile()) {\n\t\t\t\t\t\tswitch (entry.name) {\n\t\t\t\t\t\t\tcase 'CHERRY_PICK_HEAD':\n\t\t\t\t\t\t\t\toperations.add('cherry-pick');\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'MERGE_HEAD':\n\t\t\t\t\t\t\t\toperations.add('merge');\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'REVERT_HEAD':\n\t\t\t\t\t\t\t\toperations.add('revert');\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t} else if (entry.isDirectory()) {\n\t\t\t\t\t\tswitch (entry.name) {\n\t\t\t\t\t\t\tcase 'rebase-apply':\n\t\t\t\t\t\t\t\toperations.add('rebase-apply');\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'rebase-merge':\n\t\t\t\t\t\t\t\toperations.add('rebase-merge');\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'sequencer':\n\t\t\t\t\t\t\t\t// The sequencer directory is used for multi-commit cherry-picks/reverts\n\t\t\t\t\t\t\t\t// We'll determine the type by reading the todo file later\n\t\t\t\t\t\t\t\toperations.add('sequencer');\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tresolve(operations);\n\t\t\t});\n\t\t});\n\t}\n\n\t@debug({ quiet: true })\n\tgetPausedOperationStatus(\n\t\trepoPath: string,\n\t\toptions?: { force?: boolean },\n\t\tcancellation?: AbortSignal,\n\t): Promise<GitPausedOperationStatus | undefined> {\n\t\tconst scope = getScopedLogger();\n\n\t\t// A forced read drops the cached status and reads it again anyway, so it has nothing to wait for\n\t\tconst validation = options?.force ? undefined : this.cache.validateBeforeRead(repoPath);\n\t\treturn validation != null\n\t\t\t? validation.then(() => this.readPausedOperationStatus(repoPath, options, scope, cancellation))\n\t\t\t: this.readPausedOperationStatus(repoPath, options, scope, cancellation);\n\t}\n\n\tprivate readonly _fingerprints = new WeakMap<Promise<GitPausedOperationStatus | undefined>, string>();\n\n\tprivate async readPausedOperationStatus(\n\t\trepoPath: string,\n\t\toptions: { force?: boolean } | undefined,\n\t\tscope: ScopedLogger | undefined,\n\t\tcancellation: AbortSignal | undefined,\n\t): Promise<GitPausedOperationStatus | undefined> {\n\t\tconst map = this.cache.pausedOperationStatus;\n\n\t\tlet gitDir: GitDir;\n\t\tlet operations: Set<Operation>;\n\t\ttry {\n\t\t\tgitDir = await this.provider.config.getGitDir(repoPath);\n\t\t\toperations = await this.scanGitDir(gitDir);\n\t\t} catch {\n\t\t\tmap.delete(repoPath);\n\t\t\treturn undefined;\n\t\t}\n\n\t\tif (!operations.size) {\n\t\t\tmap.delete(repoPath);\n\t\t\treturn undefined;\n\t\t}\n\n\t\tconst fingerprint = await this.readFingerprint(gitDir, operations);\n\t\tif (cancellation?.aborted) throw new CancellationError();\n\n\t\tconst read = async (\n\t\t\tcacheable: CacheController,\n\t\t\tsignal?: AbortSignal,\n\t\t): Promise<GitPausedOperationStatus | undefined> => {\n\t\t\tconst sortedOperations = [...operations].sort(\n\t\t\t\t(a, b) => orderedOperations.indexOf(a) - orderedOperations.indexOf(b),\n\t\t\t);\n\t\t\tscope?.info(`Detected paused operations: ${sortedOperations.join(', ')}`);\n\n\t\t\tconst operation = sortedOperations[0];\n\t\t\tswitch (operation) {\n\t\t\t\tcase 'cherry-pick': {\n\t\t\t\t\tconst result = await this.git.run(\n\t\t\t\t\t\t{ cwd: repoPath, cancellation: signal, errors: 'ignore' },\n\t\t\t\t\t\t'rev-parse',\n\t\t\t\t\t\t'--quiet',\n\t\t\t\t\t\t'--verify',\n\t\t\t\t\t\t'CHERRY_PICK_HEAD',\n\t\t\t\t\t);\n\t\t\t\t\tif (result.completion.status === 'cancelled' || signal?.aborted) {\n\t\t\t\t\t\tthrow new CancellationError();\n\t\t\t\t\t}\n\n\t\t\t\t\tconst cherryPickHead = result.stdout.trim();\n\t\t\t\t\tif (!cherryPickHead) {\n\t\t\t\t\t\tscope?.addExitInfo('No CHERRY_PICK_HEAD found');\n\t\t\t\t\t\tcacheable.invalidate();\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\tconst [branchResult, mergeBaseResult, messageResult] = await Promise.allSettled([\n\t\t\t\t\t\tthis.provider.branches.getCurrentBranchReference(repoPath, signal),\n\t\t\t\t\t\tthis.provider.refs.getMergeBase(repoPath, 'CHERRY_PICK_HEAD', 'HEAD', undefined, signal),\n\t\t\t\t\t\tthis.getCommitMessage(repoPath, cherryPickHead, signal),\n\t\t\t\t\t]);\n\t\t\t\t\tif (signal?.aborted) throw new CancellationError();\n\n\t\t\t\t\tconst current = getSettledValue(branchResult)!;\n\t\t\t\t\tconst mergeBase = getSettledValue(mergeBaseResult);\n\t\t\t\t\tconst message = getSettledValue(messageResult);\n\n\t\t\t\t\treturn {\n\t\t\t\t\t\ttype: 'cherry-pick',\n\t\t\t\t\t\trepoPath: repoPath,\n\t\t\t\t\t\tmergeBase: mergeBase,\n\t\t\t\t\t\tHEAD: createReference(cherryPickHead, repoPath, { refType: 'revision', message: message }),\n\t\t\t\t\t\tcurrent: current,\n\t\t\t\t\t\tincoming: createReference(cherryPickHead, repoPath, {\n\t\t\t\t\t\t\trefType: 'revision',\n\t\t\t\t\t\t\tmessage: message,\n\t\t\t\t\t\t}),\n\t\t\t\t\t} satisfies GitCherryPickStatus;\n\t\t\t\t}\n\t\t\t\tcase 'merge': {\n\t\t\t\t\tconst result = await this.git.run(\n\t\t\t\t\t\t{ cwd: repoPath, cancellation: signal, errors: 'ignore' },\n\t\t\t\t\t\t'rev-parse',\n\t\t\t\t\t\t'--quiet',\n\t\t\t\t\t\t'--verify',\n\t\t\t\t\t\t'MERGE_HEAD',\n\t\t\t\t\t);\n\t\t\t\t\tif (result.completion.status === 'cancelled' || signal?.aborted) {\n\t\t\t\t\t\tthrow new CancellationError();\n\t\t\t\t\t}\n\n\t\t\t\t\tconst mergeHead = result.stdout.trim();\n\t\t\t\t\tif (!mergeHead) {\n\t\t\t\t\t\tscope?.addExitInfo('No MERGE_HEAD found');\n\t\t\t\t\t\tcacheable.invalidate();\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\tconst [branchResult, mergeBaseResult, possibleSourceBranchesResult] = await Promise.allSettled([\n\t\t\t\t\t\tthis.provider.branches.getCurrentBranchReference(repoPath, signal),\n\t\t\t\t\t\tthis.provider.refs.getMergeBase(repoPath, 'MERGE_HEAD', 'HEAD', undefined, signal),\n\t\t\t\t\t\tthis.provider.branches.getBranchesWithCommits(\n\t\t\t\t\t\t\trepoPath,\n\t\t\t\t\t\t\t['MERGE_HEAD'],\n\t\t\t\t\t\t\tundefined,\n\t\t\t\t\t\t\t{ all: true, mode: 'pointsAt' },\n\t\t\t\t\t\t\tsignal,\n\t\t\t\t\t\t),\n\t\t\t\t\t]);\n\n\t\t\t\t\tif (signal?.aborted) throw new CancellationError();\n\n\t\t\t\t\tconst current = getSettledValue(branchResult)!;\n\t\t\t\t\tconst mergeBase = getSettledValue(mergeBaseResult);\n\t\t\t\t\tconst possibleSourceBranches = getSettledValue(possibleSourceBranchesResult);\n\n\t\t\t\t\treturn {\n\t\t\t\t\t\ttype: 'merge',\n\t\t\t\t\t\trepoPath: repoPath,\n\t\t\t\t\t\tmergeBase: mergeBase,\n\t\t\t\t\t\tHEAD: createReference(mergeHead, repoPath, { refType: 'revision' }),\n\t\t\t\t\t\tcurrent: current,\n\t\t\t\t\t\tincoming:\n\t\t\t\t\t\t\tpossibleSourceBranches?.length === 1\n\t\t\t\t\t\t\t\t? createReference(possibleSourceBranches[0], repoPath, {\n\t\t\t\t\t\t\t\t\t\trefType: 'branch',\n\t\t\t\t\t\t\t\t\t\tname: possibleSourceBranches[0],\n\t\t\t\t\t\t\t\t\t\tremote: false,\n\t\t\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t\t: createReference(mergeHead, repoPath, { refType: 'revision' }),\n\t\t\t\t\t} satisfies GitMergeStatus;\n\t\t\t\t}\n\t\t\t\tcase 'revert': {\n\t\t\t\t\tconst result = await this.git.run(\n\t\t\t\t\t\t{ cwd: repoPath, cancellation: signal, errors: 'ignore' },\n\t\t\t\t\t\t'rev-parse',\n\t\t\t\t\t\t'--quiet',\n\t\t\t\t\t\t'--verify',\n\t\t\t\t\t\t'REVERT_HEAD',\n\t\t\t\t\t);\n\t\t\t\t\tif (result.completion.status === 'cancelled' || signal?.aborted) {\n\t\t\t\t\t\tthrow new CancellationError();\n\t\t\t\t\t}\n\n\t\t\t\t\tconst revertHead = result.stdout.trim();\n\t\t\t\t\tif (!revertHead) {\n\t\t\t\t\t\tscope?.addExitInfo('No REVERT_HEAD found');\n\t\t\t\t\t\tcacheable.invalidate();\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\tconst [branchResult, mergeBaseResult, messageResult] = await Promise.allSettled([\n\t\t\t\t\t\tthis.provider.branches.getCurrentBranchReference(repoPath, signal),\n\t\t\t\t\t\tthis.provider.refs.getMergeBase(repoPath, 'REVERT_HEAD', 'HEAD', undefined, signal),\n\t\t\t\t\t\tthis.getCommitMessage(repoPath, revertHead, signal),\n\t\t\t\t\t]);\n\t\t\t\t\tif (signal?.aborted) throw new CancellationError();\n\n\t\t\t\t\tconst current = getSettledValue(branchResult)!;\n\t\t\t\t\tconst mergeBase = getSettledValue(mergeBaseResult);\n\t\t\t\t\tconst message = getSettledValue(messageResult);\n\n\t\t\t\t\treturn {\n\t\t\t\t\t\ttype: 'revert',\n\t\t\t\t\t\trepoPath: repoPath,\n\t\t\t\t\t\tmergeBase: mergeBase,\n\t\t\t\t\t\tHEAD: createReference(revertHead, repoPath, { refType: 'revision', message: message }),\n\t\t\t\t\t\tcurrent: current,\n\t\t\t\t\t\tincoming: createReference(revertHead, repoPath, { refType: 'revision', message: message }),\n\t\t\t\t\t} satisfies GitRevertStatus;\n\t\t\t\t}\n\t\t\t\tcase 'rebase-apply':\n\t\t\t\tcase 'rebase-merge': {\n\t\t\t\t\tlet branch = await this.readDotGitFile(gitDir, [operation, 'head-name']);\n\t\t\t\t\tif (!branch) {\n\t\t\t\t\t\tscope?.addExitInfo(`No '${operation}/head-name' found`);\n\t\t\t\t\t\tcacheable.invalidate();\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\tconst [\n\t\t\t\t\t\trebaseHeadResult,\n\t\t\t\t\t\torigHeadResult,\n\t\t\t\t\t\tontoResult,\n\t\t\t\t\t\tstepsNumberResult,\n\t\t\t\t\t\tstepsTotalResult,\n\t\t\t\t\t\tstepsMessageResult,\n\t\t\t\t\t\tisInteractiveResult,\n\t\t\t\t\t] = await Promise.allSettled([\n\t\t\t\t\t\tthis.git.run(\n\t\t\t\t\t\t\t{ cwd: repoPath, cancellation: signal, errors: 'ignore' },\n\t\t\t\t\t\t\t'rev-parse',\n\t\t\t\t\t\t\t'--quiet',\n\t\t\t\t\t\t\t'--verify',\n\t\t\t\t\t\t\t'REBASE_HEAD',\n\t\t\t\t\t\t),\n\t\t\t\t\t\tthis.readDotGitFile(gitDir, [operation, 'orig-head']),\n\t\t\t\t\t\tthis.readDotGitFile(gitDir, [operation, 'onto']),\n\t\t\t\t\t\tthis.readDotGitFile(gitDir, [operation, rebaseStepFiles[operation].number], { numeric: true }),\n\t\t\t\t\t\tthis.readDotGitFile(gitDir, [operation, rebaseStepFiles[operation].total], { numeric: true }),\n\t\t\t\t\t\tthis.readDotGitFile(gitDir, [operation, 'message'], { throw: true }).catch(() =>\n\t\t\t\t\t\t\tthis.readDotGitFile(gitDir, [operation, 'message-squashed']),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tstat(joinPaths(gitDir.uri.fsPath, operation, 'interactive')).then(\n\t\t\t\t\t\t\t() => true,\n\t\t\t\t\t\t\t() => false,\n\t\t\t\t\t\t),\n\t\t\t\t\t]);\n\n\t\t\t\t\tif (signal?.aborted) throw new CancellationError();\n\n\t\t\t\t\tconst origHead = getSettledValue(origHeadResult);\n\t\t\t\t\tconst onto = getSettledValue(ontoResult);\n\t\t\t\t\tif (origHead == null || onto == null) {\n\t\t\t\t\t\tscope?.addExitInfo(`Neither '${operation}/orig-head' nor '${operation}/onto' found`);\n\t\t\t\t\t\tcacheable.invalidate();\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\tconst rebaseHead = getSettledValue(rebaseHeadResult)?.stdout.trim();\n\n\t\t\t\t\tif (branch.startsWith('refs/heads/')) {\n\t\t\t\t\t\tbranch = branch.substring(11).trim();\n\t\t\t\t\t}\n\n\t\t\t\t\tconst [mergeBaseResult, branchTipsResult, tagTipsResult] = await Promise.allSettled([\n\t\t\t\t\t\trebaseHead\n\t\t\t\t\t\t\t? this.provider.refs.getMergeBase(repoPath, rebaseHead, 'HEAD', undefined, signal)\n\t\t\t\t\t\t\t: this.provider.refs.getMergeBase(repoPath, onto, origHead, undefined, signal),\n\t\t\t\t\t\tthis.provider.branches.getBranchesWithCommits(\n\t\t\t\t\t\t\trepoPath,\n\t\t\t\t\t\t\t[onto],\n\t\t\t\t\t\t\tundefined,\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tall: true,\n\t\t\t\t\t\t\t\tmode: 'pointsAt',\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\tsignal,\n\t\t\t\t\t\t),\n\t\t\t\t\t\tthis.provider.tags.getTagsWithCommit(repoPath, onto, { mode: 'pointsAt' }, signal),\n\t\t\t\t\t]);\n\n\t\t\t\t\tif (signal?.aborted) throw new CancellationError();\n\n\t\t\t\t\tconst mergeBase = getSettledValue(mergeBaseResult);\n\t\t\t\t\tconst branchTips = getSettledValue(branchTipsResult);\n\t\t\t\t\tconst tagTips = getSettledValue(tagTipsResult);\n\n\t\t\t\t\tlet ontoRef: GitBranchReference | GitTagReference | undefined;\n\t\t\t\t\tif (branchTips != null) {\n\t\t\t\t\t\tfor (const ref of branchTips) {\n\t\t\t\t\t\t\tif (ref.startsWith('(no branch, rebasing')) continue;\n\n\t\t\t\t\t\t\tontoRef = createReference(ref, repoPath, {\n\t\t\t\t\t\t\t\trefType: 'branch',\n\t\t\t\t\t\t\t\tname: ref,\n\t\t\t\t\t\t\t\tremote: false,\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif (ontoRef == null && tagTips != null) {\n\t\t\t\t\t\tfor (const ref of tagTips) {\n\t\t\t\t\t\t\tif (ref.startsWith('(no branch, rebasing')) continue;\n\n\t\t\t\t\t\t\tontoRef = createReference(ref, repoPath, {\n\t\t\t\t\t\t\t\trefType: 'tag',\n\t\t\t\t\t\t\t\tname: ref,\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tconst stepsNumber = getSettledValue(stepsNumberResult) ?? 0;\n\n\t\t\t\t\treturn {\n\t\t\t\t\t\ttype: 'rebase',\n\t\t\t\t\t\trepoPath: repoPath,\n\t\t\t\t\t\tmergeBase: mergeBase,\n\t\t\t\t\t\tHEAD: createReference(rebaseHead ?? origHead, repoPath, { refType: 'revision' }),\n\t\t\t\t\t\tonto: createReference(onto, repoPath, { refType: 'revision' }),\n\t\t\t\t\t\tsource: createReference(origHead, repoPath, { refType: 'revision' }),\n\t\t\t\t\t\tcurrent: ontoRef,\n\t\t\t\t\t\tincoming: createReference(branch, repoPath, {\n\t\t\t\t\t\t\trefType: 'branch',\n\t\t\t\t\t\t\tname: branch,\n\t\t\t\t\t\t\tremote: false,\n\t\t\t\t\t\t}),\n\t\t\t\t\t\tsteps: {\n\t\t\t\t\t\t\tcurrent: {\n\t\t\t\t\t\t\t\tnumber: stepsNumber,\n\t\t\t\t\t\t\t\tcommit: rebaseHead\n\t\t\t\t\t\t\t\t\t? createReference(rebaseHead, repoPath, {\n\t\t\t\t\t\t\t\t\t\t\trefType: 'revision',\n\t\t\t\t\t\t\t\t\t\t\tmessage: getSettledValue(stepsMessageResult),\n\t\t\t\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t\t\t: undefined,\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\ttotal: getSettledValue(stepsTotalResult) ?? 0,\n\t\t\t\t\t\t},\n\t\t\t\t\t\thasStarted: stepsNumber > 0,\n\t\t\t\t\t\t// REBASE_HEAD only exists when git is paused and waiting for user action\n\t\t\t\t\t\tisPaused: stepsNumber > 0 && rebaseHead != null,\n\t\t\t\t\t\tisInteractive: getSettledValue(isInteractiveResult) ?? false,\n\t\t\t\t\t} satisfies GitRebaseStatus;\n\t\t\t\t}\n\t\t\t\tcase 'sequencer': {\n\t\t\t\t\tconst todoContent = await this.readDotGitFile(gitDir, ['sequencer', 'todo']);\n\t\t\t\t\tif (!todoContent) {\n\t\t\t\t\t\tscope?.addExitInfo('No sequencer/todo file found');\n\t\t\t\t\t\tcacheable.invalidate();\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\tconst firstLine = todoContent.split('\\n')[0]?.trim();\n\t\t\t\t\tif (!firstLine) {\n\t\t\t\t\t\tscope?.addExitInfo('Empty sequencer/todo file');\n\t\t\t\t\t\tcacheable.invalidate();\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\t// Format: \"pick <sha> <message>\" or \"p <sha> <message>\" or \"revert <sha> <message>\"\n\t\t\t\t\tconst isCherryPick = /^p(?:ick)?\\s/.test(firstLine);\n\t\t\t\t\tconst isRevert = /^revert\\s/.test(firstLine);\n\n\t\t\t\t\tif (!isCherryPick && !isRevert) {\n\t\t\t\t\t\tscope?.addExitInfo(`Unknown sequencer command: ${firstLine}`);\n\t\t\t\t\t\tcacheable.invalidate();\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\tconst match = firstLine.match(todoCommitRegex);\n\t\t\t\t\tconst currentCommitSha = match?.[1];\n\t\t\t\t\tif (!currentCommitSha) {\n\t\t\t\t\t\tscope?.addExitInfo('Could not parse commit sha from sequencer/todo');\n\t\t\t\t\t\tcacheable.invalidate();\n\t\t\t\t\t\treturn undefined;\n\t\t\t\t\t}\n\n\t\t\t\t\t// The todo line carries only the commit's SUBJECT (the other producers carry the full\n\t\t\t\t\t// message) — good enough to name the commit a skip would drop, without another git call\n\t\t\t\t\tconst message = match?.[2]?.trim() || undefined;\n\n\t\t\t\t\tconst [branchResult, mergeBaseResult] = await Promise.allSettled([\n\t\t\t\t\t\tthis.provider.branches.getCurrentBranchReference(repoPath, signal),\n\t\t\t\t\t\tthis.provider.refs.getMergeBase(repoPath, currentCommitSha, 'HEAD', undefined, signal),\n\t\t\t\t\t]);\n\t\t\t\t\tif (signal?.aborted) throw new CancellationError();\n\n\t\t\t\t\tconst current = getSettledValue(branchResult)!;\n\t\t\t\t\tconst mergeBase = getSettledValue(mergeBaseResult);\n\n\t\t\t\t\tif (isCherryPick) {\n\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\ttype: 'cherry-pick',\n\t\t\t\t\t\t\trepoPath: repoPath,\n\t\t\t\t\t\t\tmergeBase: mergeBase,\n\t\t\t\t\t\t\tHEAD: createReference(currentCommitSha, repoPath, {\n\t\t\t\t\t\t\t\trefType: 'revision',\n\t\t\t\t\t\t\t\tmessage: message,\n\t\t\t\t\t\t\t}),\n\t\t\t\t\t\t\tcurrent: current,\n\t\t\t\t\t\t\tincoming: createReference(currentCommitSha, repoPath, {\n\t\t\t\t\t\t\t\trefType: 'revision',\n\t\t\t\t\t\t\t\tmessage: message,\n\t\t\t\t\t\t\t}),\n\t\t\t\t\t\t} satisfies GitCherryPickStatus;\n\t\t\t\t\t}\n\n\t\t\t\t\treturn {\n\t\t\t\t\t\ttype: 'revert',\n\t\t\t\t\t\trepoPath: repoPath,\n\t\t\t\t\t\tmergeBase: mergeBase,\n\t\t\t\t\t\tHEAD: createReference(currentCommitSha, repoPath, {\n\t\t\t\t\t\t\trefType: 'revision',\n\t\t\t\t\t\t\tmessage: message,\n\t\t\t\t\t\t}),\n\t\t\t\t\t\tcurrent: current,\n\t\t\t\t\t\tincoming: createReference(currentCommitSha, repoPath, {\n\t\t\t\t\t\t\trefType: 'revision',\n\t\t\t\t\t\t\tmessage: message,\n\t\t\t\t\t\t}),\n\t\t\t\t\t} satisfies GitRevertStatus;\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\n\t\tconst cached = map.get(repoPath);\n\t\tif (cached != null && (options?.force || this._fingerprints.get(cached) !== fingerprint)) {\n\t\t\tmap.delete(repoPath);\n\t\t}\n\n\t\tconst status = map.getOrCreate(repoPath, read, cancellation);\n\t\tconst entry = map.get(repoPath);\n\t\tif (entry != null && !this._fingerprints.has(entry)) {\n\t\t\tthis._fingerprints.set(entry, fingerprint);\n\t\t}\n\n\t\treturn status;\n\t}\n\n\tprivate async readFingerprint(gitDir: GitDir, operations: Set<Operation>): Promise<string> {\n\t\tconst sortedOperations = [...operations].sort();\n\t\tconst [todo, ...files] = await Promise.all([\n\t\t\toperations.has('sequencer') ? this.readDotGitFile(gitDir, ['sequencer', 'todo']) : undefined,\n\t\t\t...sortedOperations.flatMap(operation =>\n\t\t\t\tfingerprintFiles[operation].map(pathParts => this.readDotGitFile(gitDir, pathParts)),\n\t\t\t),\n\t\t]);\n\t\treturn [\n\t\t\tsortedOperations.join(','),\n\t\t\ttodo?.split('\\n', 1)[0]?.trim() ?? '',\n\t\t\t...files.map(contents => contents ?? ''),\n\t\t].join('\\0');\n\t}\n\n\t/** Memoized per repo by sha — forced status re-reads on FS noise (every file save while resolving\n\t * conflicts) would otherwise re-spawn `git log` for an unchanging commit. */\n\tprivate readonly _commitMessageCache = new Map<string, { sha: string; message: string | undefined }>();\n\n\tprivate async getCommitMessage(\n\t\trepoPath: string,\n\t\tsha: string,\n\t\tcancellation?: AbortSignal,\n\t): Promise<string | undefined> {\n\t\tconst cached = this._commitMessageCache.get(repoPath);\n\t\tif (cached?.sha === sha) return cached.message;\n\n\t\tconst result = await this.git.run(\n\t\t\t{ cwd: repoPath, cancellation: cancellation, errors: 'ignore' },\n\t\t\t'log',\n\t\t\t'-1',\n\t\t\t'--format=%B',\n\t\t\tsha,\n\t\t);\n\t\tconst message = result.stdout.trim() || undefined;\n\t\t// Don't cache a miss — a transient failure would otherwise stick for the operation's lifetime\n\t\tif (message != null) {\n\t\t\tthis._commitMessageCache.set(repoPath, { sha: sha, message: message });\n\t\t}\n\t\treturn message;\n\t}\n\n\tprivate async readDotGitFile(\n\t\tgitDir: GitDir,\n\t\tpathParts: string[],\n\t\toptions?: { numeric?: false; throw?: boolean; trim?: boolean },\n\t): Promise<string | undefined>;\n\tprivate async readDotGitFile(\n\t\tgitDir: GitDir,\n\t\tpathParts: string[],\n\t\toptions?: { numeric: true; throw?: boolean; trim?: boolean },\n\t): Promise<number | undefined>;\n\tprivate async readDotGitFile(\n\t\tgitDir: GitDir,\n\t\tpathParts: string[],\n\t\toptions?: { numeric?: boolean; throw?: boolean; trim?: boolean },\n\t): Promise<string | number | undefined> {\n\t\ttry {\n\t\t\tconst filePath = joinPaths(gitDir.uri.fsPath, ...pathParts);\n\t\t\tconst bytes = await readFile(filePath);\n\t\t\tlet contents = new TextDecoder('utf8').decode(bytes);\n\t\t\tcontents = (options?.trim ?? true) ? contents.trim() : contents;\n\n\t\t\tif (options?.numeric) {\n\t\t\t\tconst number = Number.parseInt(contents, 10);\n\t\t\t\treturn isNaN(number) ? undefined : number;\n\t\t\t}\n\n\t\t\treturn contents;\n\t\t} catch (ex) {\n\t\t\tif (options?.throw) throw ex;\n\n\t\t\treturn undefined;\n\t\t}\n\t}\n\n\t@gate((rp, o) => `${rp ?? ''}:${o?.quit ?? false}`)\n\t@debug()\n\tasync abortPausedOperation(repoPath: string, options?: { quit?: boolean }): Promise<void> {\n\t\tconst scope = getScopedLogger();\n\n\t\tconst status = await this.getPausedOperationStatus(repoPath);\n\t\tif (status == null) return;\n\n\t\tconst args = [status.type, options?.quit ? '--quit' : '--abort'];\n\n\t\ttry {\n\t\t\t// Unbounded like the operations it undoes — an abort of a large rebase can outrun the default\n\t\t\t// command timeout, and being SIGTERM'd partway through would leave the repo mid-abort.\n\t\t\tawait refreshIndexAfter(this.indexRefresher, repoPath, () =>\n\t\t\t\tthis.git.run({ cwd: repoPath, errors: 'throw', timeout: 0 }, ...args),\n\t\t\t);\n\t\t} catch (ex) {\n\t\t\tscope?.error(ex);\n\t\t\tthrow getGitCommandError(\n\t\t\t\t'paused-operation-abort',\n\t\t\t\tex,\n\t\t\t\treason =>\n\t\t\t\t\tnew PausedOperationAbortError(\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treason: reason,\n\t\t\t\t\t\t\toperation: status,\n\t\t\t\t\t\t\tgitCommand: { repoPath: repoPath, args: args },\n\t\t\t\t\t\t},\n\t\t\t\t\t\tex,\n\t\t\t\t\t),\n\t\t\t);\n\t\t} finally {\n\t\t\t// An abort that fails or is cancelled partway can still have moved HEAD or reset the working tree\n\t\t\tthis.context.hooks?.cache?.onReset?.(repoPath, 'branches', 'status');\n\t\t\tthis.context.hooks?.repository?.onChanged?.(repoPath, ['head', 'heads', 'index']);\n\t\t}\n\t}\n\n\t@debug()\n\tasync continuePausedOperation(\n\t\trepoPath: string,\n\t\toptions?: {\n\t\t\tallowEmpty?: boolean;\n\t\t\tskip?: boolean;\n\t\t\tmessageEditor?: string;\n\t\t\teditorEnv?: Record<string, string>;\n\t\t},\n\t): Promise<void> {\n\t\tconst scope = getScopedLogger();\n\n\t\tconst status = await this.getPausedOperationStatus(repoPath);\n\t\tif (status == null) return;\n\n\t\tif (status.type === 'merge' && options?.skip) {\n\t\t\tthrow new Error(l10n.t('Skipping a merge is not supported'));\n\t\t}\n\n\t\tconst args = [status.type, options?.skip ? '--skip' : '--continue'];\n\n\t\t// Continuing after a conflicted step can open the commit-message editor (merge-backend rebases,\n\t\t// cherry-picks, and reverts). `GIT_EDITOR` is what git honors for that step, so set it on the\n\t\t// environment; also set `core.editor` config as a fallback.\n\t\tconst configs: string[] = [];\n\t\tlet env: Record<string, string | undefined> | undefined;\n\t\tif (options?.messageEditor) {\n\t\t\tconfigs.push('-c', `core.editor=${options.messageEditor}`);\n\t\t\tenv = { ...options.editorEnv, GIT_EDITOR: options.messageEditor };\n\t\t}\n\n\t\ttry {\n\t\t\tif (options?.allowEmpty) {\n\t\t\t\tconst commitArgs = ['commit', '--allow-empty', '--no-edit'];\n\t\t\t\ttry {\n\t\t\t\t\t// Git won't record the empty commit on its own; making it explicitly (`--no-edit` reuses the\n\t\t\t\t\t// message git already prepared) is what lets the operation move past it.\n\t\t\t\t\tawait this.git.run({ cwd: repoPath, errors: 'throw' }, ...commitArgs);\n\t\t\t\t} catch (ex) {\n\t\t\t\t\tscope?.error(ex);\n\t\t\t\t\t// Same reason taxonomy, but attributed to the commit that actually failed\n\t\t\t\t\tthrow getGitCommandError(\n\t\t\t\t\t\t'paused-operation-continue',\n\t\t\t\t\t\tex,\n\t\t\t\t\t\treason =>\n\t\t\t\t\t\t\tnew PausedOperationContinueError(\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\treason: reason,\n\t\t\t\t\t\t\t\t\toperation: status,\n\t\t\t\t\t\t\t\t\tskip: false,\n\t\t\t\t\t\t\t\t\tgitCommand: { repoPath: repoPath, args: commitArgs },\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\tex,\n\t\t\t\t\t\t\t),\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tawait refreshIndexAfter(this.indexRefresher, repoPath, () =>\n\t\t\t\tthis.git.run(\n\t\t\t\t\t{\n\t\t\t\t\t\tcwd: repoPath,\n\t\t\t\t\t\terrors: 'throw',\n\t\t\t\t\t\tconfigs: configs,\n\t\t\t\t\t\tenv: env,\n\t\t\t\t\t\t// A `--continue` that opens the commit-message editor blocks for as long as the user leaves\n\t\t\t\t\t\t// that tab open, which is unbounded — the default `advanced.git.timeout` would SIGTERM it\n\t\t\t\t\t\t// mid-operation. The start paths (merge/rebase/revert) opt out for the same reason.\n\t\t\t\t\t\ttimeout: 0,\n\t\t\t\t\t\t// The runner dedups in-flight commands by args only — it ignores per-call `configs`/`env`.\n\t\t\t\t\t\t// A headless continue (with `GIT_EDITOR`) and a plain `--continue` would therefore collapse\n\t\t\t\t\t\t// into one execution, so the plain one could silently run headless (auto-accepting a commit\n\t\t\t\t\t\t// message) or the headless one could ride a plain continue and open an editor that hangs the\n\t\t\t\t\t\t// loop. Tag the headless variant so it can't share a pending command with the plain one.\n\t\t\t\t\t\tcorrelationKey: options?.messageEditor ? 'paused-op-continue-headless' : undefined,\n\t\t\t\t\t},\n\t\t\t\t\t...args,\n\t\t\t\t),\n\t\t\t);\n\t\t} catch (ex) {\n\t\t\tif (PausedOperationContinueError.is(ex)) throw ex;\n\n\t\t\tconst error = getGitCommandError(\n\t\t\t\t'paused-operation-continue',\n\t\t\t\tex,\n\t\t\t\treason =>\n\t\t\t\t\tnew PausedOperationContinueError(\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treason: reason,\n\t\t\t\t\t\t\toperation: status,\n\t\t\t\t\t\t\tskip: options?.skip ?? false,\n\t\t\t\t\t\t\tgitCommand: { repoPath: repoPath, args: args },\n\t\t\t\t\t\t},\n\t\t\t\t\t\tex,\n\t\t\t\t\t),\n\t\t\t);\n\n\t\t\t// An empty commit concludes a single-commit cherry-pick/revert outright, leaving its\n\t\t\t// `--continue` nothing to continue — the operation finished either way.\n\t\t\tif (!options?.allowEmpty || !PausedOperationContinueError.is(error, 'nothingToContinue')) {\n\t\t\t\tscope?.error(ex);\n\t\t\t\tthrow error;\n\t\t\t}\n\t\t} finally {\n\t\t\t// Notify unconditionally rather than only on success: a throwing `--continue` can still have\n\t\t\t// mutated the repo (committing the resolved step, then stopping on the NEXT step's conflict or\n\t\t\t// empty commit), and the error alone can't distinguish that from a no-op failure. Invalidating\n\t\t\t// after a genuine no-op only costs a re-read; not invalidating after a real advance leaves\n\t\t\t// consumers rendering a stale step.\n\t\t\tthis.context.hooks?.cache?.onReset?.(repoPath, 'branches', 'status');\n\t\t\tthis.context.hooks?.repository?.onChanged?.(repoPath, ['head', 'heads', 'index']);\n\t\t}\n\t}\n}\n"],"mappings":";;;;;;;;;;;;;;;AA+BA,MAAM,kBAAkB;AAMxB,MAAM,oBAAiC;CAAC;CAAgB;CAAgB;CAAS;CAAe;CAAU;AAAW;AAErH,MAAM,kBAAkB;CACvB,gBAAgB;EAAE,QAAQ;EAAQ,OAAO;CAAO;CAChD,gBAAgB;EAAE,QAAQ;EAAU,OAAO;CAAM;AAClD;AAEA,MAAM,mBAAkD;CACvD,eAAe,CAAC,CAAC,kBAAkB,CAAC;CACpC,OAAO,CAAC,CAAC,YAAY,CAAC;CACtB,QAAQ,CAAC,CAAC,aAAa,CAAC;CACxB,gBAAgB;EACf,CAAC,aAAa;EACd,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AA,GAAA,+BAAA,WAAA,2BAAA,IAAA"}
|
|
@@ -18,6 +18,7 @@ import { IntegrationAuthenticationProvider, IntegrationAuthenticationProviderDes
|
|
|
18
18
|
import { IssueTrackerCreateOptions, IssueTrackerCreateOptionsResult, IssueTrackerDeleteOptions, IssueTrackerField, IssueTrackerIssueReceipt, IssueTrackerIssueWriteOptions, IssueTrackerIssueWriteOptionsResult, IssueTrackerStatus, IssueTrackerTransition, IssueTrackerWriteConnection, IssueTrackerWriteFailure, IssueTrackerWriteOptions, IssueTrackerWriteResult, IssueTrackerWriteTargetOptions, IssueTrackerWriteTargetResult } from "./models/issueTrackerWrites.js";
|
|
19
19
|
import { AzureServerWorkItemWriteScope, AzureServicesWorkItemWriteScope, WorkItemAddress, WorkItemCreateOptions, WorkItemCreateOptionsResult, WorkItemDeleteCapability, WorkItemDeleteOptions, WorkItemDeleteResult, WorkItemDeleteTargetChanged, WorkItemDeletion, WorkItemReceipt, WorkItemState, WorkItemWriteContext, WorkItemWriteField, WorkItemWriteOptions, WorkItemWriteOptionsResult, WorkItemWriteResult, WorkItemWriteScope, WorkItemWriteTargetOptions, WorkItemWriteTargetResult } from "./models/workItemWrites.js";
|
|
20
20
|
import { AzurePullRequestCreateCapabilityOptions, AzurePullRequestCreateCapabilityResult, AzurePullRequestMergeStrategy, AzurePullRequestRepository, AzurePullRequestWriteAction, AzurePullRequestWriteFailure, AzurePullRequestWriteOptions, AzurePullRequestWriteResult, AzurePullRequestWriteTargetOptions, AzurePullRequestWriteTargetResult, AzureServerPullRequestWriteOptions, AzureServerPullRequestWriteScope, AzureServerPullRequestWriteTargetOptions, AzureWrittenPullRequest } from "./models/azurePullRequestWrites.js";
|
|
21
|
+
import { BitbucketPullRequestCreateCapabilityOptions, BitbucketPullRequestCreateCapabilityResult, BitbucketPullRequestMergeCapability, BitbucketPullRequestMergeStatusOptions, BitbucketPullRequestMergeStatusResult, BitbucketPullRequestMergeStrategy, BitbucketPullRequestRepository, BitbucketPullRequestWriteAction, BitbucketPullRequestWriteFailure, BitbucketPullRequestWriteOptions, BitbucketPullRequestWriteReleaseOptions, BitbucketPullRequestWriteReleaseResult, BitbucketPullRequestWriteResult, BitbucketPullRequestWriteTargetOptions, BitbucketPullRequestWriteTargetResult, BitbucketUnsettledPullRequestWrite, BitbucketWrittenPullRequest } from "./models/bitbucketPullRequestWrites.js";
|
|
21
22
|
import { CaptureRelationshipCurrency, IssueRelationshipFailure, IssueRelationshipPin, IssueRelationshipReceipt, IssueRelationshipWriteOptions, IssueRelationshipWriteResult, IssueRelationshipsOptions, IssueRelationshipsResult } from "./models/issueRelationships.js";
|
|
22
23
|
import { IssueFilter } from "./providerFilters.js";
|
|
23
24
|
import { IssueEtagInclude, PullRequestEtagInclude } from "./reads/etag.js";
|
|
@@ -108,5 +109,5 @@ export interface IntegrationManagerContext {
|
|
|
108
109
|
*/
|
|
109
110
|
export declare function createIntegrationManager(ctx: IntegrationManagerContext): IntegrationManager;
|
|
110
111
|
//#endregion
|
|
111
|
-
export { type Account, type AccountProvider, type ActionablePullRequest, type ActionablePullRequestAccount, ActionablePullRequestBuildStatusState, type ActionablePullRequestCategory, type ActionablePullRequestEnrichedItem, type ActionablePullRequestEnrichedItems, type ActionablePullRequestFields, type ActionablePullRequestInput, ActionablePullRequestReviewState, type AuthenticationSessionLike, type AuthenticationSessionsChangeEvent, type Autolink, type AutolinkReference, type AzurePullRequestCreateCapabilityOptions, type AzurePullRequestCreateCapabilityResult, type AzurePullRequestMergeStrategy, type AzurePullRequestRepository, type AzurePullRequestWriteAction, type AzurePullRequestWriteFailure, type AzurePullRequestWriteOptions, type AzurePullRequestWriteResult, type AzurePullRequestWriteTargetOptions, type AzurePullRequestWriteTargetResult, type AzureServerPullRequestWriteOptions, type AzureServerPullRequestWriteScope, type AzureServerPullRequestWriteTargetOptions, type AzureServerWorkItemWriteScope, type AzureServicesWorkItemWriteScope, type AzureWrittenPullRequest, type CaptureRelationshipCurrency, type ClosedPullRequestSweepOptions, type CloudIntegrationAuthType, type CloudIntegrationConnection, type CloudIntegrationType, type ConfigChangeEvent, type ConfigProvider, type ConfiguredIntegrationDescriptor, type ConfiguredIntegrationsChangeEvent, type ConnectionStateChangeEvent, type CurrentAccountResult, type DynamicAutolinkReference, type EntityIdentifier, type EntityIdentifierFields, type EntityIdentifierInput, EntityIdentifierProviderType, EntityType, EntityVersion, type FieldPresence, type GetAutolinkReferencesOptions, GitCloudHostIntegrationId, type GitConfigEntityIdentifier, type GitHostIntegration, GitSelfManagedHostIntegrationId, type HttpProvider, type Integration, type IntegrationAuthenticationProvider, type IntegrationAuthenticationProviderDescriptor, type IntegrationAuthenticationSessionDescriptor, type IntegrationById, type IntegrationCacheDescriptor, type IntegrationConnectedKey, type IntegrationCredential, type IntegrationIds, type IntegrationManager, type IntegrationResult, type IntegrationServiceHooks, type IntegrationStorageProvider, type IntegrationType, type IntegrationsRemoteConfig, type IssueBatchResult, type IssueBatchTarget, type IssueCountResult, type IssueCountScope, type IssueDeleteOptions, type IssueEtagInclude, type IssueFieldGroup, IssueFilter, type IssueProjection, type IssueRelationshipFailure, type IssueRelationshipPin, type IssueRelationshipReceipt, type IssueRelationshipWriteOptions, type IssueRelationshipWriteResult, type IssueRelationshipsOptions, type IssueRelationshipsResult, type IssueSearchCapabilities, type IssueSearchCriteria, type IssueSearchRelationship, type IssueStateFilter, type IssueTrackerCreateOptions, type IssueTrackerCreateOptionsResult, type IssueTrackerDeleteOptions, type IssueTrackerField, type IssueTrackerIssueReceipt, type IssueTrackerIssueWriteOptions, type IssueTrackerIssueWriteOptionsResult, type IssueTrackerStatus, type IssueTrackerTransition, type IssueTrackerWriteConnection, type IssueTrackerWriteFailure, type IssueTrackerWriteOptions, type IssueTrackerWriteResult, type IssueTrackerWriteTargetOptions, type IssueTrackerWriteTargetResult, type IssueWriteOptions, type IssueWriteResult, type IssueWriteTargetOptions, type IssueWriteTargetResult, IssuesCloudHostIntegrationId, type IssuesIntegration, IssuesSelfManagedHostIntegrationId, type ListLinearProjectsOptions, type ListOrgsOptions, type ListProjectsOptions, LookupBackedOffError, type ManualTokenAuthProviderOptions, type MyPullRequestsForReposOptions, type ProviderAuthenticationSession, type ProviderBroadenOrg, type ProviderBroadenResult, type ProviderLinearProjectShape, type ProviderMetadata, type ProviderOrganization, type ProviderPageInfo, type ProviderPagedResult, type ProviderPullRequestSearchResult, type ProviderReference, type ProviderRepositoriesInput, type ProviderRepositoryInput, type ProviderRepositoryShape, type ProviderResult, type ProviderSweepResult, type ProviderSweepTarget, type ProviderSweepTargetEvent, type ProviderSweepTargetRef, type ProviderWarning, type ProviderWarningCause, type ProviderWarningCauseReason, type ProviderWarningKind, type ProviderWarningOmission, type ProviderWarningOmissionKind, type ProviderWarningOmissionRecovery, type ProviderWarningOmissionScope, type ProviderWarningScope, type ProviderWarningSelector, type ProviderWarningUnreadableItems, type PullRequestActivityAuthor, type PullRequestActivityComment, type PullRequestActivityItem, type PullRequestActivityResult, type PullRequestActivityReview, type PullRequestActivityReviewComment, type PullRequestActivityTarget, type PullRequestBatchResult, type PullRequestBatchTarget, type PullRequestBranchResult, type PullRequestBranchTarget, type PullRequestCheckLogResult, type PullRequestCheckLogTarget, type PullRequestCountResult, type PullRequestCountScope, type PullRequestCreateCapabilityOptions, type PullRequestCreateCapabilityResult, type PullRequestEntityIdentifierInput, type PullRequestEtagInclude, type PullRequestFieldGroup, PullRequestFilter, type PullRequestForCommitResult, type PullRequestProjection, type PullRequestSearchCapabilities, type PullRequestSearchCriteria, type PullRequestStateFilter, type PullRequestSweepOptions, type PullRequestWriteFailure, type PullRequestWriteOptions, type PullRequestWriteResult, type PullRequestWriteSnapshot, type PullRequestWriteTargetOptions, type PullRequestWriteTargetResult, type RefSet, type RepositoriesProvider, type RepositoryIdentity, type RepositoryResolution, type RepositoryResolutionStatus, type ResolveRepositoryResult, type SearchMyPullRequestsOptions, type SearchPullRequestsOptions, type Source, type Sources, type SupportedCloudIntegrationIds, type TokenInfo, type WorkItemAddress, type WorkItemCreateOptions, type WorkItemCreateOptionsResult, type WorkItemDeleteCapability, type WorkItemDeleteOptions, type WorkItemDeleteResult, type WorkItemDeleteTargetChanged, type WorkItemDeletion, type WorkItemReceipt, type WorkItemState, type WorkItemWriteContext, type WorkItemWriteField, type WorkItemWriteOptions, type WorkItemWriteOptionsResult, type WorkItemWriteResult, type WorkItemWriteScope, type WorkItemWriteTargetOptions, type WorkItemWriteTargetResult, areDomainsOnSameHost, convertRemoteProviderIdToIntegrationId, createManualTokenAuthProvider, decodeEntityIdentifier, decodeEntityIdentifiersFromGitConfig, encodeEntityIdentifier, encodeIssueOrPullRequestForGitConfig, getActionablePullRequests, getAzureRepositoryIdentity, getEntityIdentifierInput, getIntegrationConnectedKey, getIntegrationIdForRemote, getIssueFieldPresence, getIssueFromGitConfigEntityIdentifier, getIssueOwner, getProviderIdFromEntityIdentifier, getPullRequestFieldPresence, getSingleConfiguredDomain, hostFromDomain, isAzureProviderId, isCloudGitSelfManagedHostIntegrationId, isGitCloudHostIntegrationId, isGitHostIntegration, isGitSelfManagedHostIntegrationId, isIntegration, isIntegrationId, isIssuesHostIntegrationId, isIssuesIntegration, isMaybeGitLabPullRequestUrl, isSelfManagedHostIntegrationId, isSupportedCloudIntegrationId, providersMetadata, splitOwnerAndRepo, supportsCodeSuggest, toActionablePullRequestInput, toCloudIntegrationType, toIntegrationId, toTokenInfo, toTokenWithInfo };
|
|
112
|
+
export { type Account, type AccountProvider, type ActionablePullRequest, type ActionablePullRequestAccount, ActionablePullRequestBuildStatusState, type ActionablePullRequestCategory, type ActionablePullRequestEnrichedItem, type ActionablePullRequestEnrichedItems, type ActionablePullRequestFields, type ActionablePullRequestInput, ActionablePullRequestReviewState, type AuthenticationSessionLike, type AuthenticationSessionsChangeEvent, type Autolink, type AutolinkReference, type AzurePullRequestCreateCapabilityOptions, type AzurePullRequestCreateCapabilityResult, type AzurePullRequestMergeStrategy, type AzurePullRequestRepository, type AzurePullRequestWriteAction, type AzurePullRequestWriteFailure, type AzurePullRequestWriteOptions, type AzurePullRequestWriteResult, type AzurePullRequestWriteTargetOptions, type AzurePullRequestWriteTargetResult, type AzureServerPullRequestWriteOptions, type AzureServerPullRequestWriteScope, type AzureServerPullRequestWriteTargetOptions, type AzureServerWorkItemWriteScope, type AzureServicesWorkItemWriteScope, type AzureWrittenPullRequest, type BitbucketPullRequestCreateCapabilityOptions, type BitbucketPullRequestCreateCapabilityResult, type BitbucketPullRequestMergeCapability, type BitbucketPullRequestMergeStatusOptions, type BitbucketPullRequestMergeStatusResult, type BitbucketPullRequestMergeStrategy, type BitbucketPullRequestRepository, type BitbucketPullRequestWriteAction, type BitbucketPullRequestWriteFailure, type BitbucketPullRequestWriteOptions, type BitbucketPullRequestWriteReleaseOptions, type BitbucketPullRequestWriteReleaseResult, type BitbucketPullRequestWriteResult, type BitbucketPullRequestWriteTargetOptions, type BitbucketPullRequestWriteTargetResult, type BitbucketUnsettledPullRequestWrite, type BitbucketWrittenPullRequest, type CaptureRelationshipCurrency, type ClosedPullRequestSweepOptions, type CloudIntegrationAuthType, type CloudIntegrationConnection, type CloudIntegrationType, type ConfigChangeEvent, type ConfigProvider, type ConfiguredIntegrationDescriptor, type ConfiguredIntegrationsChangeEvent, type ConnectionStateChangeEvent, type CurrentAccountResult, type DynamicAutolinkReference, type EntityIdentifier, type EntityIdentifierFields, type EntityIdentifierInput, EntityIdentifierProviderType, EntityType, EntityVersion, type FieldPresence, type GetAutolinkReferencesOptions, GitCloudHostIntegrationId, type GitConfigEntityIdentifier, type GitHostIntegration, GitSelfManagedHostIntegrationId, type HttpProvider, type Integration, type IntegrationAuthenticationProvider, type IntegrationAuthenticationProviderDescriptor, type IntegrationAuthenticationSessionDescriptor, type IntegrationById, type IntegrationCacheDescriptor, type IntegrationConnectedKey, type IntegrationCredential, type IntegrationIds, type IntegrationManager, type IntegrationResult, type IntegrationServiceHooks, type IntegrationStorageProvider, type IntegrationType, type IntegrationsRemoteConfig, type IssueBatchResult, type IssueBatchTarget, type IssueCountResult, type IssueCountScope, type IssueDeleteOptions, type IssueEtagInclude, type IssueFieldGroup, IssueFilter, type IssueProjection, type IssueRelationshipFailure, type IssueRelationshipPin, type IssueRelationshipReceipt, type IssueRelationshipWriteOptions, type IssueRelationshipWriteResult, type IssueRelationshipsOptions, type IssueRelationshipsResult, type IssueSearchCapabilities, type IssueSearchCriteria, type IssueSearchRelationship, type IssueStateFilter, type IssueTrackerCreateOptions, type IssueTrackerCreateOptionsResult, type IssueTrackerDeleteOptions, type IssueTrackerField, type IssueTrackerIssueReceipt, type IssueTrackerIssueWriteOptions, type IssueTrackerIssueWriteOptionsResult, type IssueTrackerStatus, type IssueTrackerTransition, type IssueTrackerWriteConnection, type IssueTrackerWriteFailure, type IssueTrackerWriteOptions, type IssueTrackerWriteResult, type IssueTrackerWriteTargetOptions, type IssueTrackerWriteTargetResult, type IssueWriteOptions, type IssueWriteResult, type IssueWriteTargetOptions, type IssueWriteTargetResult, IssuesCloudHostIntegrationId, type IssuesIntegration, IssuesSelfManagedHostIntegrationId, type ListLinearProjectsOptions, type ListOrgsOptions, type ListProjectsOptions, LookupBackedOffError, type ManualTokenAuthProviderOptions, type MyPullRequestsForReposOptions, type ProviderAuthenticationSession, type ProviderBroadenOrg, type ProviderBroadenResult, type ProviderLinearProjectShape, type ProviderMetadata, type ProviderOrganization, type ProviderPageInfo, type ProviderPagedResult, type ProviderPullRequestSearchResult, type ProviderReference, type ProviderRepositoriesInput, type ProviderRepositoryInput, type ProviderRepositoryShape, type ProviderResult, type ProviderSweepResult, type ProviderSweepTarget, type ProviderSweepTargetEvent, type ProviderSweepTargetRef, type ProviderWarning, type ProviderWarningCause, type ProviderWarningCauseReason, type ProviderWarningKind, type ProviderWarningOmission, type ProviderWarningOmissionKind, type ProviderWarningOmissionRecovery, type ProviderWarningOmissionScope, type ProviderWarningScope, type ProviderWarningSelector, type ProviderWarningUnreadableItems, type PullRequestActivityAuthor, type PullRequestActivityComment, type PullRequestActivityItem, type PullRequestActivityResult, type PullRequestActivityReview, type PullRequestActivityReviewComment, type PullRequestActivityTarget, type PullRequestBatchResult, type PullRequestBatchTarget, type PullRequestBranchResult, type PullRequestBranchTarget, type PullRequestCheckLogResult, type PullRequestCheckLogTarget, type PullRequestCountResult, type PullRequestCountScope, type PullRequestCreateCapabilityOptions, type PullRequestCreateCapabilityResult, type PullRequestEntityIdentifierInput, type PullRequestEtagInclude, type PullRequestFieldGroup, PullRequestFilter, type PullRequestForCommitResult, type PullRequestProjection, type PullRequestSearchCapabilities, type PullRequestSearchCriteria, type PullRequestStateFilter, type PullRequestSweepOptions, type PullRequestWriteFailure, type PullRequestWriteOptions, type PullRequestWriteResult, type PullRequestWriteSnapshot, type PullRequestWriteTargetOptions, type PullRequestWriteTargetResult, type RefSet, type RepositoriesProvider, type RepositoryIdentity, type RepositoryResolution, type RepositoryResolutionStatus, type ResolveRepositoryResult, type SearchMyPullRequestsOptions, type SearchPullRequestsOptions, type Source, type Sources, type SupportedCloudIntegrationIds, type TokenInfo, type WorkItemAddress, type WorkItemCreateOptions, type WorkItemCreateOptionsResult, type WorkItemDeleteCapability, type WorkItemDeleteOptions, type WorkItemDeleteResult, type WorkItemDeleteTargetChanged, type WorkItemDeletion, type WorkItemReceipt, type WorkItemState, type WorkItemWriteContext, type WorkItemWriteField, type WorkItemWriteOptions, type WorkItemWriteOptionsResult, type WorkItemWriteResult, type WorkItemWriteScope, type WorkItemWriteTargetOptions, type WorkItemWriteTargetResult, areDomainsOnSameHost, convertRemoteProviderIdToIntegrationId, createManualTokenAuthProvider, decodeEntityIdentifier, decodeEntityIdentifiersFromGitConfig, encodeEntityIdentifier, encodeIssueOrPullRequestForGitConfig, getActionablePullRequests, getAzureRepositoryIdentity, getEntityIdentifierInput, getIntegrationConnectedKey, getIntegrationIdForRemote, getIssueFieldPresence, getIssueFromGitConfigEntityIdentifier, getIssueOwner, getProviderIdFromEntityIdentifier, getPullRequestFieldPresence, getSingleConfiguredDomain, hostFromDomain, isAzureProviderId, isCloudGitSelfManagedHostIntegrationId, isGitCloudHostIntegrationId, isGitHostIntegration, isGitSelfManagedHostIntegrationId, isIntegration, isIntegrationId, isIssuesHostIntegrationId, isIssuesIntegration, isMaybeGitLabPullRequestUrl, isSelfManagedHostIntegrationId, isSupportedCloudIntegrationId, providersMetadata, splitOwnerAndRepo, supportsCodeSuggest, toActionablePullRequestInput, toCloudIntegrationType, toIntegrationId, toTokenInfo, toTokenWithInfo };
|
|
112
113
|
//# sourceMappingURL=index.d.ts.map
|