chief-clancy 0.5.2 → 0.5.4
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 +3 -3
- package/dist/bundle/clancy-afk.js +2 -2
- package/dist/bundle/clancy-once.js +29 -28
- package/dist/schemas/env.d.ts +27 -0
- package/dist/schemas/env.d.ts.map +1 -1
- package/dist/schemas/env.js +8 -0
- package/dist/schemas/env.js.map +1 -1
- package/dist/scripts/afk/afk.d.ts.map +1 -1
- package/dist/scripts/afk/afk.js +1 -8
- package/dist/scripts/afk/afk.js.map +1 -1
- package/dist/scripts/board/github/github.d.ts +18 -1
- package/dist/scripts/board/github/github.d.ts.map +1 -1
- package/dist/scripts/board/github/github.js +55 -4
- package/dist/scripts/board/github/github.js.map +1 -1
- package/dist/scripts/board/linear/linear.d.ts.map +1 -1
- package/dist/scripts/board/linear/linear.js +35 -4
- package/dist/scripts/board/linear/linear.js.map +1 -1
- package/dist/scripts/once/once.d.ts.map +1 -1
- package/dist/scripts/once/once.js +208 -37
- package/dist/scripts/once/once.js.map +1 -1
- package/dist/scripts/shared/env-schema/env-schema.d.ts.map +1 -1
- package/dist/scripts/shared/env-schema/env-schema.js +3 -2
- package/dist/scripts/shared/env-schema/env-schema.js.map +1 -1
- package/dist/scripts/shared/format/format.d.ts +11 -0
- package/dist/scripts/shared/format/format.d.ts.map +1 -0
- package/dist/scripts/shared/format/format.js +18 -0
- package/dist/scripts/shared/format/format.js.map +1 -0
- package/dist/scripts/shared/git-ops/git-ops.d.ts +9 -0
- package/dist/scripts/shared/git-ops/git-ops.d.ts.map +1 -1
- package/dist/scripts/shared/git-ops/git-ops.js +20 -0
- package/dist/scripts/shared/git-ops/git-ops.js.map +1 -1
- package/dist/scripts/shared/http/http.d.ts +2 -0
- package/dist/scripts/shared/http/http.d.ts.map +1 -1
- package/dist/scripts/shared/http/http.js +2 -0
- package/dist/scripts/shared/http/http.js.map +1 -1
- package/dist/scripts/shared/progress/progress.d.ts +3 -2
- package/dist/scripts/shared/progress/progress.d.ts.map +1 -1
- package/dist/scripts/shared/progress/progress.js +1 -1
- package/dist/scripts/shared/progress/progress.js.map +1 -1
- package/dist/scripts/shared/pull-request/bitbucket/bitbucket.d.ts +38 -0
- package/dist/scripts/shared/pull-request/bitbucket/bitbucket.d.ts.map +1 -0
- package/dist/scripts/shared/pull-request/bitbucket/bitbucket.js +69 -0
- package/dist/scripts/shared/pull-request/bitbucket/bitbucket.js.map +1 -0
- package/dist/scripts/shared/pull-request/github/github.d.ts +15 -0
- package/dist/scripts/shared/pull-request/github/github.d.ts.map +1 -0
- package/dist/scripts/shared/pull-request/github/github.js +29 -0
- package/dist/scripts/shared/pull-request/github/github.js.map +1 -0
- package/dist/scripts/shared/pull-request/gitlab/gitlab.d.ts +23 -0
- package/dist/scripts/shared/pull-request/gitlab/gitlab.d.ts.map +1 -0
- package/dist/scripts/shared/pull-request/gitlab/gitlab.js +27 -0
- package/dist/scripts/shared/pull-request/gitlab/gitlab.js.map +1 -0
- package/dist/scripts/shared/pull-request/post-pr/post-pr.d.ts +31 -0
- package/dist/scripts/shared/pull-request/post-pr/post-pr.d.ts.map +1 -0
- package/dist/scripts/shared/pull-request/post-pr/post-pr.js +61 -0
- package/dist/scripts/shared/pull-request/post-pr/post-pr.js.map +1 -0
- package/dist/scripts/shared/pull-request/pr-body/pr-body.d.ts +19 -0
- package/dist/scripts/shared/pull-request/pr-body/pr-body.d.ts.map +1 -0
- package/dist/scripts/shared/pull-request/pr-body/pr-body.js +35 -0
- package/dist/scripts/shared/pull-request/pr-body/pr-body.js.map +1 -0
- package/dist/scripts/shared/remote/remote.d.ts +41 -0
- package/dist/scripts/shared/remote/remote.d.ts.map +1 -0
- package/dist/scripts/shared/remote/remote.js +227 -0
- package/dist/scripts/shared/remote/remote.js.map +1 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/remote.d.ts +44 -0
- package/dist/types/remote.d.ts.map +1 -0
- package/dist/types/remote.js +5 -0
- package/dist/types/remote.js.map +1 -0
- package/package.json +1 -1
- package/src/roles/planner/workflows/plan.md +7 -1
- package/src/roles/reviewer/workflows/review.md +3 -1
- package/src/roles/reviewer/workflows/status.md +6 -1
- package/src/roles/setup/workflows/init.md +91 -0
- package/src/roles/setup/workflows/scaffold.md +27 -0
- package/src/roles/setup/workflows/settings.md +62 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,aAAa,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AACxD,YAAY,EACV,WAAW,EACX,SAAS,EACT,OAAO,EACP,SAAS,EACT,SAAS,GACV,MAAM,kBAAkB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,aAAa,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AACxD,YAAY,EACV,WAAW,EACX,gBAAgB,EAChB,cAAc,EACd,UAAU,GACX,MAAM,aAAa,CAAC;AACrB,YAAY,EACV,WAAW,EACX,SAAS,EACT,OAAO,EACP,SAAS,EACT,SAAS,GACV,MAAM,kBAAkB,CAAC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Remote git hosting types shared across remote detection and PR creation.
|
|
3
|
+
*/
|
|
4
|
+
/** Supported git hosting platforms. */
|
|
5
|
+
export type GitPlatform = 'github' | 'gitlab' | 'bitbucket' | 'bitbucket-server' | 'azure' | 'unknown';
|
|
6
|
+
/** Parsed remote URL with platform and path info. */
|
|
7
|
+
export type RemoteInfo = {
|
|
8
|
+
host: 'github';
|
|
9
|
+
owner: string;
|
|
10
|
+
repo: string;
|
|
11
|
+
hostname: string;
|
|
12
|
+
} | {
|
|
13
|
+
host: 'gitlab';
|
|
14
|
+
projectPath: string;
|
|
15
|
+
hostname: string;
|
|
16
|
+
} | {
|
|
17
|
+
host: 'bitbucket';
|
|
18
|
+
workspace: string;
|
|
19
|
+
repoSlug: string;
|
|
20
|
+
hostname: string;
|
|
21
|
+
} | {
|
|
22
|
+
host: 'bitbucket-server';
|
|
23
|
+
projectKey: string;
|
|
24
|
+
repoSlug: string;
|
|
25
|
+
hostname: string;
|
|
26
|
+
} | {
|
|
27
|
+
host: 'azure' | 'unknown';
|
|
28
|
+
url: string;
|
|
29
|
+
} | {
|
|
30
|
+
host: 'none';
|
|
31
|
+
};
|
|
32
|
+
/** Result of a PR/MR creation attempt. */
|
|
33
|
+
export type PrCreationResult = {
|
|
34
|
+
ok: true;
|
|
35
|
+
url: string;
|
|
36
|
+
number: number;
|
|
37
|
+
} | {
|
|
38
|
+
ok: false;
|
|
39
|
+
error: string;
|
|
40
|
+
alreadyExists?: boolean;
|
|
41
|
+
};
|
|
42
|
+
/** Progress log status values. */
|
|
43
|
+
export type ProgressStatus = 'DONE' | 'SKIPPED' | 'PR_CREATED' | 'PUSHED' | 'PUSH_FAILED' | 'LOCAL' | 'PLAN' | 'APPROVE' | 'REWORK';
|
|
44
|
+
//# sourceMappingURL=remote.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"remote.d.ts","sourceRoot":"","sources":["../../src/types/remote.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,uCAAuC;AACvC,MAAM,MAAM,WAAW,GACnB,QAAQ,GACR,QAAQ,GACR,WAAW,GACX,kBAAkB,GAClB,OAAO,GACP,SAAS,CAAC;AAEd,qDAAqD;AACrD,MAAM,MAAM,UAAU,GAClB;IACE,IAAI,EAAE,QAAQ,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;CAClB,GACD;IACE,IAAI,EAAE,QAAQ,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;CAClB,GACD;IACE,IAAI,EAAE,WAAW,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;CAClB,GACD;IACE,IAAI,EAAE,kBAAkB,CAAC;IACzB,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;CAClB,GACD;IACE,IAAI,EAAE,OAAO,GAAG,SAAS,CAAC;IAC1B,GAAG,EAAE,MAAM,CAAC;CACb,GACD;IACE,IAAI,EAAE,MAAM,CAAC;CACd,CAAC;AAEN,0CAA0C;AAC1C,MAAM,MAAM,gBAAgB,GACxB;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,GAAG,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,GACzC;IAAE,EAAE,EAAE,KAAK,CAAC;IAAC,KAAK,EAAE,MAAM,CAAC;IAAC,aAAa,CAAC,EAAE,OAAO,CAAA;CAAE,CAAC;AAE1D,kCAAkC;AAClC,MAAM,MAAM,cAAc,GACtB,MAAM,GACN,SAAS,GACT,YAAY,GACZ,QAAQ,GACR,aAAa,GACb,OAAO,GACP,MAAM,GACN,SAAS,GACT,QAAQ,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"remote.js","sourceRoot":"","sources":["../../src/types/remote.ts"],"names":[],"mappings":"AAAA;;GAEG"}
|
package/package.json
CHANGED
|
@@ -73,11 +73,17 @@ Note: include the `comment` field so we can check for existing plans and read fe
|
|
|
73
73
|
|
|
74
74
|
### GitHub Issues
|
|
75
75
|
|
|
76
|
+
First resolve the authenticated username (don't use `@me` — it breaks with fine-grained PATs):
|
|
77
|
+
```bash
|
|
78
|
+
GITHUB_USERNAME=$(curl -s -H "Authorization: Bearer $GITHUB_TOKEN" https://api.github.com/user | jq -r '.login')
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
Then fetch issues:
|
|
76
82
|
```bash
|
|
77
83
|
RESPONSE=$(curl -s \
|
|
78
84
|
-H "Authorization: Bearer $GITHUB_TOKEN" \
|
|
79
85
|
-H "X-GitHub-Api-Version: 2022-11-28" \
|
|
80
|
-
"https://api.github.com/repos/$GITHUB_REPO/issues?state=open&assignee
|
|
86
|
+
"https://api.github.com/repos/$GITHUB_REPO/issues?state=open&assignee=$GITHUB_USERNAME&labels=$CLANCY_PLAN_LABEL&per_page=<N>")
|
|
81
87
|
```
|
|
82
88
|
|
|
83
89
|
- `CLANCY_PLAN_LABEL` defaults to `needs-refinement` if not set
|
|
@@ -41,7 +41,9 @@ RESPONSE=$(curl -s \
|
|
|
41
41
|
-d '{"jql": "<jql as above>", "maxResults": 1, "fields": ["summary", "description", "issuelinks", "parent", "customfield_10014"]}')
|
|
42
42
|
```
|
|
43
43
|
|
|
44
|
-
**GitHub Issues:**
|
|
44
|
+
**GitHub Issues:** First resolve the authenticated username (don't use `@me` — it breaks with fine-grained PATs):
|
|
45
|
+
`GITHUB_USERNAME=$(curl -s -H "Authorization: Bearer $GITHUB_TOKEN" https://api.github.com/user | jq -r '.login')`
|
|
46
|
+
Then: `GET /repos/$GITHUB_REPO/issues?state=open&assignee=$GITHUB_USERNAME&labels=clancy&per_page=1` — filter out PRs (entries with `pull_request` key).
|
|
45
47
|
|
|
46
48
|
**Linear:** GraphQL `viewer.assignedIssues` with `filter: { state: { type: { eq: "unstarted" } }, team: { id: { eq: "$LINEAR_TEAM_ID" } }[, labels: { name: { eq: "$CLANCY_LABEL" } }] }` (label clause only if `CLANCY_LABEL` is set), `first: 1`, `orderBy: priority`
|
|
47
49
|
|
|
@@ -42,11 +42,16 @@ RESPONSE=$(curl -s \
|
|
|
42
42
|
```
|
|
43
43
|
|
|
44
44
|
**GitHub Issues:**
|
|
45
|
+
First resolve the authenticated username (don't use `@me` — it breaks with fine-grained PATs):
|
|
46
|
+
```bash
|
|
47
|
+
GITHUB_USERNAME=$(curl -s -H "Authorization: Bearer $GITHUB_TOKEN" https://api.github.com/user | jq -r '.login')
|
|
48
|
+
```
|
|
49
|
+
Then fetch issues:
|
|
45
50
|
```bash
|
|
46
51
|
RESPONSE=$(curl -s \
|
|
47
52
|
-H "Authorization: Bearer $GITHUB_TOKEN" \
|
|
48
53
|
-H "X-GitHub-Api-Version: 2022-11-28" \
|
|
49
|
-
"https://api.github.com/repos/$GITHUB_REPO/issues?state=open&assignee
|
|
54
|
+
"https://api.github.com/repos/$GITHUB_REPO/issues?state=open&assignee=$GITHUB_USERNAME&labels=clancy&per_page=3")
|
|
50
55
|
# Filter out PRs (entries with pull_request key)
|
|
51
56
|
```
|
|
52
57
|
|
|
@@ -207,6 +207,56 @@ Never silently continue with unverified credentials — the user must explicitly
|
|
|
207
207
|
|
|
208
208
|
---
|
|
209
209
|
|
|
210
|
+
### Q2c (Jira and Linear only): Git host token
|
|
211
|
+
|
|
212
|
+
When the board is **Jira** or **Linear**, Clancy needs a git host token to create pull requests after implementation. Skip this step entirely for **GitHub Issues** — the `GITHUB_TOKEN` collected in Q2 already covers PR creation.
|
|
213
|
+
|
|
214
|
+
Output:
|
|
215
|
+
|
|
216
|
+
```
|
|
217
|
+
Clancy can push your feature branch and create a pull request automatically.
|
|
218
|
+
Which git host does this project use?
|
|
219
|
+
|
|
220
|
+
[1] GitHub
|
|
221
|
+
[2] GitLab
|
|
222
|
+
[3] Bitbucket
|
|
223
|
+
[4] Skip — I'll push and create PRs manually
|
|
224
|
+
```
|
|
225
|
+
|
|
226
|
+
**If [1] GitHub:**
|
|
227
|
+
|
|
228
|
+
`Paste your GitHub personal access token: (needs repo scope — create at github.com/settings/tokens)`
|
|
229
|
+
|
|
230
|
+
Store as `GITHUB_TOKEN` in `.clancy/.env`.
|
|
231
|
+
|
|
232
|
+
Verify by calling `GET https://api.github.com/user` with `Authorization: Bearer {token}` and `X-GitHub-Api-Version: 2022-11-28`.
|
|
233
|
+
|
|
234
|
+
On success: `✅ GitHub connected — {login}`
|
|
235
|
+
On failure: offer re-enter or skip (same pattern as Q2b).
|
|
236
|
+
|
|
237
|
+
**If [2] GitLab:**
|
|
238
|
+
|
|
239
|
+
`Paste your GitLab personal access token: (needs api scope — create at gitlab.com/-/user_settings/personal_access_tokens)`
|
|
240
|
+
|
|
241
|
+
Store as `GITLAB_TOKEN` in `.clancy/.env`.
|
|
242
|
+
|
|
243
|
+
If the user is using a self-hosted GitLab instance, also ask:
|
|
244
|
+
`What's your GitLab API base URL? (e.g. https://gitlab.example.com/api/v4 — press Enter for gitlab.com)`
|
|
245
|
+
|
|
246
|
+
If a URL is entered, store as `CLANCY_GIT_API_URL` in `.clancy/.env` and `CLANCY_GIT_PLATFORM="gitlab"`.
|
|
247
|
+
If the user enters just a hostname or instance URL without `/api/v4`, append `/api/v4` automatically.
|
|
248
|
+
|
|
249
|
+
**If [3] Bitbucket:**
|
|
250
|
+
|
|
251
|
+
1. `What's your Bitbucket username? (your Atlassian account username)`
|
|
252
|
+
2. `Paste your Bitbucket app password: (needs repository:write scope — create at bitbucket.org/account/settings/app-passwords)`
|
|
253
|
+
|
|
254
|
+
Store as `BITBUCKET_USER` and `BITBUCKET_TOKEN` in `.clancy/.env`.
|
|
255
|
+
|
|
256
|
+
**If [4] Skip:** no git host token is written. Clancy will still implement tickets but leave the feature branch for the user to push and create PRs manually.
|
|
257
|
+
|
|
258
|
+
---
|
|
259
|
+
|
|
210
260
|
### Q3 (Jira only): Status name
|
|
211
261
|
|
|
212
262
|
Output:
|
|
@@ -315,6 +365,47 @@ You can always configure these later via `/clancy:settings`.
|
|
|
315
365
|
|
|
316
366
|
---
|
|
317
367
|
|
|
368
|
+
### Q3d-2 (Jira and Linear only): Review status
|
|
369
|
+
|
|
370
|
+
Only ask this if a git host token was configured in Q2c (i.e. the user didn't skip PR creation).
|
|
371
|
+
|
|
372
|
+
**GitHub:** Skip entirely — not applicable (GitHub Issues don't have workflow states).
|
|
373
|
+
|
|
374
|
+
**Jira:** Output:
|
|
375
|
+
|
|
376
|
+
```
|
|
377
|
+
When Clancy creates a pull request, it can transition the ticket to a review status.
|
|
378
|
+
|
|
379
|
+
What transition should Clancy use after creating a PR?
|
|
380
|
+
|
|
381
|
+
[1] In Review
|
|
382
|
+
[2] Ready for Review
|
|
383
|
+
[3] Enter a different value
|
|
384
|
+
[4] Skip — use the same status as completion (CLANCY_STATUS_DONE)
|
|
385
|
+
```
|
|
386
|
+
|
|
387
|
+
If [1]: store `CLANCY_STATUS_REVIEW="In Review"` in `.clancy/.env`.
|
|
388
|
+
If [2]: store `CLANCY_STATUS_REVIEW="Ready for Review"` in `.clancy/.env`.
|
|
389
|
+
If [3]: prompt for the value, store as `CLANCY_STATUS_REVIEW` in `.clancy/.env`. Wrap in double quotes.
|
|
390
|
+
If [4] or the user says "skip"/"none": skip — no `CLANCY_STATUS_REVIEW` line written (falls back to `CLANCY_STATUS_DONE`).
|
|
391
|
+
|
|
392
|
+
**Linear:** Output:
|
|
393
|
+
|
|
394
|
+
```
|
|
395
|
+
When Clancy creates a pull request, it can move the issue to a review state.
|
|
396
|
+
|
|
397
|
+
What state should Clancy move an issue to after creating a PR?
|
|
398
|
+
|
|
399
|
+
[1] In Review
|
|
400
|
+
[2] Ready for Review
|
|
401
|
+
[3] Enter a different value
|
|
402
|
+
[4] Skip — use the same state as completion (CLANCY_STATUS_DONE)
|
|
403
|
+
```
|
|
404
|
+
|
|
405
|
+
Same storage logic as Jira above.
|
|
406
|
+
|
|
407
|
+
---
|
|
408
|
+
|
|
318
409
|
### Q4: Base branch (auto-detect)
|
|
319
410
|
|
|
320
411
|
Silently detect the base branch — do not ask unless detection fails:
|
|
@@ -383,6 +383,18 @@ MAX_ITERATIONS=5
|
|
|
383
383
|
# "Done" can be any transition to a post-implementation status.
|
|
384
384
|
# CLANCY_STATUS_IN_PROGRESS="In Progress"
|
|
385
385
|
# CLANCY_STATUS_DONE="Done"
|
|
386
|
+
# CLANCY_STATUS_REVIEW="In Review" # used when creating a PR instead of merging locally
|
|
387
|
+
|
|
388
|
+
# ─── Optional: Git host (PR creation) ───────────────────────────────────────
|
|
389
|
+
# When a ticket has no parent epic, Clancy pushes the feature branch and creates
|
|
390
|
+
# a pull request instead of squash-merging locally. Requires a git host token.
|
|
391
|
+
# GitHub Issues users already have GITHUB_TOKEN above — no extra config needed.
|
|
392
|
+
# GITHUB_TOKEN=ghp_your-token # if your git host is GitHub
|
|
393
|
+
# GITLAB_TOKEN=glpat-your-token # if your git host is GitLab
|
|
394
|
+
# BITBUCKET_USER=your-username # if your git host is Bitbucket
|
|
395
|
+
# BITBUCKET_TOKEN=your-app-password # if your git host is Bitbucket
|
|
396
|
+
# CLANCY_GIT_PLATFORM=gitlab # override auto-detection (github/gitlab/bitbucket)
|
|
397
|
+
# CLANCY_GIT_API_URL=https://gitlab.example.com/api/v4 # self-hosted git API base URL
|
|
386
398
|
|
|
387
399
|
# ─── Optional: Planner queue ─────────────────────────────────────────────────
|
|
388
400
|
# Status for backlog tickets that /clancy:plan fetches from (default: Backlog)
|
|
@@ -419,6 +431,10 @@ GITHUB_REPO=owner/repo-name
|
|
|
419
431
|
# When an issue has a milestone, Clancy auto-creates milestone/{slug} from this branch.
|
|
420
432
|
CLANCY_BASE_BRANCH=main
|
|
421
433
|
|
|
434
|
+
# ─── PR creation ─────────────────────────────────────────────────────────────
|
|
435
|
+
# When an issue has no milestone, Clancy pushes the feature branch and creates a
|
|
436
|
+
# PR using your GITHUB_TOKEN above. No extra config needed for GitHub Issues users.
|
|
437
|
+
|
|
422
438
|
# ─── Loop ─────────────────────────────────────────────────────────────────────
|
|
423
439
|
# Max tickets to process per /clancy:run session (default: 20)
|
|
424
440
|
MAX_ITERATIONS=20
|
|
@@ -495,6 +511,17 @@ MAX_ITERATIONS=20
|
|
|
495
511
|
# "Done" can be any post-implementation state (e.g. "Ready for Review", "In Review").
|
|
496
512
|
# CLANCY_STATUS_IN_PROGRESS="In Progress"
|
|
497
513
|
# CLANCY_STATUS_DONE="Done"
|
|
514
|
+
# CLANCY_STATUS_REVIEW="In Review" # used when creating a PR instead of merging locally
|
|
515
|
+
|
|
516
|
+
# ─── Optional: Git host (PR creation) ───────────────────────────────────────
|
|
517
|
+
# When an issue has no parent, Clancy pushes the feature branch and creates a
|
|
518
|
+
# pull request instead of squash-merging locally. Requires a git host token.
|
|
519
|
+
# GITHUB_TOKEN=ghp_your-token # if your git host is GitHub
|
|
520
|
+
# GITLAB_TOKEN=glpat-your-token # if your git host is GitLab
|
|
521
|
+
# BITBUCKET_USER=your-username # if your git host is Bitbucket
|
|
522
|
+
# BITBUCKET_TOKEN=your-app-password # if your git host is Bitbucket
|
|
523
|
+
# CLANCY_GIT_PLATFORM=gitlab # override auto-detection (github/gitlab/bitbucket)
|
|
524
|
+
# CLANCY_GIT_API_URL=https://gitlab.example.com/api/v4 # self-hosted git API base URL
|
|
498
525
|
|
|
499
526
|
# ─── Optional: Notifications ──────────────────────────────────────────────────
|
|
500
527
|
# Webhook URL for Slack or Teams notifications on ticket completion
|
|
@@ -59,6 +59,7 @@ Jira
|
|
|
59
59
|
[B3] Label filter {CLANCY_LABEL if set, else off}
|
|
60
60
|
[B4] Pickup status {CLANCY_STATUS_IN_PROGRESS if set, else off}
|
|
61
61
|
[B5] Done status {CLANCY_STATUS_DONE if set, else off}
|
|
62
|
+
[B6] Review status {CLANCY_STATUS_REVIEW if set, else "uses Done status"}
|
|
62
63
|
|
|
63
64
|
{If GitHub:}
|
|
64
65
|
GitHub
|
|
@@ -69,6 +70,7 @@ Linear
|
|
|
69
70
|
[B1] Label filter {CLANCY_LABEL if set, else off}
|
|
70
71
|
[B2] Pickup status {CLANCY_STATUS_IN_PROGRESS if set, else off}
|
|
71
72
|
[B3] Done status {CLANCY_STATUS_DONE if set, else off}
|
|
73
|
+
[B4] Review status {CLANCY_STATUS_REVIEW if set, else "uses Done status"}
|
|
72
74
|
|
|
73
75
|
Roles
|
|
74
76
|
[R1] Planner {✅ enabled / ─ disabled}
|
|
@@ -82,6 +84,9 @@ Planner
|
|
|
82
84
|
{If Linear:}
|
|
83
85
|
[P1] Plan state type {CLANCY_PLAN_STATE_TYPE:-backlog}
|
|
84
86
|
|
|
87
|
+
Git Host (PR creation)
|
|
88
|
+
[H1] Git host token {platform: GitHub/GitLab/Bitbucket or "not set"}
|
|
89
|
+
|
|
85
90
|
Integrations
|
|
86
91
|
[I1] Figma MCP {enabled if FIGMA_API_KEY set, else not set}
|
|
87
92
|
[I2] Playwright {enabled if PLAYWRIGHT_ENABLED=true, else off}
|
|
@@ -232,6 +237,23 @@ If [2]: remove `CLANCY_STATUS_DONE` from `.clancy/.env`.
|
|
|
232
237
|
|
|
233
238
|
---
|
|
234
239
|
|
|
240
|
+
### [B6] Jira Review status (Jira only)
|
|
241
|
+
|
|
242
|
+
```
|
|
243
|
+
Jira Review status — current: {value or "uses Done status"}
|
|
244
|
+
When Clancy creates a pull request (instead of merging locally), it transitions
|
|
245
|
+
the ticket to this status. Falls back to CLANCY_STATUS_DONE if not set.
|
|
246
|
+
|
|
247
|
+
[1] Set status name
|
|
248
|
+
[2] Off (use Done status for PR flow too)
|
|
249
|
+
[3] Cancel
|
|
250
|
+
```
|
|
251
|
+
|
|
252
|
+
If [1]: prompt `What status name should Clancy use for In Review? (e.g. In Review, Ready for Review, Code Review)` then write `CLANCY_STATUS_REVIEW=<value>` to `.clancy/.env`.
|
|
253
|
+
If [2]: remove `CLANCY_STATUS_REVIEW` from `.clancy/.env`.
|
|
254
|
+
|
|
255
|
+
---
|
|
256
|
+
|
|
235
257
|
### [B1] Linear label filter (Linear only)
|
|
236
258
|
|
|
237
259
|
```
|
|
@@ -283,6 +305,23 @@ If [2]: remove `CLANCY_STATUS_DONE` from `.clancy/.env`.
|
|
|
283
305
|
|
|
284
306
|
---
|
|
285
307
|
|
|
308
|
+
### [B4] Linear Review status (Linear only)
|
|
309
|
+
|
|
310
|
+
```
|
|
311
|
+
Linear Review status — current: {value or "uses Done state"}
|
|
312
|
+
When Clancy creates a pull request (instead of merging locally), it moves
|
|
313
|
+
the issue to this state. Falls back to CLANCY_STATUS_DONE if not set.
|
|
314
|
+
|
|
315
|
+
[1] Set state name
|
|
316
|
+
[2] Off (use Done state for PR flow too)
|
|
317
|
+
[3] Cancel
|
|
318
|
+
```
|
|
319
|
+
|
|
320
|
+
If [1]: prompt `What workflow state name should Clancy use for In Review? (e.g. In Review, Ready for Review, Code Review)` then write `CLANCY_STATUS_REVIEW=<value>` to `.clancy/.env`.
|
|
321
|
+
If [2]: remove `CLANCY_STATUS_REVIEW` from `.clancy/.env`.
|
|
322
|
+
|
|
323
|
+
---
|
|
324
|
+
|
|
286
325
|
### [R1] Planner role
|
|
287
326
|
|
|
288
327
|
```
|
|
@@ -355,6 +394,28 @@ If [3]: prompt `What state type should /clancy:plan fetch from?` then write `CLA
|
|
|
355
394
|
|
|
356
395
|
---
|
|
357
396
|
|
|
397
|
+
### [H1] Git host token
|
|
398
|
+
|
|
399
|
+
Only shown for Jira and Linear boards. GitHub Issues users already have `GITHUB_TOKEN` for PR creation.
|
|
400
|
+
|
|
401
|
+
```
|
|
402
|
+
Git host — current: {GitHub / GitLab / Bitbucket / not set}
|
|
403
|
+
Clancy pushes feature branches and creates PRs on your git host.
|
|
404
|
+
|
|
405
|
+
[1] GitHub
|
|
406
|
+
[2] GitLab
|
|
407
|
+
[3] Bitbucket
|
|
408
|
+
[4] Remove (push and create PRs manually)
|
|
409
|
+
[5] Cancel
|
|
410
|
+
```
|
|
411
|
+
|
|
412
|
+
If [1]: prompt `Paste your GitHub personal access token:` then write `GITHUB_TOKEN=<value>` to `.clancy/.env`. Remove any existing `GITLAB_TOKEN`, `BITBUCKET_USER`, `BITBUCKET_TOKEN`.
|
|
413
|
+
If [2]: prompt `Paste your GitLab personal access token:` then write `GITLAB_TOKEN=<value>` to `.clancy/.env`. Optionally ask for a self-hosted API base URL (e.g. `https://gitlab.example.com/api/v4`) and write `CLANCY_GIT_API_URL` and `CLANCY_GIT_PLATFORM="gitlab"`. If the user enters just a hostname or instance URL without `/api/v4`, append `/api/v4` automatically. Remove any existing `GITHUB_TOKEN` (only if board is not GitHub), `BITBUCKET_USER`, `BITBUCKET_TOKEN`.
|
|
414
|
+
If [3]: prompt for `Bitbucket username` and `Bitbucket app password`, write `BITBUCKET_USER` and `BITBUCKET_TOKEN` to `.clancy/.env`. Remove any existing `GITHUB_TOKEN` (only if board is not GitHub), `GITLAB_TOKEN`.
|
|
415
|
+
If [4]: remove all git host token vars (`GITLAB_TOKEN`, `BITBUCKET_USER`, `BITBUCKET_TOKEN`, `CLANCY_GIT_PLATFORM`, `CLANCY_GIT_API_URL`). Keep `GITHUB_TOKEN` only if board is GitHub Issues.
|
|
416
|
+
|
|
417
|
+
---
|
|
418
|
+
|
|
358
419
|
### [I1] Figma MCP
|
|
359
420
|
|
|
360
421
|
```
|
|
@@ -479,6 +540,7 @@ If no: print `Cancelled. No changes made.` and loop back to the menu.
|
|
|
479
540
|
- Jira: `JIRA_BASE_URL`, `JIRA_USER`, `JIRA_API_TOKEN`, `JIRA_PROJECT_KEY`, `CLANCY_JQL_STATUS`, `CLANCY_JQL_SPRINT`
|
|
480
541
|
- GitHub: `GITHUB_TOKEN`, `GITHUB_REPO`
|
|
481
542
|
- Linear: `LINEAR_API_KEY`, `LINEAR_TEAM_ID`
|
|
543
|
+
- Git host (all boards): `GITLAB_TOKEN`, `BITBUCKET_USER`, `BITBUCKET_TOKEN`, `CLANCY_GIT_PLATFORM`, `CLANCY_GIT_API_URL`, `CLANCY_STATUS_REVIEW`
|
|
482
544
|
2. Write the new board credentials to `.clancy/.env`
|
|
483
545
|
3. If switching to Jira: also ask the status filter question (same as init Q3) and write `CLANCY_JQL_STATUS` to `.clancy/.env`
|
|
484
546
|
4. No script replacement needed — the bundled runtime scripts are board-agnostic (board detection happens at runtime from `.clancy/.env`)
|