chief-clancy 0.7.0 → 0.7.2
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/README.md +4 -1
- package/dist/bundle/clancy-once.js +50 -50
- package/package.json +5 -2
- package/src/roles/planner/commands/approve-plan.md +3 -0
- package/src/roles/planner/commands/plan.md +1 -0
- package/src/roles/planner/workflows/approve-plan.md +3 -1
- package/src/roles/planner/workflows/plan.md +5 -5
- package/src/roles/strategist/commands/approve-brief.md +1 -0
- package/src/roles/strategist/workflows/approve-brief.md +3 -1
- package/src/roles/strategist/workflows/brief.md +38 -20
- package/src/templates/.env.example.github +19 -1
- package/src/templates/.env.example.jira +25 -1
- package/src/templates/.env.example.linear +19 -1
- package/dist/schemas/bitbucket-pr.d.ts +0 -137
- package/dist/schemas/bitbucket-pr.d.ts.map +0 -1
- package/dist/schemas/bitbucket-pr.js +0 -75
- package/dist/schemas/bitbucket-pr.js.map +0 -1
- package/dist/schemas/env.d.ts +0 -170
- package/dist/schemas/env.d.ts.map +0 -1
- package/dist/schemas/env.js +0 -69
- package/dist/schemas/env.js.map +0 -1
- package/dist/schemas/github-issues.d.ts +0 -105
- package/dist/schemas/github-issues.d.ts.map +0 -1
- package/dist/schemas/github-issues.js +0 -54
- package/dist/schemas/github-issues.js.map +0 -1
- package/dist/schemas/gitlab-mr.d.ts +0 -73
- package/dist/schemas/gitlab-mr.d.ts.map +0 -1
- package/dist/schemas/gitlab-mr.js +0 -33
- package/dist/schemas/gitlab-mr.js.map +0 -1
- package/dist/schemas/jira.d.ts +0 -59
- package/dist/schemas/jira.d.ts.map +0 -1
- package/dist/schemas/jira.js +0 -56
- package/dist/schemas/jira.js.map +0 -1
- package/dist/schemas/linear.d.ts +0 -108
- package/dist/schemas/linear.d.ts.map +0 -1
- package/dist/schemas/linear.js +0 -84
- package/dist/schemas/linear.js.map +0 -1
- package/dist/scripts/afk/afk.d.ts +0 -21
- package/dist/scripts/afk/afk.d.ts.map +0 -1
- package/dist/scripts/afk/afk.js +0 -145
- package/dist/scripts/afk/afk.js.map +0 -1
- package/dist/scripts/afk/report/report.d.ts +0 -47
- package/dist/scripts/afk/report/report.d.ts.map +0 -1
- package/dist/scripts/afk/report/report.js +0 -194
- package/dist/scripts/afk/report/report.js.map +0 -1
- package/dist/scripts/board/github/github.d.ts +0 -104
- package/dist/scripts/board/github/github.d.ts.map +0 -1
- package/dist/scripts/board/github/github.js +0 -291
- package/dist/scripts/board/github/github.js.map +0 -1
- package/dist/scripts/board/jira/jira.d.ts +0 -139
- package/dist/scripts/board/jira/jira.d.ts.map +0 -1
- package/dist/scripts/board/jira/jira.js +0 -378
- package/dist/scripts/board/jira/jira.js.map +0 -1
- package/dist/scripts/board/linear/linear.d.ts +0 -129
- package/dist/scripts/board/linear/linear.d.ts.map +0 -1
- package/dist/scripts/board/linear/linear.js +0 -393
- package/dist/scripts/board/linear/linear.js.map +0 -1
- package/dist/scripts/once/board-ops/board-ops.d.ts +0 -26
- package/dist/scripts/once/board-ops/board-ops.d.ts.map +0 -1
- package/dist/scripts/once/board-ops/board-ops.js +0 -113
- package/dist/scripts/once/board-ops/board-ops.js.map +0 -1
- package/dist/scripts/once/cost/cost.d.ts +0 -10
- package/dist/scripts/once/cost/cost.d.ts.map +0 -1
- package/dist/scripts/once/cost/cost.js +0 -23
- package/dist/scripts/once/cost/cost.js.map +0 -1
- package/dist/scripts/once/deliver/deliver.d.ts +0 -37
- package/dist/scripts/once/deliver/deliver.d.ts.map +0 -1
- package/dist/scripts/once/deliver/deliver.js +0 -253
- package/dist/scripts/once/deliver/deliver.js.map +0 -1
- package/dist/scripts/once/fetch-ticket/fetch-ticket.d.ts +0 -22
- package/dist/scripts/once/fetch-ticket/fetch-ticket.d.ts.map +0 -1
- package/dist/scripts/once/fetch-ticket/fetch-ticket.js +0 -123
- package/dist/scripts/once/fetch-ticket/fetch-ticket.js.map +0 -1
- package/dist/scripts/once/git-token/git-token.d.ts +0 -13
- package/dist/scripts/once/git-token/git-token.d.ts.map +0 -1
- package/dist/scripts/once/git-token/git-token.js +0 -30
- package/dist/scripts/once/git-token/git-token.js.map +0 -1
- package/dist/scripts/once/lock/lock.d.ts +0 -17
- package/dist/scripts/once/lock/lock.d.ts.map +0 -1
- package/dist/scripts/once/lock/lock.js +0 -70
- package/dist/scripts/once/lock/lock.js.map +0 -1
- package/dist/scripts/once/once.d.ts +0 -12
- package/dist/scripts/once/once.d.ts.map +0 -1
- package/dist/scripts/once/once.js +0 -452
- package/dist/scripts/once/once.js.map +0 -1
- package/dist/scripts/once/pr-creation/pr-creation.d.ts +0 -11
- package/dist/scripts/once/pr-creation/pr-creation.d.ts.map +0 -1
- package/dist/scripts/once/pr-creation/pr-creation.js +0 -50
- package/dist/scripts/once/pr-creation/pr-creation.js.map +0 -1
- package/dist/scripts/once/resume/resume.d.ts +0 -24
- package/dist/scripts/once/resume/resume.d.ts.map +0 -1
- package/dist/scripts/once/resume/resume.js +0 -159
- package/dist/scripts/once/resume/resume.js.map +0 -1
- package/dist/scripts/once/rework/rework.d.ts +0 -32
- package/dist/scripts/once/rework/rework.d.ts.map +0 -1
- package/dist/scripts/once/rework/rework.js +0 -208
- package/dist/scripts/once/rework/rework.js.map +0 -1
- package/dist/scripts/once/types/types.d.ts +0 -13
- package/dist/scripts/once/types/types.d.ts.map +0 -1
- package/dist/scripts/once/types/types.js +0 -2
- package/dist/scripts/once/types/types.js.map +0 -1
- package/dist/scripts/shared/branch/branch.d.ts +0 -50
- package/dist/scripts/shared/branch/branch.d.ts.map +0 -1
- package/dist/scripts/shared/branch/branch.js +0 -61
- package/dist/scripts/shared/branch/branch.js.map +0 -1
- package/dist/scripts/shared/claude-cli/claude-cli.d.ts +0 -31
- package/dist/scripts/shared/claude-cli/claude-cli.d.ts.map +0 -1
- package/dist/scripts/shared/claude-cli/claude-cli.js +0 -60
- package/dist/scripts/shared/claude-cli/claude-cli.js.map +0 -1
- package/dist/scripts/shared/env-schema/env-schema.d.ts +0 -27
- package/dist/scripts/shared/env-schema/env-schema.d.ts.map +0 -1
- package/dist/scripts/shared/env-schema/env-schema.js +0 -47
- package/dist/scripts/shared/env-schema/env-schema.js.map +0 -1
- package/dist/scripts/shared/feasibility/feasibility.d.ts +0 -30
- package/dist/scripts/shared/feasibility/feasibility.d.ts.map +0 -1
- package/dist/scripts/shared/feasibility/feasibility.js +0 -68
- package/dist/scripts/shared/feasibility/feasibility.js.map +0 -1
- package/dist/scripts/shared/format/format.d.ts +0 -11
- package/dist/scripts/shared/format/format.d.ts.map +0 -1
- package/dist/scripts/shared/format/format.js +0 -23
- package/dist/scripts/shared/format/format.js.map +0 -1
- package/dist/scripts/shared/git-ops/git-ops.d.ts +0 -90
- package/dist/scripts/shared/git-ops/git-ops.d.ts.map +0 -1
- package/dist/scripts/shared/git-ops/git-ops.js +0 -190
- package/dist/scripts/shared/git-ops/git-ops.js.map +0 -1
- package/dist/scripts/shared/http/http.d.ts +0 -54
- package/dist/scripts/shared/http/http.d.ts.map +0 -1
- package/dist/scripts/shared/http/http.js +0 -76
- package/dist/scripts/shared/http/http.js.map +0 -1
- package/dist/scripts/shared/notify/notify.d.ts +0 -46
- package/dist/scripts/shared/notify/notify.d.ts.map +0 -1
- package/dist/scripts/shared/notify/notify.js +0 -88
- package/dist/scripts/shared/notify/notify.js.map +0 -1
- package/dist/scripts/shared/preflight/preflight.d.ts +0 -40
- package/dist/scripts/shared/preflight/preflight.d.ts.map +0 -1
- package/dist/scripts/shared/preflight/preflight.js +0 -96
- package/dist/scripts/shared/preflight/preflight.js.map +0 -1
- package/dist/scripts/shared/progress/progress.d.ts +0 -88
- package/dist/scripts/shared/progress/progress.d.ts.map +0 -1
- package/dist/scripts/shared/progress/progress.js +0 -210
- package/dist/scripts/shared/progress/progress.js.map +0 -1
- package/dist/scripts/shared/prompt/prompt.d.ts +0 -58
- package/dist/scripts/shared/prompt/prompt.d.ts.map +0 -1
- package/dist/scripts/shared/prompt/prompt.js +0 -123
- package/dist/scripts/shared/prompt/prompt.js.map +0 -1
- package/dist/scripts/shared/pull-request/bitbucket/bitbucket.d.ts +0 -82
- package/dist/scripts/shared/pull-request/bitbucket/bitbucket.d.ts.map +0 -1
- package/dist/scripts/shared/pull-request/bitbucket/bitbucket.js +0 -301
- package/dist/scripts/shared/pull-request/bitbucket/bitbucket.js.map +0 -1
- package/dist/scripts/shared/pull-request/github/github.d.ts +0 -72
- package/dist/scripts/shared/pull-request/github/github.d.ts.map +0 -1
- package/dist/scripts/shared/pull-request/github/github.js +0 -226
- package/dist/scripts/shared/pull-request/github/github.js.map +0 -1
- package/dist/scripts/shared/pull-request/gitlab/gitlab.d.ts +0 -74
- package/dist/scripts/shared/pull-request/gitlab/gitlab.d.ts.map +0 -1
- package/dist/scripts/shared/pull-request/gitlab/gitlab.js +0 -220
- package/dist/scripts/shared/pull-request/gitlab/gitlab.js.map +0 -1
- package/dist/scripts/shared/pull-request/post-pr/post-pr.d.ts +0 -31
- package/dist/scripts/shared/pull-request/post-pr/post-pr.d.ts.map +0 -1
- package/dist/scripts/shared/pull-request/post-pr/post-pr.js +0 -61
- package/dist/scripts/shared/pull-request/post-pr/post-pr.js.map +0 -1
- package/dist/scripts/shared/pull-request/pr-body/pr-body.d.ts +0 -41
- package/dist/scripts/shared/pull-request/pr-body/pr-body.d.ts.map +0 -1
- package/dist/scripts/shared/pull-request/pr-body/pr-body.js +0 -93
- package/dist/scripts/shared/pull-request/pr-body/pr-body.js.map +0 -1
- package/dist/scripts/shared/pull-request/rework-comment/rework-comment.d.ts +0 -23
- package/dist/scripts/shared/pull-request/rework-comment/rework-comment.d.ts.map +0 -1
- package/dist/scripts/shared/pull-request/rework-comment/rework-comment.js +0 -30
- package/dist/scripts/shared/pull-request/rework-comment/rework-comment.js.map +0 -1
- package/dist/scripts/shared/remote/remote.d.ts +0 -41
- package/dist/scripts/shared/remote/remote.d.ts.map +0 -1
- package/dist/scripts/shared/remote/remote.js +0 -227
- package/dist/scripts/shared/remote/remote.js.map +0 -1
- package/dist/types/board.d.ts +0 -13
- package/dist/types/board.d.ts.map +0 -1
- package/dist/types/board.js +0 -5
- package/dist/types/board.js.map +0 -1
- package/dist/types/index.d.ts +0 -4
- package/dist/types/index.d.ts.map +0 -1
- package/dist/types/index.js +0 -2
- package/dist/types/index.js.map +0 -1
- package/dist/types/remote.d.ts +0 -55
- package/dist/types/remote.d.ts.map +0 -1
- package/dist/types/remote.js +0 -5
- package/dist/types/remote.js.map +0 -1
- package/dist/utils/parse-json/parse-json.d.ts +0 -20
- package/dist/utils/parse-json/parse-json.d.ts.map +0 -1
- package/dist/utils/parse-json/parse-json.js +0 -27
- package/dist/utils/parse-json/parse-json.js.map +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"progress.js","sourceRoot":"","sources":["../../../../src/scripts/shared/progress/progress.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAAE,cAAc,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAClE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAc1C;;;;;GAKG;AACH,MAAM,UAAU,eAAe,CAAC,IAAU;IACxC,MAAM,CAAC,GAAG,IAAI,CAAC,cAAc,EAAE,CAAC;IAChC,MAAM,EAAE,GAAG,MAAM,CAAC,IAAI,CAAC,WAAW,EAAE,GAAG,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC;IAC3D,MAAM,CAAC,GAAG,MAAM,CAAC,IAAI,CAAC,UAAU,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC;IACrD,MAAM,CAAC,GAAG,MAAM,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC;IACtD,MAAM,EAAE,GAAG,MAAM,CAAC,IAAI,CAAC,aAAa,EAAE,CAAC,CAAC,QAAQ,CAAC,CA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MAAM,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,MAAM,KAAK,MAAM,CAAC,CAAC;AAC9E,CAAC"}
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Claude prompt builder for ticket implementation.
|
|
3
|
-
*
|
|
4
|
-
* Generates the full prompt string piped to `claude --dangerously-skip-permissions`.
|
|
5
|
-
* The prompt structure matches the original shell scripts exactly.
|
|
6
|
-
*/
|
|
7
|
-
import type { BoardProvider } from '../../../types/index.js';
|
|
8
|
-
type PromptInput = {
|
|
9
|
-
provider: BoardProvider;
|
|
10
|
-
key: string;
|
|
11
|
-
title: string;
|
|
12
|
-
description: string;
|
|
13
|
-
/** Epic/milestone/parent info string (e.g., `'PROJ-100'`, `'Sprint 3'`, `'none'`). */
|
|
14
|
-
parentInfo: string;
|
|
15
|
-
/** Blocker info string (e.g., `'Blocked by: PROJ-99, PROJ-98'` or `'None'`). */
|
|
16
|
-
blockers?: string;
|
|
17
|
-
/** When true, enforce test-driven development (red-green-refactor). */
|
|
18
|
-
tdd?: boolean;
|
|
19
|
-
};
|
|
20
|
-
/** Input for building a rework prompt from reviewer feedback. */
|
|
21
|
-
export type ReworkPromptInput = {
|
|
22
|
-
key: string;
|
|
23
|
-
title: string;
|
|
24
|
-
description: string;
|
|
25
|
-
provider: BoardProvider;
|
|
26
|
-
feedbackComments: string[];
|
|
27
|
-
/** Git diff or git log output from the previous implementation. */
|
|
28
|
-
previousContext?: string;
|
|
29
|
-
/** When true, enforce test-driven development (red-green-refactor). */
|
|
30
|
-
tdd?: boolean;
|
|
31
|
-
};
|
|
32
|
-
/**
|
|
33
|
-
* Build the Claude prompt for reworking a ticket based on reviewer feedback.
|
|
34
|
-
*
|
|
35
|
-
* @param input - The rework ticket data and feedback.
|
|
36
|
-
* @returns The complete rework prompt string.
|
|
37
|
-
*
|
|
38
|
-
* @example
|
|
39
|
-
* ```ts
|
|
40
|
-
* const prompt = buildReworkPrompt({
|
|
41
|
-
* key: 'PROJ-123',
|
|
42
|
-
* title: 'Add login page',
|
|
43
|
-
* description: 'Create a login page with email/password fields.',
|
|
44
|
-
* provider: 'jira',
|
|
45
|
-
* feedbackComments: ['Button colour is wrong', 'Missing validation'],
|
|
46
|
-
* });
|
|
47
|
-
* ```
|
|
48
|
-
*/
|
|
49
|
-
export declare function buildReworkPrompt(input: ReworkPromptInput): string;
|
|
50
|
-
/**
|
|
51
|
-
* Build the full Claude prompt for implementing a ticket.
|
|
52
|
-
*
|
|
53
|
-
* @param input - The ticket data for the prompt.
|
|
54
|
-
* @returns The complete prompt string.
|
|
55
|
-
*/
|
|
56
|
-
export declare function buildPrompt(input: PromptInput): string;
|
|
57
|
-
export {};
|
|
58
|
-
//# sourceMappingURL=prompt.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"prompt.d.ts","sourceRoot":"","sources":["../../../../src/scripts/shared/prompt/prompt.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAEtD,KAAK,WAAW,GAAG;IACjB,QAAQ,EAAE,aAAa,CAAC;IACxB,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,sFAAsF;IACtF,UAAU,EAAE,MAAM,CAAC;IACnB,gFAAgF;IAChF,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,uEAAuE;IACvE,GAAG,CAAC,EAAE,OAAO,CAAC;CACf,CAAC;AA6CF,iEAAiE;AACjE,MAAM,MAAM,iBAAiB,GAAG;IAC9B,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,aAAa,CAAC;IACxB,gBAAgB,EAAE,MAAM,EAAE,CAAC;IAC3B,mEAAmE;IACnE,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,uEAAuE;IACvE,GAAG,CAAC,EAAE,OAAO,CAAC;CACf,CAAC;AAEF;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,iBAAiB,GAAG,MAAM,CA4BlE;AAED;;;;;GAKG;AACH,wBAAgB,WAAW,CAAC,KAAK,EAAE,WAAW,GAAG,MAAM,CAkCtD"}
|
|
@@ -1,123 +0,0 @@
|
|
|
1
|
-
const tddBlock = `
|
|
2
|
-
## Test-Driven Development
|
|
3
|
-
|
|
4
|
-
You MUST follow the red-green-refactor cycle for every behaviour change:
|
|
5
|
-
|
|
6
|
-
1. **Red** — Write a failing test that describes the desired behaviour.
|
|
7
|
-
Run the test suite and confirm the new test fails.
|
|
8
|
-
2. **Green** — Write the minimum code to make the failing test pass.
|
|
9
|
-
Do not add behaviour beyond what the test requires.
|
|
10
|
-
3. **Refactor** — Clean up the implementation while keeping all tests green.
|
|
11
|
-
Look for duplication, unclear names, or unnecessary complexity.
|
|
12
|
-
|
|
13
|
-
Repeat for each behaviour. Do not write implementation code without a failing test first.
|
|
14
|
-
Design interfaces for testability — prefer pure functions and thin boundaries
|
|
15
|
-
so modules are easy to test in isolation.`;
|
|
16
|
-
/**
|
|
17
|
-
* Get the board-specific label for the ticket type.
|
|
18
|
-
*
|
|
19
|
-
* @param provider - The board provider.
|
|
20
|
-
* @returns The label used in prompts (e.g., `'Jira ticket'`, `'GitHub Issue'`).
|
|
21
|
-
*/
|
|
22
|
-
function ticketLabel(provider) {
|
|
23
|
-
switch (provider) {
|
|
24
|
-
case 'jira':
|
|
25
|
-
return 'Jira ticket';
|
|
26
|
-
case 'github':
|
|
27
|
-
return 'GitHub Issue';
|
|
28
|
-
case 'linear':
|
|
29
|
-
return 'Linear issue';
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
/**
|
|
33
|
-
* Get the board-specific label for the parent grouping.
|
|
34
|
-
*
|
|
35
|
-
* @param provider - The board provider.
|
|
36
|
-
* @returns The label (e.g., `'Epic'`, `'Milestone'`).
|
|
37
|
-
*/
|
|
38
|
-
function parentLabel(provider) {
|
|
39
|
-
return provider === 'github' ? 'Milestone' : 'Epic';
|
|
40
|
-
}
|
|
41
|
-
/**
|
|
42
|
-
* Build the Claude prompt for reworking a ticket based on reviewer feedback.
|
|
43
|
-
*
|
|
44
|
-
* @param input - The rework ticket data and feedback.
|
|
45
|
-
* @returns The complete rework prompt string.
|
|
46
|
-
*
|
|
47
|
-
* @example
|
|
48
|
-
* ```ts
|
|
49
|
-
* const prompt = buildReworkPrompt({
|
|
50
|
-
* key: 'PROJ-123',
|
|
51
|
-
* title: 'Add login page',
|
|
52
|
-
* description: 'Create a login page with email/password fields.',
|
|
53
|
-
* provider: 'jira',
|
|
54
|
-
* feedbackComments: ['Button colour is wrong', 'Missing validation'],
|
|
55
|
-
* });
|
|
56
|
-
* ```
|
|
57
|
-
*/
|
|
58
|
-
export function buildReworkPrompt(input) {
|
|
59
|
-
const feedbackSection = input.feedbackComments.length > 0
|
|
60
|
-
? input.feedbackComments.map((c, i) => `${i + 1}. ${c}`).join('\n')
|
|
61
|
-
: 'No reviewer comments found. Review the existing implementation and fix any issues.';
|
|
62
|
-
const previousSection = input.previousContext
|
|
63
|
-
? `\n\n## Previous Implementation\n\n\`\`\`\n${input.previousContext}\n\`\`\``
|
|
64
|
-
: '';
|
|
65
|
-
return `You are fixing review feedback on [${input.key}] ${input.title}.
|
|
66
|
-
|
|
67
|
-
Description:
|
|
68
|
-
${input.description}
|
|
69
|
-
|
|
70
|
-
## Reviewer Feedback
|
|
71
|
-
|
|
72
|
-
${feedbackSection}${previousSection}
|
|
73
|
-
|
|
74
|
-
Address the specific feedback above. Don't re-implement unrelated areas. Focus only on what was flagged.${input.tdd ? tddBlock : ''}
|
|
75
|
-
|
|
76
|
-
Steps:
|
|
77
|
-
1. Read core docs in .clancy/docs/: STACK.md, ARCHITECTURE.md, CONVENTIONS.md, GIT.md, DEFINITION-OF-DONE.md, CONCERNS.md
|
|
78
|
-
Also read if relevant to this ticket: INTEGRATIONS.md (external APIs/services/auth), TESTING.md (tests/specs/coverage), DESIGN-SYSTEM.md (UI/components/styles), ACCESSIBILITY.md (accessibility/ARIA/WCAG)
|
|
79
|
-
2. Follow the conventions in GIT.md exactly
|
|
80
|
-
3. Fix the issues identified in the reviewer feedback
|
|
81
|
-
4. Commit your work following the conventions in GIT.md
|
|
82
|
-
5. When done, confirm you are finished.`;
|
|
83
|
-
}
|
|
84
|
-
/**
|
|
85
|
-
* Build the full Claude prompt for implementing a ticket.
|
|
86
|
-
*
|
|
87
|
-
* @param input - The ticket data for the prompt.
|
|
88
|
-
* @returns The complete prompt string.
|
|
89
|
-
*/
|
|
90
|
-
export function buildPrompt(input) {
|
|
91
|
-
const label = ticketLabel(input.provider);
|
|
92
|
-
const pLabel = parentLabel(input.provider);
|
|
93
|
-
const blockerLine = input.blockers && input.provider !== 'github'
|
|
94
|
-
? `\nBlockers: ${input.blockers}`
|
|
95
|
-
: '';
|
|
96
|
-
return `You are implementing ${label} ${input.key}.
|
|
97
|
-
|
|
98
|
-
${input.provider === 'github' ? 'Title' : 'Summary'}: ${input.title}
|
|
99
|
-
${pLabel}: ${input.parentInfo}${blockerLine}
|
|
100
|
-
|
|
101
|
-
Description:
|
|
102
|
-
${input.description}
|
|
103
|
-
|
|
104
|
-
Step 0 — Executability check (do this before any git or file operation):
|
|
105
|
-
Read the ${input.provider === 'github' ? 'issue title and description' : 'ticket summary and description'} above. Can this ${input.provider === 'github' ? 'issue' : 'ticket'} be implemented entirely
|
|
106
|
-
as a code change committed to this repo? Consult the 'Executability check' section of
|
|
107
|
-
CLAUDE.md for the full list of skip conditions.
|
|
108
|
-
|
|
109
|
-
If you must SKIP this ${input.provider === 'github' ? 'issue' : 'ticket'}:
|
|
110
|
-
1. Output: ⚠ Skipping [${input.key}]: {one-line reason}
|
|
111
|
-
2. Output: Ticket skipped — update it to be codebase-only work, then re-run.
|
|
112
|
-
3. Append to .clancy/progress.txt: YYYY-MM-DD HH:MM | ${input.key} | {reason} | SKIPPED
|
|
113
|
-
4. Stop — no branches, no file changes, no git operations.
|
|
114
|
-
|
|
115
|
-
If the ${input.provider === 'github' ? 'issue' : 'ticket'} IS implementable, continue:${input.tdd ? tddBlock : ''}
|
|
116
|
-
1. Read core docs in .clancy/docs/: STACK.md, ARCHITECTURE.md, CONVENTIONS.md, GIT.md, DEFINITION-OF-DONE.md, CONCERNS.md
|
|
117
|
-
Also read if relevant to this ticket: INTEGRATIONS.md (external APIs/services/auth), TESTING.md (tests/specs/coverage), DESIGN-SYSTEM.md (UI/components/styles), ACCESSIBILITY.md (accessibility/ARIA/WCAG)
|
|
118
|
-
2. Follow the conventions in GIT.md exactly
|
|
119
|
-
3. Implement the ${input.provider === 'github' ? 'issue' : 'ticket'} fully
|
|
120
|
-
4. Commit your work following the conventions in GIT.md
|
|
121
|
-
5. When done, confirm you are finished.`;
|
|
122
|
-
}
|
|
123
|
-
//# sourceMappingURL=prompt.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"prompt.js","sourceRoot":"","sources":["../../../../src/scripts/shared/prompt/prompt.ts"],"names":[],"mappings":"AAqBA,MAAM,QAAQ,GAAG;;;;;;;;;;;;;;0CAcyB,CAAC;AAE3C;;;;;GAKG;AACH,SAAS,WAAW,CAAC,QAAuB;IAC1C,QAAQ,QAAQ,EAAE,CAAC;QACjB,KAAK,MAAM;YACT,OAAO,aAAa,CAAC;QACvB,KAAK,QAAQ;YACX,OAAO,cAAc,CAAC;QACxB,KAAK,QAAQ;YACX,OAAO,cAAc,CAAC;IAC1B,CAAC;AACH,CAAC;AAED;;;;;GAKG;AACH,SAAS,WAAW,CAAC,QAAuB;IAC1C,OAAO,QAAQ,KAAK,QAAQ,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,MAAM,CAAC;AACtD,CAAC;AAeD;;;;;;;;;;;;;;;;GAgBG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,WAAW;;;EAGzC,KAAK,CAAC,WAAW;;;WAGR,KAAK,CAAC,QAAQ,KAAK,QAAQ,CAAC,CAAC,CAAC,6BAA6B,CAAC,CAAC,CAAC,gCAAgC,oBAAoB,KAAK,CAAC,QAAQ,KAAK,QAAQ,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,QAAQ;;;;wBAIrJ,KAAK,CAAC,QAAQ,KAAK,QAAQ,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,QAAQ;yBAC/C,KAAK,CAAC,GAAG;;wDAEsB,KAAK,CAAC,GAAG;;;SAGxD,KAAK,CAAC,QAAQ,KAAK,QAAQ,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,QAAQ,+BAA+B,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE;;;;mBAI9F,KAAK,CAAC,QAAQ,KAAK,QAAQ,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,QAAQ;;wCAE3B,CAAC;AACzC,CAAC"}
|
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
import type { PrCreationResult, PrReviewState } from '../../../../types/index.js';
|
|
2
|
-
/**
|
|
3
|
-
* Create a pull request on Bitbucket Cloud.
|
|
4
|
-
*
|
|
5
|
-
* @param username - The Bitbucket username.
|
|
6
|
-
* @param token - The Bitbucket API token (or app password).
|
|
7
|
-
* @param workspace - The Bitbucket workspace slug.
|
|
8
|
-
* @param repoSlug - The repository slug.
|
|
9
|
-
* @param sourceBranch - The source branch name.
|
|
10
|
-
* @param targetBranch - The target branch name.
|
|
11
|
-
* @param title - The PR title.
|
|
12
|
-
* @param description - The PR body (markdown).
|
|
13
|
-
* @returns A result with the PR URL and ID on success, or an error message.
|
|
14
|
-
*/
|
|
15
|
-
export declare function createPullRequest(username: string, token: string, workspace: string, repoSlug: string, sourceBranch: string, targetBranch: string, title: string, description: string): Promise<PrCreationResult>;
|
|
16
|
-
/**
|
|
17
|
-
* Create a pull request on Bitbucket Server / Data Center.
|
|
18
|
-
*
|
|
19
|
-
* @param token - The Bitbucket Server personal access token.
|
|
20
|
-
* @param apiBase - The API base URL (e.g. `https://bitbucket.acme.com/rest/api/1.0`).
|
|
21
|
-
* @param projectKey - The Bitbucket Server project key.
|
|
22
|
-
* @param repoSlug - The repository slug.
|
|
23
|
-
* @param sourceBranch - The source branch name.
|
|
24
|
-
* @param targetBranch - The target branch name.
|
|
25
|
-
* @param title - The PR title.
|
|
26
|
-
* @param description - The PR body.
|
|
27
|
-
* @returns A result with the PR URL and ID on success, or an error message.
|
|
28
|
-
*/
|
|
29
|
-
export declare function createServerPullRequest(token: string, apiBase: string, projectKey: string, repoSlug: string, sourceBranch: string, targetBranch: string, title: string, description: string): Promise<PrCreationResult>;
|
|
30
|
-
/**
|
|
31
|
-
* Post a comment on a Bitbucket Cloud pull request.
|
|
32
|
-
*
|
|
33
|
-
* Best-effort — never throws. Returns `true` on success, `false` on error.
|
|
34
|
-
*/
|
|
35
|
-
export declare function postCloudPrComment(username: string, token: string, workspace: string, repoSlug: string, prId: number, body: string): Promise<boolean>;
|
|
36
|
-
/**
|
|
37
|
-
* Post a comment on a Bitbucket Server/DC pull request.
|
|
38
|
-
*
|
|
39
|
-
* Best-effort — never throws. Returns `true` on success, `false` on error.
|
|
40
|
-
*/
|
|
41
|
-
export declare function postServerPrComment(token: string, apiBase: string, projectKey: string, repoSlug: string, prId: number, body: string): Promise<boolean>;
|
|
42
|
-
/**
|
|
43
|
-
* Check the review state of an open PR on Bitbucket Cloud for a given branch.
|
|
44
|
-
*
|
|
45
|
-
* Finds the open PR, fetches all comments. Inline comments (with `inline`
|
|
46
|
-
* property) always trigger rework. General conversation comments only
|
|
47
|
-
* trigger rework when prefixed with `Rework:`.
|
|
48
|
-
*
|
|
49
|
-
* @param since - ISO 8601 timestamp; only comments created after this time trigger rework.
|
|
50
|
-
* @returns The review state, or `undefined` if no open PR exists.
|
|
51
|
-
*/
|
|
52
|
-
export declare function checkPrReviewState(username: string, token: string, workspace: string, repoSlug: string, branch: string, since?: string): Promise<PrReviewState | undefined>;
|
|
53
|
-
/**
|
|
54
|
-
* Fetch feedback comments on a Bitbucket Cloud PR.
|
|
55
|
-
*
|
|
56
|
-
* Inline comments (with `inline` property) are always included — they
|
|
57
|
-
* inherently represent change requests. General conversation comments are
|
|
58
|
-
* only included when prefixed with `Rework:` (prefix stripped).
|
|
59
|
-
* Inline comments are prefixed with `[path]`.
|
|
60
|
-
*/
|
|
61
|
-
export declare function fetchPrReviewComments(username: string, token: string, workspace: string, repoSlug: string, prId: number, since?: string): Promise<string[]>;
|
|
62
|
-
/**
|
|
63
|
-
* Check the review state of an open PR on Bitbucket Server/DC for a given branch.
|
|
64
|
-
*
|
|
65
|
-
* Finds the open PR, fetches all comments. Inline comments (with `anchor`
|
|
66
|
-
* property) always trigger rework. General conversation comments only
|
|
67
|
-
* trigger rework when prefixed with `Rework:`.
|
|
68
|
-
*
|
|
69
|
-
* @param since - ISO 8601 timestamp; only comments created after this time trigger rework.
|
|
70
|
-
* @returns The review state, or `undefined` if no open PR exists.
|
|
71
|
-
*/
|
|
72
|
-
export declare function checkServerPrReviewState(token: string, apiBase: string, projectKey: string, repoSlug: string, branch: string, since?: string): Promise<PrReviewState | undefined>;
|
|
73
|
-
/**
|
|
74
|
-
* Fetch feedback comments on a Bitbucket Server/DC PR.
|
|
75
|
-
*
|
|
76
|
-
* Inline comments (with `anchor` property) are always included — they
|
|
77
|
-
* inherently represent change requests. General conversation comments are
|
|
78
|
-
* only included when prefixed with `Rework:` (prefix stripped).
|
|
79
|
-
* Inline comments are prefixed with `[path]`.
|
|
80
|
-
*/
|
|
81
|
-
export declare function fetchServerPrReviewComments(token: string, apiBase: string, projectKey: string, repoSlug: string, prId: number, since?: string): Promise<string[]>;
|
|
82
|
-
//# sourceMappingURL=bitbucket.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"bitbucket.d.ts","source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SAAS,EAAE,MAAM,EACjB,QAAQ,EAAE,MAAM,EAChB,MAAM,EAAE,MAAM,EACd,KAAK,CAAC,EAAE,MAAM,GACb,OAAO,CAAC,aAAa,GAAG,SAAS,CAAC,CAyCpC;AAED;;;;;;;GAOG;AACH,wBAAsB,qBAAqB,CACzC,QAAQ,EAAE,MAAM,EAChB,KAAK,EAAE,MAAM,EACb,SAAS,EAAE,MAAM,EACjB,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,MAAM,EACZ,KAAK,CAAC,EAAE,MAAM,GACb,OAAO,CAAC,MAAM,EAAE,CAAC,CA8BnB;AAMD;;;;;;;;;GASG;AACH,wBAAsB,wBAAwB,CAC5C,KAAK,EAAE,MAAM,EACb,OAAO,EAAE,MAAM,EACf,UAAU,EAAE,MAAM,EAClB,QAAQ,EAAE,MAAM,EAChB,MAAM,EAAE,MAAM,EACd,KAAK,CAAC,EAAE,MAAM,GACb,OAAO,CAAC,aAAa,GAAG,SAAS,CAAC,CA+CpC;AAED;;;;;;;GAOG;AACH,wBAAsB,2BAA2B,CAC/C,KAAK,EAAE,MAAM,EACb,OAAO,EAAE,MAAM,EACf,UAAU,EAAE,MAAM,EAClB,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,MAAM,EACZ,KAAK,CAAC,EAAE,MAAM,GACb,OAAO,CAAC,MAAM,EAAE,CAAC,CAgCnB"}
|
|
@@ -1,301 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Bitbucket pull request creation and review state checking.
|
|
3
|
-
*
|
|
4
|
-
* Supports both Bitbucket Cloud (api.bitbucket.org/2.0) and
|
|
5
|
-
* Bitbucket Server/Data Center (rest/api/1.0).
|
|
6
|
-
*
|
|
7
|
-
* Auth: Cloud uses HTTP Basic Auth, Server uses Bearer token.
|
|
8
|
-
*/
|
|
9
|
-
import { bitbucketCommentsSchema, bitbucketPrListSchema, bitbucketServerActivitiesSchema, bitbucketServerPrListSchema, } from '../../../../schemas/bitbucket-pr.js';
|
|
10
|
-
import { basicAuth, postPullRequest } from '../post-pr/post-pr.js';
|
|
11
|
-
import { extractReworkContent, isReworkComment, } from '../rework-comment/rework-comment.js';
|
|
12
|
-
/**
|
|
13
|
-
* Create a pull request on Bitbucket Cloud.
|
|
14
|
-
*
|
|
15
|
-
* @param username - The Bitbucket username.
|
|
16
|
-
* @param token - The Bitbucket API token (or app password).
|
|
17
|
-
* @param workspace - The Bitbucket workspace slug.
|
|
18
|
-
* @param repoSlug - The repository slug.
|
|
19
|
-
* @param sourceBranch - The source branch name.
|
|
20
|
-
* @param targetBranch - The target branch name.
|
|
21
|
-
* @param title - The PR title.
|
|
22
|
-
* @param description - The PR body (markdown).
|
|
23
|
-
* @returns A result with the PR URL and ID on success, or an error message.
|
|
24
|
-
*/
|
|
25
|
-
export async function createPullRequest(username, token, workspace, repoSlug, sourceBranch, targetBranch, title, description) {
|
|
26
|
-
return postPullRequest(`https://api.bitbucket.org/2.0/repositories/${workspace}/${repoSlug}/pullrequests`, { Authorization: basicAuth(username, token) }, {
|
|
27
|
-
title,
|
|
28
|
-
description,
|
|
29
|
-
source: { branch: { name: sourceBranch } },
|
|
30
|
-
destination: { branch: { name: targetBranch } },
|
|
31
|
-
close_source_branch: true,
|
|
32
|
-
}, (json) => {
|
|
33
|
-
const data = json;
|
|
34
|
-
return {
|
|
35
|
-
url: data.links?.html?.href ?? '',
|
|
36
|
-
number: data.id ?? 0,
|
|
37
|
-
};
|
|
38
|
-
}, (status, text) => status === 409 && text.includes('already exists'));
|
|
39
|
-
}
|
|
40
|
-
/**
|
|
41
|
-
* Create a pull request on Bitbucket Server / Data Center.
|
|
42
|
-
*
|
|
43
|
-
* @param token - The Bitbucket Server personal access token.
|
|
44
|
-
* @param apiBase - The API base URL (e.g. `https://bitbucket.acme.com/rest/api/1.0`).
|
|
45
|
-
* @param projectKey - The Bitbucket Server project key.
|
|
46
|
-
* @param repoSlug - The repository slug.
|
|
47
|
-
* @param sourceBranch - The source branch name.
|
|
48
|
-
* @param targetBranch - The target branch name.
|
|
49
|
-
* @param title - The PR title.
|
|
50
|
-
* @param description - The PR body.
|
|
51
|
-
* @returns A result with the PR URL and ID on success, or an error message.
|
|
52
|
-
*/
|
|
53
|
-
export async function createServerPullRequest(token, apiBase, projectKey, repoSlug, sourceBranch, targetBranch, title, description) {
|
|
54
|
-
return postPullRequest(`${apiBase}/projects/${projectKey}/repos/${repoSlug}/pull-requests`, { Authorization: `Bearer ${token}` }, {
|
|
55
|
-
title,
|
|
56
|
-
description,
|
|
57
|
-
fromRef: {
|
|
58
|
-
id: `refs/heads/${sourceBranch}`,
|
|
59
|
-
repository: {
|
|
60
|
-
slug: repoSlug,
|
|
61
|
-
project: { key: projectKey },
|
|
62
|
-
},
|
|
63
|
-
},
|
|
64
|
-
toRef: {
|
|
65
|
-
id: `refs/heads/${targetBranch}`,
|
|
66
|
-
repository: {
|
|
67
|
-
slug: repoSlug,
|
|
68
|
-
project: { key: projectKey },
|
|
69
|
-
},
|
|
70
|
-
},
|
|
71
|
-
}, (json) => {
|
|
72
|
-
const data = json;
|
|
73
|
-
return {
|
|
74
|
-
url: data.links?.self?.[0]?.href ?? '',
|
|
75
|
-
number: data.id ?? 0,
|
|
76
|
-
};
|
|
77
|
-
}, (status, text) => status === 409 &&
|
|
78
|
-
(text.includes('already exists') ||
|
|
79
|
-
text.includes('Only one pull request')));
|
|
80
|
-
}
|
|
81
|
-
// ---------------------------------------------------------------------------
|
|
82
|
-
// Cloud — comment posting
|
|
83
|
-
// ---------------------------------------------------------------------------
|
|
84
|
-
/**
|
|
85
|
-
* Post a comment on a Bitbucket Cloud pull request.
|
|
86
|
-
*
|
|
87
|
-
* Best-effort — never throws. Returns `true` on success, `false` on error.
|
|
88
|
-
*/
|
|
89
|
-
export async function postCloudPrComment(username, token, workspace, repoSlug, prId, body) {
|
|
90
|
-
try {
|
|
91
|
-
const res = await fetch(`https://api.bitbucket.org/2.0/repositories/${workspace}/${repoSlug}/pullrequests/${prId}/comments`, {
|
|
92
|
-
method: 'POST',
|
|
93
|
-
headers: {
|
|
94
|
-
Authorization: basicAuth(username, token),
|
|
95
|
-
'Content-Type': 'application/json',
|
|
96
|
-
},
|
|
97
|
-
body: JSON.stringify({ content: { raw: body } }),
|
|
98
|
-
});
|
|
99
|
-
return res.ok;
|
|
100
|
-
}
|
|
101
|
-
catch {
|
|
102
|
-
return false;
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
// ---------------------------------------------------------------------------
|
|
106
|
-
// Server/DC — comment posting
|
|
107
|
-
// ---------------------------------------------------------------------------
|
|
108
|
-
/**
|
|
109
|
-
* Post a comment on a Bitbucket Server/DC pull request.
|
|
110
|
-
*
|
|
111
|
-
* Best-effort — never throws. Returns `true` on success, `false` on error.
|
|
112
|
-
*/
|
|
113
|
-
export async function postServerPrComment(token, apiBase, projectKey, repoSlug, prId, body) {
|
|
114
|
-
try {
|
|
115
|
-
const res = await fetch(`${apiBase}/projects/${projectKey}/repos/${repoSlug}/pull-requests/${prId}/comments`, {
|
|
116
|
-
method: 'POST',
|
|
117
|
-
headers: {
|
|
118
|
-
Authorization: `Bearer ${token}`,
|
|
119
|
-
'Content-Type': 'application/json',
|
|
120
|
-
},
|
|
121
|
-
body: JSON.stringify({ text: body }),
|
|
122
|
-
});
|
|
123
|
-
return res.ok;
|
|
124
|
-
}
|
|
125
|
-
catch {
|
|
126
|
-
return false;
|
|
127
|
-
}
|
|
128
|
-
}
|
|
129
|
-
// ---------------------------------------------------------------------------
|
|
130
|
-
// Cloud — review state & comments
|
|
131
|
-
// ---------------------------------------------------------------------------
|
|
132
|
-
/**
|
|
133
|
-
* Check the review state of an open PR on Bitbucket Cloud for a given branch.
|
|
134
|
-
*
|
|
135
|
-
* Finds the open PR, fetches all comments. Inline comments (with `inline`
|
|
136
|
-
* property) always trigger rework. General conversation comments only
|
|
137
|
-
* trigger rework when prefixed with `Rework:`.
|
|
138
|
-
*
|
|
139
|
-
* @param since - ISO 8601 timestamp; only comments created after this time trigger rework.
|
|
140
|
-
* @returns The review state, or `undefined` if no open PR exists.
|
|
141
|
-
*/
|
|
142
|
-
export async function checkPrReviewState(username, token, workspace, repoSlug, branch, since) {
|
|
143
|
-
try {
|
|
144
|
-
const prUrl = `https://api.bitbucket.org/2.0/repositories/${workspace}/${repoSlug}/pullrequests` +
|
|
145
|
-
`?q=source.branch.name="${branch}"&state=OPEN`;
|
|
146
|
-
const prRes = await fetch(prUrl, {
|
|
147
|
-
headers: { Authorization: basicAuth(username, token) },
|
|
148
|
-
});
|
|
149
|
-
if (!prRes.ok)
|
|
150
|
-
return undefined;
|
|
151
|
-
const parsed = bitbucketPrListSchema.parse(await prRes.json());
|
|
152
|
-
if (parsed.values.length === 0)
|
|
153
|
-
return undefined;
|
|
154
|
-
const pr = parsed.values[0];
|
|
155
|
-
const htmlUrl = pr.links.html?.href ?? '';
|
|
156
|
-
const commentsUrl = `https://api.bitbucket.org/2.0/repositories/${workspace}/${repoSlug}/pullrequests/${pr.id}/comments` +
|
|
157
|
-
`?pagelen=100`;
|
|
158
|
-
const commentsRes = await fetch(commentsUrl, {
|
|
159
|
-
headers: { Authorization: basicAuth(username, token) },
|
|
160
|
-
});
|
|
161
|
-
if (!commentsRes.ok)
|
|
162
|
-
return undefined;
|
|
163
|
-
const comments = bitbucketCommentsSchema.parse(await commentsRes.json());
|
|
164
|
-
const relevant = since
|
|
165
|
-
? comments.values.filter((c) => c.created_on > since)
|
|
166
|
-
: comments.values;
|
|
167
|
-
const hasInline = relevant.some((c) => c.inline != null);
|
|
168
|
-
const hasReworkConvo = relevant.some((c) => c.inline == null && isReworkComment(c.content.raw));
|
|
169
|
-
const changesRequested = hasInline || hasReworkConvo;
|
|
170
|
-
return { changesRequested, prNumber: pr.id, prUrl: htmlUrl };
|
|
171
|
-
}
|
|
172
|
-
catch {
|
|
173
|
-
return undefined;
|
|
174
|
-
}
|
|
175
|
-
}
|
|
176
|
-
/**
|
|
177
|
-
* Fetch feedback comments on a Bitbucket Cloud PR.
|
|
178
|
-
*
|
|
179
|
-
* Inline comments (with `inline` property) are always included — they
|
|
180
|
-
* inherently represent change requests. General conversation comments are
|
|
181
|
-
* only included when prefixed with `Rework:` (prefix stripped).
|
|
182
|
-
* Inline comments are prefixed with `[path]`.
|
|
183
|
-
*/
|
|
184
|
-
export async function fetchPrReviewComments(username, token, workspace, repoSlug, prId, since) {
|
|
185
|
-
try {
|
|
186
|
-
const url = `https://api.bitbucket.org/2.0/repositories/${workspace}/${repoSlug}/pullrequests/${prId}/comments` +
|
|
187
|
-
`?pagelen=100`;
|
|
188
|
-
const res = await fetch(url, {
|
|
189
|
-
headers: { Authorization: basicAuth(username, token) },
|
|
190
|
-
});
|
|
191
|
-
if (!res.ok)
|
|
192
|
-
return [];
|
|
193
|
-
const parsed = bitbucketCommentsSchema.parse(await res.json());
|
|
194
|
-
const relevant = since
|
|
195
|
-
? parsed.values.filter((c) => c.created_on > since)
|
|
196
|
-
: parsed.values;
|
|
197
|
-
const comments = [];
|
|
198
|
-
for (const c of relevant) {
|
|
199
|
-
if (c.inline != null) {
|
|
200
|
-
const prefix = c.inline.path ? `[${c.inline.path}] ` : '';
|
|
201
|
-
comments.push(`${prefix}${c.content.raw}`);
|
|
202
|
-
}
|
|
203
|
-
else if (isReworkComment(c.content.raw)) {
|
|
204
|
-
comments.push(extractReworkContent(c.content.raw));
|
|
205
|
-
}
|
|
206
|
-
}
|
|
207
|
-
return comments;
|
|
208
|
-
}
|
|
209
|
-
catch {
|
|
210
|
-
return [];
|
|
211
|
-
}
|
|
212
|
-
}
|
|
213
|
-
// ---------------------------------------------------------------------------
|
|
214
|
-
// Server/DC — review state & comments
|
|
215
|
-
// ---------------------------------------------------------------------------
|
|
216
|
-
/**
|
|
217
|
-
* Check the review state of an open PR on Bitbucket Server/DC for a given branch.
|
|
218
|
-
*
|
|
219
|
-
* Finds the open PR, fetches all comments. Inline comments (with `anchor`
|
|
220
|
-
* property) always trigger rework. General conversation comments only
|
|
221
|
-
* trigger rework when prefixed with `Rework:`.
|
|
222
|
-
*
|
|
223
|
-
* @param since - ISO 8601 timestamp; only comments created after this time trigger rework.
|
|
224
|
-
* @returns The review state, or `undefined` if no open PR exists.
|
|
225
|
-
*/
|
|
226
|
-
export async function checkServerPrReviewState(token, apiBase, projectKey, repoSlug, branch, since) {
|
|
227
|
-
try {
|
|
228
|
-
const prUrl = `${apiBase}/projects/${projectKey}/repos/${repoSlug}/pull-requests` +
|
|
229
|
-
`?state=OPEN&at=refs/heads/${branch}`;
|
|
230
|
-
const prRes = await fetch(prUrl, {
|
|
231
|
-
headers: { Authorization: `Bearer ${token}` },
|
|
232
|
-
});
|
|
233
|
-
if (!prRes.ok)
|
|
234
|
-
return undefined;
|
|
235
|
-
const parsed = bitbucketServerPrListSchema.parse(await prRes.json());
|
|
236
|
-
if (parsed.values.length === 0)
|
|
237
|
-
return undefined;
|
|
238
|
-
const pr = parsed.values[0];
|
|
239
|
-
const htmlUrl = pr.links.self?.[0]?.href ?? '';
|
|
240
|
-
const activitiesUrl = `${apiBase}/projects/${projectKey}/repos/${repoSlug}/pull-requests/${pr.id}/activities` +
|
|
241
|
-
`?limit=100`;
|
|
242
|
-
const activitiesRes = await fetch(activitiesUrl, {
|
|
243
|
-
headers: { Authorization: `Bearer ${token}` },
|
|
244
|
-
});
|
|
245
|
-
if (!activitiesRes.ok)
|
|
246
|
-
return undefined;
|
|
247
|
-
const activities = bitbucketServerActivitiesSchema.parse(await activitiesRes.json());
|
|
248
|
-
const sinceMs = since ? Date.parse(since) : undefined;
|
|
249
|
-
const commentActivities = activities.values.filter((a) => a.action === 'COMMENTED' &&
|
|
250
|
-
a.comment &&
|
|
251
|
-
(sinceMs == null || a.comment.createdDate > sinceMs));
|
|
252
|
-
const hasInline = commentActivities.some((a) => a.comment.anchor != null);
|
|
253
|
-
const hasReworkConvo = commentActivities.some((a) => a.comment.anchor == null && isReworkComment(a.comment.text));
|
|
254
|
-
const changesRequested = hasInline || hasReworkConvo;
|
|
255
|
-
return { changesRequested, prNumber: pr.id, prUrl: htmlUrl };
|
|
256
|
-
}
|
|
257
|
-
catch {
|
|
258
|
-
return undefined;
|
|
259
|
-
}
|
|
260
|
-
}
|
|
261
|
-
/**
|
|
262
|
-
* Fetch feedback comments on a Bitbucket Server/DC PR.
|
|
263
|
-
*
|
|
264
|
-
* Inline comments (with `anchor` property) are always included — they
|
|
265
|
-
* inherently represent change requests. General conversation comments are
|
|
266
|
-
* only included when prefixed with `Rework:` (prefix stripped).
|
|
267
|
-
* Inline comments are prefixed with `[path]`.
|
|
268
|
-
*/
|
|
269
|
-
export async function fetchServerPrReviewComments(token, apiBase, projectKey, repoSlug, prId, since) {
|
|
270
|
-
try {
|
|
271
|
-
const url = `${apiBase}/projects/${projectKey}/repos/${repoSlug}/pull-requests/${prId}/activities` +
|
|
272
|
-
`?limit=100`;
|
|
273
|
-
const res = await fetch(url, {
|
|
274
|
-
headers: { Authorization: `Bearer ${token}` },
|
|
275
|
-
});
|
|
276
|
-
if (!res.ok)
|
|
277
|
-
return [];
|
|
278
|
-
const parsed = bitbucketServerActivitiesSchema.parse(await res.json());
|
|
279
|
-
const sinceMs = since ? Date.parse(since) : undefined;
|
|
280
|
-
const comments = [];
|
|
281
|
-
for (const a of parsed.values) {
|
|
282
|
-
if (a.action !== 'COMMENTED' || !a.comment)
|
|
283
|
-
continue;
|
|
284
|
-
if (sinceMs != null && a.comment.createdDate <= sinceMs)
|
|
285
|
-
continue;
|
|
286
|
-
const c = a.comment;
|
|
287
|
-
if (c.anchor != null) {
|
|
288
|
-
const prefix = c.anchor.path ? `[${c.anchor.path}] ` : '';
|
|
289
|
-
comments.push(`${prefix}${c.text}`);
|
|
290
|
-
}
|
|
291
|
-
else if (isReworkComment(c.text)) {
|
|
292
|
-
comments.push(extractReworkContent(c.text));
|
|
293
|
-
}
|
|
294
|
-
}
|
|
295
|
-
return comments;
|
|
296
|
-
}
|
|
297
|
-
catch {
|
|
298
|
-
return [];
|
|
299
|
-
}
|
|
300
|
-
}
|
|
301
|
-
//# sourceMappingURL=bitbucket.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"bitbucket.js","sourceRoot":"","sources":["../../../../../src/scripts/shared/pull-request/bitbucket/bitbucket.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,EACL,uBAAuB,EACvB,qBAAqB,EACrB,+BAA+B,EAC/B,2BAA2B,GAC5B,MAAM,2BAA2B,CAAC;AAGnC,OAAO,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACnE,OAAO,EACL,oBAAoB,EACpB,eAAe,GAChB,MAAM,qCAAqC,CAAC;AAE7C;;;;;;;;;;;;GAYG;AACH,MAAM,CAAC,KAAK,UAAU,iBAAiB,CACrC,QAAgB,EAChB,KAAa,EACb,SAAiB,EACjB,QAAgB,EAChB,YAAoB,EACpB,YAAoB,EACpB,KAAa,EACb,WAAmB;IAEnB,OAAO,eAAe,CACpB,8CAA8C,SAAS,IAAI,QAAQ,eAAe,EAClF,EAAE,aAAa,EAAE,SAAS,CAAC,QAAQ,EAAE,KAAK,CAAC,EAAE,EAC7C;QACE,KAAK;QACL,WAAW;QACX,MAAM,EAAE,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,YAAY,EAAE,EAAE;QAC1C,WAAW,EAAE,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,YAAY,EAAE,EAAE;QAC/C,mBAAmB,EAAE,IAAI;KAC1B,EACD,CAAC,IAAI,EAAE,EAAE;QACP,MAAM,IAAI,GAAG,IAGZ,CAAC;QACF,OAAO;YACL,GAAG,EAAE,IAAI,CAAC,KAAK,EAAE,IAAI,EAAE,IAAI,IAAI,EAAE;YACjC,MAAM,EAAE,IAAI,CAAC,EAAE,IAAI,CAAC;SACrB,CAAC;IACJ,CAAC,EACD,CAAC,MAAM,EAAE,IAAI,EAAE,EAAE,CAAC,MAAM,KAAK,GAAG,IAAI,IAAI,CAAC,QAAQ,CAAC,gBAAgB,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