open-azdo 0.2.0 → 0.2.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/dist/open-azdo.js
CHANGED
|
@@ -46650,27 +46650,37 @@ var PullRequestMetadataSchema = exports_Schema.Struct({
|
|
|
46650
46650
|
description: exports_Schema.String,
|
|
46651
46651
|
url: exports_Schema.optionalKey(exports_Schema.String)
|
|
46652
46652
|
});
|
|
46653
|
+
var ExistingThreadStatusSchema = exports_Schema.Union([
|
|
46654
|
+
exports_Schema.Int,
|
|
46655
|
+
exports_Schema.Literal("active"),
|
|
46656
|
+
exports_Schema.Literal("fixed"),
|
|
46657
|
+
exports_Schema.Literal("wontFix"),
|
|
46658
|
+
exports_Schema.Literal("closed"),
|
|
46659
|
+
exports_Schema.Literal("byDesign"),
|
|
46660
|
+
exports_Schema.Literal("pending")
|
|
46661
|
+
]);
|
|
46662
|
+
var NullableIntSchema = exports_Schema.Union([exports_Schema.Int, exports_Schema.Null]);
|
|
46653
46663
|
var ExistingThreadSchema = exports_Schema.Struct({
|
|
46654
46664
|
id: exports_Schema.Int,
|
|
46655
|
-
status:
|
|
46665
|
+
status: ExistingThreadStatusSchema,
|
|
46656
46666
|
comments: exports_Schema.Array(exports_Schema.Struct({
|
|
46657
46667
|
id: exports_Schema.Int,
|
|
46658
|
-
content: exports_Schema.optionalKey(exports_Schema.String)
|
|
46668
|
+
content: exports_Schema.optionalKey(exports_Schema.Union([exports_Schema.String, exports_Schema.Null]))
|
|
46659
46669
|
})),
|
|
46660
46670
|
threadContext: exports_Schema.optionalKey(exports_Schema.Struct({
|
|
46661
46671
|
filePath: exports_Schema.optionalKey(exports_Schema.String),
|
|
46662
46672
|
rightFileStart: exports_Schema.optionalKey(exports_Schema.Struct({
|
|
46663
|
-
line: exports_Schema.optionalKey(
|
|
46664
|
-
offset: exports_Schema.optionalKey(
|
|
46673
|
+
line: exports_Schema.optionalKey(NullableIntSchema),
|
|
46674
|
+
offset: exports_Schema.optionalKey(NullableIntSchema)
|
|
46665
46675
|
})),
|
|
46666
46676
|
rightFileEnd: exports_Schema.optionalKey(exports_Schema.Struct({
|
|
46667
|
-
line: exports_Schema.optionalKey(
|
|
46668
|
-
offset: exports_Schema.optionalKey(
|
|
46677
|
+
line: exports_Schema.optionalKey(NullableIntSchema),
|
|
46678
|
+
offset: exports_Schema.optionalKey(NullableIntSchema)
|
|
46669
46679
|
}))
|
|
46670
46680
|
}))
|
|
46671
46681
|
});
|
|
46672
46682
|
var ExistingThreadsResponseSchema = exports_Schema.Struct({
|
|
46673
|
-
value: exports_Schema.Array(ExistingThreadSchema)
|
|
46683
|
+
value: exports_Schema.optionalKey(exports_Schema.Array(ExistingThreadSchema))
|
|
46674
46684
|
});
|
|
46675
46685
|
|
|
46676
46686
|
// ../../packages/azdo/src/Layers/AzureDevOpsClient.ts
|
|
@@ -47478,6 +47488,7 @@ var ManagedReviewStateSchema = exports_Schema.Struct({
|
|
|
47478
47488
|
inlineFindingsCount: exports_Schema.Int,
|
|
47479
47489
|
unmappedNotesCount: exports_Schema.Int
|
|
47480
47490
|
});
|
|
47491
|
+
var isActiveThreadStatus = (status) => status === 1 || status === "active" || status === "pending";
|
|
47481
47492
|
var STATE_SCHEMA_VERSION = 1;
|
|
47482
47493
|
var FINDING_MARKER_PREFIX = "<!-- open-azdo:";
|
|
47483
47494
|
var SUMMARY_STATE_PREFIX = "<!-- open-azdo-review:";
|
|
@@ -47631,7 +47642,7 @@ var mergeFollowUpReviewResult = ({
|
|
|
47631
47642
|
scopedDeletedLinesByFile,
|
|
47632
47643
|
reviewResult
|
|
47633
47644
|
}) => {
|
|
47634
|
-
const carriedForwardFindings = listManagedFindingThreads(existingThreads).filter((existingThread) => existingThread.thread.status
|
|
47645
|
+
const carriedForwardFindings = listManagedFindingThreads(existingThreads).filter((existingThread) => isActiveThreadStatus(existingThread.thread.status)).filter((existingThread) => !findingTouchesScopedDiff(existingThread.finding, scopedChangedLinesByFile, scopedDeletedLinesByFile)).map((existingThread) => existingThread.finding);
|
|
47635
47646
|
if (carriedForwardFindings.length === 0) {
|
|
47636
47647
|
return reviewResult;
|
|
47637
47648
|
}
|
|
@@ -48426,7 +48437,7 @@ var reviewCommandConfig = {
|
|
|
48426
48437
|
var reviewCommand = make33("review", reviewCommandConfig).pipe(withDescription3("Review an Azure DevOps pull request with OpenCode."), withHandler((input) => runReviewCommand(input)));
|
|
48427
48438
|
var openAzdoCli = make33("open-azdo").pipe(withDescription3("Secure Azure DevOps pull-request review CLI powered by OpenCode."), withSubcommands([reviewCommand]));
|
|
48428
48439
|
// package.json
|
|
48429
|
-
var version2 = "0.2.
|
|
48440
|
+
var version2 = "0.2.1";
|
|
48430
48441
|
|
|
48431
48442
|
// src/Main.ts
|
|
48432
48443
|
var cliProgram = run3(openAzdoCli, { version: version2 }).pipe(exports_Effect.scoped, exports_Effect.provide(BaseRuntimeLayer));
|
|
@@ -48435,4 +48446,4 @@ var main = () => runMain2(cliProgram, { disableErrorReporting: true });
|
|
|
48435
48446
|
// bin/open-azdo.ts
|
|
48436
48447
|
main();
|
|
48437
48448
|
|
|
48438
|
-
//# debugId=
|
|
48449
|
+
//# debugId=168E0BF81544E90D64756E2164756E21
|