chief-clancy 0.6.0 → 0.7.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.
Files changed (181) hide show
  1. package/README.md +3 -2
  2. package/dist/bundle/clancy-afk.js +6 -2
  3. package/dist/bundle/clancy-once.js +49 -48
  4. package/dist/installer/hook-installer/hook-installer.d.ts +2 -0
  5. package/dist/installer/hook-installer/hook-installer.d.ts.map +1 -1
  6. package/dist/installer/hook-installer/hook-installer.js +36 -1
  7. package/dist/installer/hook-installer/hook-installer.js.map +1 -1
  8. package/dist/installer/install.js +8 -0
  9. package/dist/installer/install.js.map +1 -1
  10. package/hooks/clancy-branch-guard.js +129 -0
  11. package/hooks/clancy-context-monitor.js +134 -46
  12. package/hooks/clancy-post-compact.js +53 -0
  13. package/hooks/package.json +3 -0
  14. package/package.json +7 -3
  15. package/src/agents/verification-gate.md +128 -0
  16. package/src/roles/setup/workflows/init.md +45 -0
  17. package/src/roles/setup/workflows/scaffold.md +30 -0
  18. package/src/roles/setup/workflows/settings.md +56 -0
  19. package/src/templates/.env.example.github +19 -1
  20. package/src/templates/.env.example.jira +25 -1
  21. package/src/templates/.env.example.linear +19 -1
  22. package/dist/schemas/bitbucket-pr.d.ts +0 -137
  23. package/dist/schemas/bitbucket-pr.d.ts.map +0 -1
  24. package/dist/schemas/bitbucket-pr.js +0 -75
  25. package/dist/schemas/bitbucket-pr.js.map +0 -1
  26. package/dist/schemas/env.d.ts +0 -150
  27. package/dist/schemas/env.d.ts.map +0 -1
  28. package/dist/schemas/env.js +0 -63
  29. package/dist/schemas/env.js.map +0 -1
  30. package/dist/schemas/github-issues.d.ts +0 -105
  31. package/dist/schemas/github-issues.d.ts.map +0 -1
  32. package/dist/schemas/github-issues.js +0 -54
  33. package/dist/schemas/github-issues.js.map +0 -1
  34. package/dist/schemas/gitlab-mr.d.ts +0 -73
  35. package/dist/schemas/gitlab-mr.d.ts.map +0 -1
  36. package/dist/schemas/gitlab-mr.js +0 -33
  37. package/dist/schemas/gitlab-mr.js.map +0 -1
  38. package/dist/schemas/jira.d.ts +0 -59
  39. package/dist/schemas/jira.d.ts.map +0 -1
  40. package/dist/schemas/jira.js +0 -56
  41. package/dist/schemas/jira.js.map +0 -1
  42. package/dist/schemas/linear.d.ts +0 -108
  43. package/dist/schemas/linear.d.ts.map +0 -1
  44. package/dist/schemas/linear.js +0 -84
  45. package/dist/schemas/linear.js.map +0 -1
  46. package/dist/scripts/afk/afk.d.ts +0 -21
  47. package/dist/scripts/afk/afk.d.ts.map +0 -1
  48. package/dist/scripts/afk/afk.js +0 -118
  49. package/dist/scripts/afk/afk.js.map +0 -1
  50. package/dist/scripts/board/github/github.d.ts +0 -104
  51. package/dist/scripts/board/github/github.d.ts.map +0 -1
  52. package/dist/scripts/board/github/github.js +0 -291
  53. package/dist/scripts/board/github/github.js.map +0 -1
  54. package/dist/scripts/board/jira/jira.d.ts +0 -139
  55. package/dist/scripts/board/jira/jira.d.ts.map +0 -1
  56. package/dist/scripts/board/jira/jira.js +0 -378
  57. package/dist/scripts/board/jira/jira.js.map +0 -1
  58. package/dist/scripts/board/linear/linear.d.ts +0 -129
  59. package/dist/scripts/board/linear/linear.d.ts.map +0 -1
  60. package/dist/scripts/board/linear/linear.js +0 -393
  61. package/dist/scripts/board/linear/linear.js.map +0 -1
  62. package/dist/scripts/once/board-ops/board-ops.d.ts +0 -26
  63. package/dist/scripts/once/board-ops/board-ops.d.ts.map +0 -1
  64. package/dist/scripts/once/board-ops/board-ops.js +0 -113
  65. package/dist/scripts/once/board-ops/board-ops.js.map +0 -1
  66. package/dist/scripts/once/deliver/deliver.d.ts +0 -37
  67. package/dist/scripts/once/deliver/deliver.d.ts.map +0 -1
  68. package/dist/scripts/once/deliver/deliver.js +0 -236
  69. package/dist/scripts/once/deliver/deliver.js.map +0 -1
  70. package/dist/scripts/once/fetch-ticket/fetch-ticket.d.ts +0 -22
  71. package/dist/scripts/once/fetch-ticket/fetch-ticket.d.ts.map +0 -1
  72. package/dist/scripts/once/fetch-ticket/fetch-ticket.js +0 -123
  73. package/dist/scripts/once/fetch-ticket/fetch-ticket.js.map +0 -1
  74. package/dist/scripts/once/git-token/git-token.d.ts +0 -13
  75. package/dist/scripts/once/git-token/git-token.d.ts.map +0 -1
  76. package/dist/scripts/once/git-token/git-token.js +0 -30
  77. package/dist/scripts/once/git-token/git-token.js.map +0 -1
  78. package/dist/scripts/once/once.d.ts +0 -12
  79. package/dist/scripts/once/once.d.ts.map +0 -1
  80. package/dist/scripts/once/once.js +0 -356
  81. package/dist/scripts/once/once.js.map +0 -1
  82. package/dist/scripts/once/pr-creation/pr-creation.d.ts +0 -11
  83. package/dist/scripts/once/pr-creation/pr-creation.d.ts.map +0 -1
  84. package/dist/scripts/once/pr-creation/pr-creation.js +0 -50
  85. package/dist/scripts/once/pr-creation/pr-creation.js.map +0 -1
  86. package/dist/scripts/once/rework/rework.d.ts +0 -32
  87. package/dist/scripts/once/rework/rework.d.ts.map +0 -1
  88. package/dist/scripts/once/rework/rework.js +0 -208
  89. package/dist/scripts/once/rework/rework.js.map +0 -1
  90. package/dist/scripts/once/types/types.d.ts +0 -13
  91. package/dist/scripts/once/types/types.d.ts.map +0 -1
  92. package/dist/scripts/once/types/types.js +0 -2
  93. package/dist/scripts/once/types/types.js.map +0 -1
  94. package/dist/scripts/shared/branch/branch.d.ts +0 -50
  95. package/dist/scripts/shared/branch/branch.d.ts.map +0 -1
  96. package/dist/scripts/shared/branch/branch.js +0 -61
  97. package/dist/scripts/shared/branch/branch.js.map +0 -1
  98. package/dist/scripts/shared/claude-cli/claude-cli.d.ts +0 -31
  99. package/dist/scripts/shared/claude-cli/claude-cli.d.ts.map +0 -1
  100. package/dist/scripts/shared/claude-cli/claude-cli.js +0 -60
  101. package/dist/scripts/shared/claude-cli/claude-cli.js.map +0 -1
  102. package/dist/scripts/shared/env-schema/env-schema.d.ts +0 -27
  103. package/dist/scripts/shared/env-schema/env-schema.d.ts.map +0 -1
  104. package/dist/scripts/shared/env-schema/env-schema.js +0 -47
  105. package/dist/scripts/shared/env-schema/env-schema.js.map +0 -1
  106. package/dist/scripts/shared/feasibility/feasibility.d.ts +0 -30
  107. package/dist/scripts/shared/feasibility/feasibility.d.ts.map +0 -1
  108. package/dist/scripts/shared/feasibility/feasibility.js +0 -68
  109. package/dist/scripts/shared/feasibility/feasibility.js.map +0 -1
  110. package/dist/scripts/shared/format/format.d.ts +0 -11
  111. package/dist/scripts/shared/format/format.d.ts.map +0 -1
  112. package/dist/scripts/shared/format/format.js +0 -18
  113. package/dist/scripts/shared/format/format.js.map +0 -1
  114. package/dist/scripts/shared/git-ops/git-ops.d.ts +0 -90
  115. package/dist/scripts/shared/git-ops/git-ops.d.ts.map +0 -1
  116. package/dist/scripts/shared/git-ops/git-ops.js +0 -190
  117. package/dist/scripts/shared/git-ops/git-ops.js.map +0 -1
  118. package/dist/scripts/shared/http/http.d.ts +0 -54
  119. package/dist/scripts/shared/http/http.d.ts.map +0 -1
  120. package/dist/scripts/shared/http/http.js +0 -76
  121. package/dist/scripts/shared/http/http.js.map +0 -1
  122. package/dist/scripts/shared/notify/notify.d.ts +0 -46
  123. package/dist/scripts/shared/notify/notify.d.ts.map +0 -1
  124. package/dist/scripts/shared/notify/notify.js +0 -88
  125. package/dist/scripts/shared/notify/notify.js.map +0 -1
  126. package/dist/scripts/shared/preflight/preflight.d.ts +0 -40
  127. package/dist/scripts/shared/preflight/preflight.d.ts.map +0 -1
  128. package/dist/scripts/shared/preflight/preflight.js +0 -96
  129. package/dist/scripts/shared/preflight/preflight.js.map +0 -1
  130. package/dist/scripts/shared/progress/progress.d.ts +0 -75
  131. package/dist/scripts/shared/progress/progress.d.ts.map +0 -1
  132. package/dist/scripts/shared/progress/progress.js +0 -210
  133. package/dist/scripts/shared/progress/progress.js.map +0 -1
  134. package/dist/scripts/shared/prompt/prompt.d.ts +0 -58
  135. package/dist/scripts/shared/prompt/prompt.d.ts.map +0 -1
  136. package/dist/scripts/shared/prompt/prompt.js +0 -123
  137. package/dist/scripts/shared/prompt/prompt.js.map +0 -1
  138. package/dist/scripts/shared/pull-request/bitbucket/bitbucket.d.ts +0 -82
  139. package/dist/scripts/shared/pull-request/bitbucket/bitbucket.d.ts.map +0 -1
  140. package/dist/scripts/shared/pull-request/bitbucket/bitbucket.js +0 -301
  141. package/dist/scripts/shared/pull-request/bitbucket/bitbucket.js.map +0 -1
  142. package/dist/scripts/shared/pull-request/github/github.d.ts +0 -72
  143. package/dist/scripts/shared/pull-request/github/github.d.ts.map +0 -1
  144. package/dist/scripts/shared/pull-request/github/github.js +0 -226
  145. package/dist/scripts/shared/pull-request/github/github.js.map +0 -1
  146. package/dist/scripts/shared/pull-request/gitlab/gitlab.d.ts +0 -74
  147. package/dist/scripts/shared/pull-request/gitlab/gitlab.d.ts.map +0 -1
  148. package/dist/scripts/shared/pull-request/gitlab/gitlab.js +0 -220
  149. package/dist/scripts/shared/pull-request/gitlab/gitlab.js.map +0 -1
  150. package/dist/scripts/shared/pull-request/post-pr/post-pr.d.ts +0 -31
  151. package/dist/scripts/shared/pull-request/post-pr/post-pr.d.ts.map +0 -1
  152. package/dist/scripts/shared/pull-request/post-pr/post-pr.js +0 -61
  153. package/dist/scripts/shared/pull-request/post-pr/post-pr.js.map +0 -1
  154. package/dist/scripts/shared/pull-request/pr-body/pr-body.d.ts +0 -40
  155. package/dist/scripts/shared/pull-request/pr-body/pr-body.d.ts.map +0 -1
  156. package/dist/scripts/shared/pull-request/pr-body/pr-body.js +0 -84
  157. package/dist/scripts/shared/pull-request/pr-body/pr-body.js.map +0 -1
  158. package/dist/scripts/shared/pull-request/rework-comment/rework-comment.d.ts +0 -23
  159. package/dist/scripts/shared/pull-request/rework-comment/rework-comment.d.ts.map +0 -1
  160. package/dist/scripts/shared/pull-request/rework-comment/rework-comment.js +0 -30
  161. package/dist/scripts/shared/pull-request/rework-comment/rework-comment.js.map +0 -1
  162. package/dist/scripts/shared/remote/remote.d.ts +0 -41
  163. package/dist/scripts/shared/remote/remote.d.ts.map +0 -1
  164. package/dist/scripts/shared/remote/remote.js +0 -227
  165. package/dist/scripts/shared/remote/remote.js.map +0 -1
  166. package/dist/types/board.d.ts +0 -13
  167. package/dist/types/board.d.ts.map +0 -1
  168. package/dist/types/board.js +0 -5
  169. package/dist/types/board.js.map +0 -1
  170. package/dist/types/index.d.ts +0 -4
  171. package/dist/types/index.d.ts.map +0 -1
  172. package/dist/types/index.js +0 -2
  173. package/dist/types/index.js.map +0 -1
  174. package/dist/types/remote.d.ts +0 -55
  175. package/dist/types/remote.d.ts.map +0 -1
  176. package/dist/types/remote.js +0 -5
  177. package/dist/types/remote.js.map +0 -1
  178. package/dist/utils/parse-json/parse-json.d.ts +0 -20
  179. package/dist/utils/parse-json/parse-json.d.ts.map +0 -1
  180. package/dist/utils/parse-json/parse-json.js +0 -27
  181. package/dist/utils/parse-json/parse-json.js.map +0 -1
@@ -1,291 +0,0 @@
1
- /**
2
- * Clancy GitHub Issues board script.
3
- *
4
- * Fetches an issue from GitHub Issues REST API, creates branches,
5
- * invokes Claude, pushes feature branches, and creates PRs.
6
- *
7
- * Note: GitHub Issues endpoint returns both issues AND pull requests.
8
- * This script filters out PRs explicitly.
9
- */
10
- import { z } from 'zod/mini';
11
- import { githubIssuesResponseSchema } from '../../../schemas/github-issues.js';
12
- import { GITHUB_API, githubHeaders, pingEndpoint, } from '../../../scripts/shared/http/http.js';
13
- /** Schema for the `GET /user` response. */
14
- const githubUserSchema = z.object({
15
- login: z.string(),
16
- });
17
- const SAFE_REPO_PATTERN = /^[a-zA-Z0-9_.-]+\/[a-zA-Z0-9_.-]+$/;
18
- /** Cached username to avoid repeated /user calls. */
19
- let cachedUsername;
20
- /** Reset the cached username. Exported for testing only. */
21
- export function resetUsernameCache() {
22
- cachedUsername = undefined;
23
- }
24
- /**
25
- * Validate that a GitHub repo string is in `owner/repo` format.
26
- *
27
- * @param repo - The repository string to validate.
28
- * @returns `true` if the string matches `owner/repo` with safe characters.
29
- */
30
- export function isValidRepo(repo) {
31
- return SAFE_REPO_PATTERN.test(repo);
32
- }
33
- /**
34
- * Ping the GitHub API to verify connectivity and credentials.
35
- *
36
- * @param token - The GitHub personal access token.
37
- * @param repo - The repository in `owner/repo` format.
38
- * @returns An object with `ok` and optional `error` message.
39
- */
40
- export async function pingGitHub(token, repo) {
41
- return pingEndpoint(`${GITHUB_API}/repos/${repo}`, githubHeaders(token), {
42
- 401: '✗ GitHub auth failed — check GITHUB_TOKEN',
43
- 403: '✗ GitHub permission denied',
44
- 404: `✗ GitHub repo "${repo}" not found`,
45
- }, '✗ Could not reach GitHub — check network');
46
- }
47
- /**
48
- * Resolve the authenticated GitHub username from the token.
49
- *
50
- * Uses `GET /user` and caches the result for the lifetime of the process.
51
- * Falls back to `@me` if the API call fails (classic PATs support `@me`).
52
- *
53
- * Fine-grained PATs do NOT resolve `@me` in the Issues API `assignee` param,
54
- * so this function ensures we always have the real username.
55
- *
56
- * @param token - The GitHub personal access token.
57
- * @returns The GitHub username, or `@me` as a fallback.
58
- */
59
- export async function resolveUsername(token, apiBase) {
60
- if (cachedUsername)
61
- return cachedUsername;
62
- try {
63
- const response = await fetch(`${apiBase ?? GITHUB_API}/user`, {
64
- headers: githubHeaders(token),
65
- });
66
- if (!response.ok) {
67
- const hint = response.status === 401 || response.status === 403
68
- ? ' Fine-grained PATs need "Account permissions → read" (or classic PATs need read:user scope).'
69
- : '';
70
- console.warn(`⚠ GitHub /user returned HTTP ${response.status} — falling back to @me.${hint}`);
71
- return '@me';
72
- }
73
- const json = await response.json();
74
- const parsed = githubUserSchema.safeParse(json);
75
- if (parsed.success) {
76
- cachedUsername = parsed.data.login;
77
- return cachedUsername;
78
- }
79
- console.warn('⚠ Unexpected GitHub /user response — falling back to @me');
80
- }
81
- catch (err) {
82
- console.warn(`⚠ GitHub /user request failed: ${err instanceof Error ? err.message : String(err)} — falling back to @me`);
83
- }
84
- return '@me';
85
- }
86
- /**
87
- * Fetch the next available issue from GitHub Issues.
88
- *
89
- * Requests extra results to account for PR pollution (GitHub Issues endpoint
90
- * returns PRs too), then filters to real issues only.
91
- *
92
- * @param token - The GitHub personal access token.
93
- * @param repo - The repository in `owner/repo` format.
94
- * @param label - Optional label to filter issues.
95
- * @param username - The GitHub username for assignee filtering (resolved via {@link resolveUsername}).
96
- * @returns The fetched ticket with optional milestone, or `undefined` if none available.
97
- */
98
- export async function fetchIssue(token, repo, label, username) {
99
- const results = await fetchIssues(token, repo, label, username, false, 1);
100
- return results[0];
101
- }
102
- /**
103
- * Fetch multiple candidate issues from GitHub Issues.
104
- *
105
- * @param token - The GitHub personal access token.
106
- * @param repo - The repository in `owner/repo` format.
107
- * @param label - Optional label to filter issues.
108
- * @param username - The GitHub username for assignee filtering.
109
- * @param excludeHitl - If `true`, excludes issues with the `clancy:hitl` label (client-side).
110
- * @param limit - Maximum number of results to return (default: 5).
111
- * @returns Array of fetched tickets (may be empty).
112
- */
113
- export async function fetchIssues(token, repo, label, username, excludeHitl, limit = 5) {
114
- let response;
115
- const params = new URLSearchParams({
116
- state: 'open',
117
- assignee: username ?? '@me',
118
- per_page: '10',
119
- });
120
- if (label)
121
- params.set('labels', label);
122
- try {
123
- response = await fetch(`${GITHUB_API}/repos/${repo}/issues?${params}`, {
124
- headers: githubHeaders(token),
125
- });
126
- }
127
- catch (err) {
128
- console.warn(`⚠ GitHub API request failed: ${err instanceof Error ? err.message : String(err)}`);
129
- return [];
130
- }
131
- if (!response.ok) {
132
- console.warn(`⚠ GitHub API returned HTTP ${response.status}`);
133
- return [];
134
- }
135
- let json;
136
- try {
137
- json = await response.json();
138
- }
139
- catch {
140
- console.warn('⚠ GitHub API returned invalid JSON');
141
- return [];
142
- }
143
- const parsed = githubIssuesResponseSchema.safeParse(json);
144
- if (!parsed.success) {
145
- console.warn(`⚠ Unexpected GitHub response shape: ${parsed.error.message}`);
146
- return [];
147
- }
148
- // Filter out pull requests
149
- let issues = parsed.data.filter((item) => !item.pull_request);
150
- // HITL/AFK filtering: exclude issues with clancy:hitl label
151
- // GitHub Issues API doesn't support label exclusion natively, so filter client-side.
152
- if (excludeHitl) {
153
- issues = issues.filter((issue) => !issue.labels?.some((l) => l.name === 'clancy:hitl'));
154
- }
155
- return issues.slice(0, limit).map((issue) => ({
156
- key: `#${issue.number}`,
157
- title: issue.title,
158
- description: issue.body ?? '',
159
- provider: 'github',
160
- milestone: issue.milestone?.title,
161
- }));
162
- }
163
- /**
164
- * Check whether a GitHub issue is blocked by unresolved blockers.
165
- *
166
- * Parses the issue body for `Blocked by #N` lines and checks if any
167
- * of those issues are still open.
168
- *
169
- * @param token - The GitHub personal access token.
170
- * @param repo - The repository in `owner/repo` format.
171
- * @param issueNumber - The issue number to check.
172
- * @param body - The issue body text.
173
- * @returns `true` if any blocker is unresolved, `false` otherwise.
174
- */
175
- export async function fetchBlockerStatus(token, repo, issueNumber, body) {
176
- if (!isValidRepo(repo))
177
- return false;
178
- // Parse "Blocked by #N" references from the body
179
- const blockerPattern = /Blocked by #(\d+)/gi;
180
- const blockerNumbers = new Set();
181
- let match;
182
- while ((match = blockerPattern.exec(body)) !== null) {
183
- const num = parseInt(match[1], 10);
184
- if (!Number.isNaN(num) && num !== issueNumber) {
185
- blockerNumbers.add(num);
186
- }
187
- }
188
- if (!blockerNumbers.size)
189
- return false;
190
- try {
191
- for (const blockerNum of blockerNumbers) {
192
- const response = await fetch(`${GITHUB_API}/repos/${repo}/issues/${blockerNum}`, { headers: githubHeaders(token) });
193
- if (!response.ok)
194
- continue;
195
- const json = (await response.json());
196
- // Short-circuit: one unresolved blocker is enough
197
- if (json.state !== 'closed')
198
- return true;
199
- }
200
- return false;
201
- }
202
- catch {
203
- return false;
204
- }
205
- }
206
- /**
207
- * Fetch the children status of a GitHub parent issue (dual-mode).
208
- *
209
- * Tries the `Epic: #{parentNumber}` text convention first. If no results,
210
- * falls back to the native `Parent: #{parentNumber}` convention for
211
- * backward compatibility with pre-v0.6.0 children.
212
- *
213
- * @param token - The GitHub personal access token.
214
- * @param repo - The repository in `owner/repo` format.
215
- * @param parentNumber - The parent issue number.
216
- * @returns The children status, or `undefined` on failure.
217
- */
218
- export async function fetchChildrenStatus(token, repo, parentNumber) {
219
- if (!isValidRepo(repo))
220
- return undefined;
221
- try {
222
- // Mode 1: Try Epic: text convention
223
- const epicTextResult = await fetchChildrenByBodyRef(token, repo, `Epic: #${parentNumber}`);
224
- if (epicTextResult && epicTextResult.total > 0)
225
- return epicTextResult;
226
- // Mode 2: Fall back to native Parent: convention
227
- return await fetchChildrenByBodyRef(token, repo, `Parent: #${parentNumber}`);
228
- }
229
- catch {
230
- return undefined;
231
- }
232
- }
233
- /**
234
- * Fetch children status by searching for a body reference string.
235
- *
236
- * @param token - The GitHub personal access token.
237
- * @param repo - The repository in `owner/repo` format.
238
- * @param bodyRef - The body reference string to search for.
239
- * @returns The children status, or `undefined` on failure.
240
- */
241
- async function fetchChildrenByBodyRef(token, repo, bodyRef) {
242
- // Use GitHub Search API with total_count for accurate counts.
243
- // Two queries: one for all children, one for open (incomplete) children.
244
- const headers = githubHeaders(token);
245
- const allQuery = `"${bodyRef}" repo:${repo} is:issue`;
246
- const allParams = new URLSearchParams({ q: allQuery, per_page: '1' });
247
- const allResponse = await fetch(`${GITHUB_API}/search/issues?${allParams}`, {
248
- headers,
249
- });
250
- if (!allResponse.ok)
251
- return undefined;
252
- const allResult = (await allResponse.json());
253
- const total = allResult.total_count ?? 0;
254
- if (total === 0)
255
- return { total: 0, incomplete: 0 };
256
- const openQuery = `"${bodyRef}" repo:${repo} is:issue is:open`;
257
- const openParams = new URLSearchParams({ q: openQuery, per_page: '1' });
258
- const openResponse = await fetch(`${GITHUB_API}/search/issues?${openParams}`, { headers });
259
- if (!openResponse.ok)
260
- return { total, incomplete: total }; // assume all open on failure
261
- const openResult = (await openResponse.json());
262
- const incomplete = openResult.total_count ?? 0;
263
- return { total, incomplete };
264
- }
265
- /**
266
- * Close a GitHub issue.
267
- *
268
- * @param token - The GitHub personal access token.
269
- * @param repo - The repository in `owner/repo` format.
270
- * @param issueNumber - The issue number to close.
271
- * @returns `true` if the issue was closed successfully.
272
- */
273
- export async function closeIssue(token, repo, issueNumber) {
274
- if (!isValidRepo(repo))
275
- return false;
276
- try {
277
- const response = await fetch(`${GITHUB_API}/repos/${repo}/issues/${issueNumber}`, {
278
- method: 'PATCH',
279
- headers: {
280
- ...githubHeaders(token),
281
- 'Content-Type': 'application/json',
282
- },
283
- body: JSON.stringify({ state: 'closed' }),
284
- });
285
- return response.ok;
286
- }
287
- catch {
288
- return false;
289
- }
290
- }
291
- //# sourceMappingURL=github.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"github.js","sourceRoot":"","sources":["../../../../src/scripts/board/github/github.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,OAAO,EAAE,CAAC,EAAE,MAAM,UAAU,CAAC;AAE7B,OAAO,EAAE,0BAA0B,EAAE,MAAM,4BAA4B,CAAC;AACxE,OAAO,EACL,UAAU,EACV,aAAa,EACb,YAAY,GACb,MAAM,+BAA+B,CAAC;AAIvC,2CAA2C;AAC3C,MAAM,gBAAgB,GAAG,CAAC,CAAC,MAAM,CAAC;IAChC,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE;CAClB,CAAC,CAAC;AAEH,MAAM,iBAAiB,GAAG,oCAAoC,CAAC;AAE/D,qDAAqD;AACrD,IAAI,cAAkC,CAAC;AAEvC,4DAA4D;AAC5D,MAAM,UAAU,kBAAkB;IAChC,cAAc,GAAG,SAAS,CAAC;AAC7B,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,WAAW,CAAC,IAAY;IACtC,OAAO,iBAAiB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACtC,CAAC;AAED;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAAU,UAAU,CAC9B,KAAa,EACb,IAAY;IAEZ,OAAO,YAAY,CACjB,GAAG,UAAU,UAAU,IAAI,EAAE,EAC7B,aAAa,CAAC,KAAK,CAAC,E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C;IACrB,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,KAAK,CAAC;IACf,CAAC;AACH,CAAC"}
@@ -1,139 +0,0 @@
1
- import type { PingResult } from '../../../scripts/shared/http/http.js';
2
- import type { Ticket } from '../../../types/index.js';
3
- /**
4
- * Build Jira Basic auth header value.
5
- *
6
- * @param user - The Jira username (email).
7
- * @param token - The Jira API token.
8
- * @returns The Base64-encoded `user:token` string for Basic auth.
9
- */
10
- export declare function buildAuthHeader(user: string, token: string): string;
11
- /**
12
- * Validate that a user-controlled value is safe for JQL injection.
13
- *
14
- * @param value - The value to validate.
15
- * @returns `true` if the value matches the safe pattern.
16
- */
17
- export declare function isSafeJqlValue(value: string): boolean;
18
- /**
19
- * Ping the Jira API to verify connectivity and credentials.
20
- *
21
- * @param baseUrl - The Jira Cloud base URL.
22
- * @param projectKey - The Jira project key.
23
- * @param auth - The Base64-encoded Basic auth string.
24
- * @returns An object with `ok` and optional `error` message.
25
- *
26
- * @example
27
- * ```ts
28
- * const result = await pingJira('https://example.atlassian.net', 'PROJ', authHeader);
29
- * if (!result.ok) console.error(result.error);
30
- * ```
31
- */
32
- export declare function pingJira(baseUrl: string, projectKey: string, auth: string): Promise<PingResult>;
33
- /**
34
- * Build the JQL query for fetching the next ticket.
35
- *
36
- * @param projectKey - The Jira project key.
37
- * @param status - The JQL status to filter by (default: `"To Do"`).
38
- * @param sprint - If set, adds an open sprint filter.
39
- * @param label - If set, adds a label filter.
40
- * @returns The JQL query string.
41
- */
42
- export declare function buildJql(projectKey: string, status: string, sprint?: string, label?: string, excludeHitl?: boolean): string;
43
- /**
44
- * Extract all text strings from a Jira ADF (Atlassian Document Format) description.
45
- *
46
- * Recursively walks the ADF tree and collects all string values.
47
- *
48
- * @param adf - The ADF description object (or `undefined`).
49
- * @returns A single string with all text content joined by spaces.
50
- */
51
- export declare function extractAdfText(adf: unknown): string;
52
- /**
53
- * Fetch the next available ticket from Jira.
54
- *
55
- * @param baseUrl - The Jira Cloud base URL.
56
- * @param auth - The Base64-encoded Basic auth string.
57
- * @param projectKey - The Jira project key.
58
- * @param status - The JQL status to filter by.
59
- * @param sprint - Optional sprint filter.
60
- * @param label - Optional label filter.
61
- * @returns The fetched ticket, or `undefined` if no tickets are available.
62
- */
63
- export declare function fetchTicket(baseUrl: string, auth: string, projectKey: string, status: string, sprint?: string, label?: string): Promise<(Ticket & {
64
- epicKey?: string;
65
- blockers: string[];
66
- }) | undefined>;
67
- /** Jira ticket with epic and blocker info. */
68
- export type JiraTicket = Ticket & {
69
- epicKey?: string;
70
- blockers: string[];
71
- };
72
- /**
73
- * Fetch multiple candidate tickets from Jira.
74
- *
75
- * @param baseUrl - The Jira Cloud base URL.
76
- * @param auth - The Base64-encoded Basic auth string.
77
- * @param projectKey - The Jira project key.
78
- * @param status - The JQL status to filter by.
79
- * @param sprint - Optional sprint filter.
80
- * @param label - Optional label filter.
81
- * @param excludeHitl - If `true`, excludes tickets with the `clancy:hitl` label.
82
- * @param limit - Maximum number of results to return (default: 5).
83
- * @returns Array of fetched tickets (may be empty).
84
- */
85
- export declare function fetchTickets(baseUrl: string, auth: string, projectKey: string, status: string, sprint?: string, label?: string, excludeHitl?: boolean, limit?: number): Promise<JiraTicket[]>;
86
- /**
87
- * Check whether a Jira issue is blocked by unresolved blockers.
88
- *
89
- * Fetches the issue's links and checks for inward "Blocks" relationships
90
- * where the blocking issue's statusCategory is not "done".
91
- *
92
- * @param baseUrl - The Jira Cloud base URL.
93
- * @param auth - The Base64-encoded Basic auth string.
94
- * @param key - The Jira issue key (e.g., `'PROJ-123'`).
95
- * @returns `true` if any blocker is unresolved, `false` otherwise.
96
- */
97
- export declare function fetchBlockerStatus(baseUrl: string, auth: string, key: string): Promise<boolean>;
98
- /** Result of checking children status for an epic. */
99
- export type ChildrenStatus = {
100
- total: number;
101
- incomplete: number;
102
- };
103
- /**
104
- * Fetch the children status of a Jira epic (dual-mode).
105
- *
106
- * Tries the `Epic: {key}` text convention first (children with "Epic: PROJ-100"
107
- * in their description). If no results, falls back to the native `parent = {key}`
108
- * JQL query for backward compatibility with pre-v0.6.0 children.
109
- *
110
- * @param baseUrl - The Jira Cloud base URL.
111
- * @param auth - The Base64-encoded Basic auth string.
112
- * @param parentKey - The parent issue key (e.g., `'PROJ-100'`).
113
- * @returns The children status, or `undefined` on failure.
114
- */
115
- export declare function fetchChildrenStatus(baseUrl: string, auth: string, parentKey: string): Promise<ChildrenStatus | undefined>;
116
- /**
117
- * Look up a Jira transition ID by status name.
118
- *
119
- * @param baseUrl - The Jira Cloud base URL.
120
- * @param auth - The Base64-encoded Basic auth string.
121
- * @param issueKey - The Jira issue key (e.g., `'PROJ-123'`).
122
- * @param statusName - The target status name (e.g., `'In Progress'`).
123
- * @returns The transition ID, or `undefined` if not found.
124
- */
125
- export declare function lookupTransitionId(baseUrl: string, auth: string, issueKey: string, statusName: string): Promise<string | undefined>;
126
- /**
127
- * Transition a Jira issue to a new status.
128
- *
129
- * Fetches available transitions and executes the one matching the target status name.
130
- * Best-effort — never throws on failure.
131
- *
132
- * @param baseUrl - The Jira Cloud base URL.
133
- * @param auth - The Base64-encoded Basic auth string.
134
- * @param issueKey - The Jira issue key (e.g., `'PROJ-123'`).
135
- * @param statusName - The target status name (e.g., `'In Progress'`).
136
- * @returns `true` if the transition succeeded.
137
- */
138
- export declare function transitionIssue(baseUrl: string, auth: string, issueKey: string, statusName: string): Promise<boolean>;
139
- //# sourceMappingURL=jira.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"jira.d.ts","sourceRoot":"","sources":["../../../../src/scripts/board/jira/jira.ts"],"names":[],"mappings":"AAeA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,+BAA+B,CAAC;AAChE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAK/C;;;;;;GAMG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,MAAM,CAEnE;AAED;;;;;GAKG;A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