@dendelion/paper-camp 0.8.0 → 0.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/app/assets/index-BnXxehKU.js +2 -0
- package/dist/app/assets/index-BnXxehKU.js.map +1 -0
- package/dist/app/assets/index-C2kYil0S.js +3 -0
- package/dist/app/assets/index-C2kYil0S.js.map +1 -0
- package/dist/app/assets/index-CRRHTP77.js +2 -0
- package/dist/app/assets/index-CRRHTP77.js.map +1 -0
- package/dist/app/assets/index-DrNAzLuW.js +2 -0
- package/dist/app/assets/index-DrNAzLuW.js.map +1 -0
- package/dist/app/assets/main-BJGNGUiz.css +1 -0
- package/dist/app/assets/main-CyxblUnu.js +233 -0
- package/dist/app/assets/main-CyxblUnu.js.map +1 -0
- package/dist/app/assets/sidebar-section-Ch50IaLb.js +2 -0
- package/dist/app/assets/sidebar-section-Ch50IaLb.js.map +1 -0
- package/dist/app/index.html +2 -2
- package/dist/chunks/{serializer.BfH7zTwv.js → roadmap.C0AQ6pUX.js} +1437 -1387
- package/dist/chunks/roadmap.C0AQ6pUX.js.map +1 -0
- package/dist/cli/index.js +6720 -6420
- package/dist/cli/index.js.map +1 -1
- package/dist/core/env.d.ts +0 -5
- package/dist/core/env.d.ts.map +1 -1
- package/dist/core/git-pr/branch.d.ts +2 -6
- package/dist/core/git-pr/branch.d.ts.map +1 -1
- package/dist/core/git-pr/pr-lookup.d.ts +3 -44
- package/dist/core/git-pr/pr-lookup.d.ts.map +1 -1
- package/dist/core/git-pr/pr.d.ts +5 -85
- package/dist/core/git-pr/pr.d.ts.map +1 -1
- package/dist/core/git-pr/scopes.d.ts +0 -6
- package/dist/core/git-pr/scopes.d.ts.map +1 -1
- package/dist/core/index.d.ts +1 -0
- package/dist/core/index.d.ts.map +1 -1
- package/dist/core/index.js +71 -66
- package/dist/core/parse/frontmatter-schemas.d.ts +0 -8
- package/dist/core/parse/frontmatter-schemas.d.ts.map +1 -1
- package/dist/core/parse/parser.d.ts +3 -31
- package/dist/core/parse/parser.d.ts.map +1 -1
- package/dist/core/parse/schemas.d.ts +2 -0
- package/dist/core/parse/schemas.d.ts.map +1 -1
- package/dist/core/readers.d.ts +2 -28
- package/dist/core/readers.d.ts.map +1 -1
- package/dist/core/roadmap.d.ts +4 -0
- package/dist/core/roadmap.d.ts.map +1 -0
- package/dist/core/roadmap.test.d.ts +2 -0
- package/dist/core/roadmap.test.d.ts.map +1 -0
- package/dist/core/run-order.d.ts +23 -0
- package/dist/core/run-order.d.ts.map +1 -0
- package/dist/core/run-order.test.d.ts +2 -0
- package/dist/core/run-order.test.d.ts.map +1 -0
- package/dist/core/scaffold/scaffold.d.ts +0 -6
- package/dist/core/scaffold/scaffold.d.ts.map +1 -1
- package/dist/core/scaffold/templates.d.ts +0 -6
- package/dist/core/scaffold/templates.d.ts.map +1 -1
- package/dist/core/sections.d.ts +18 -0
- package/dist/core/sections.d.ts.map +1 -0
- package/dist/core/serialize/content-hash.d.ts +0 -6
- package/dist/core/serialize/content-hash.d.ts.map +1 -1
- package/dist/core/serialize/serializer.d.ts +3 -60
- package/dist/core/serialize/serializer.d.ts.map +1 -1
- package/dist/core/serialize/serializer.test.d.ts +2 -0
- package/dist/core/serialize/serializer.test.d.ts.map +1 -0
- package/dist/core/status/status.d.ts +4 -19
- package/dist/core/status/status.d.ts.map +1 -1
- package/dist/types/index.d.ts +56 -29
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/index.js.map +1 -1
- package/package.json +2 -2
- package/dist/app/assets/index-CF8jC3IN.js +0 -2
- package/dist/app/assets/index-CF8jC3IN.js.map +0 -1
- package/dist/app/assets/index-DGXi8vpJ.js +0 -2
- package/dist/app/assets/index-DGXi8vpJ.js.map +0 -1
- package/dist/app/assets/main-D66GnCKz.css +0 -1
- package/dist/app/assets/main-DJDNx4Xs.js +0 -218
- package/dist/app/assets/main-DJDNx4Xs.js.map +0 -1
- package/dist/app/assets/sidebar-section-C2j12TzE.js +0 -2
- package/dist/app/assets/sidebar-section-C2j12TzE.js.map +0 -1
- package/dist/chunks/serializer.BfH7zTwv.js.map +0 -1
package/dist/core/env.d.ts
CHANGED
|
@@ -1,9 +1,4 @@
|
|
|
1
1
|
import { EnvEntry } from '../types/index';
|
|
2
|
-
/** Parses `KEY=value` lines, skipping comments and blank lines. */
|
|
3
2
|
export declare function parseEnv(content: string): EnvEntry[];
|
|
4
|
-
/**
|
|
5
|
-
* Replaces matched-key lines in place, drops keys no longer present, and appends
|
|
6
|
-
* new keys at the end — preserving comments and the ordering of every untouched line.
|
|
7
|
-
*/
|
|
8
3
|
export declare function applyEnvEntries(content: string, entries: EnvEntry[]): string;
|
|
9
4
|
//# sourceMappingURL=env.d.ts.map
|
package/dist/core/env.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"env.d.ts","sourceRoot":"","sources":["../../src/core/env.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AA2B/C,
|
|
1
|
+
{"version":3,"file":"env.d.ts","sourceRoot":"","sources":["../../src/core/env.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AA2B/C,wBAAgB,QAAQ,CAAC,OAAO,EAAE,MAAM,GAAG,QAAQ,EAAE,CAOpD;AAED,wBAAgB,eAAe,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,GAAG,MAAM,CAuB5E"}
|
|
@@ -1,8 +1,4 @@
|
|
|
1
|
-
/**
|
|
2
|
-
*
|
|
3
|
-
* that `branchEntityId`/`getFeatureBranchPlanId` parse back out. Shared so
|
|
4
|
-
* branch creation (`ensureBranch`) and PR resolution (`resolvePrMerged`)
|
|
5
|
-
* target the exact same name.
|
|
6
|
-
*/
|
|
1
|
+
/** Matches the `kind/id-slug` convention that `branchEntityId`/`getFeatureBranchPlanId`
|
|
2
|
+
* parse back out — shared so branch creation and PR resolution target the same name. */
|
|
7
3
|
export declare function branchName(id: string | undefined, type: string | undefined, title: string): string | undefined;
|
|
8
4
|
//# sourceMappingURL=branch.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"branch.d.ts","sourceRoot":"","sources":["../../../src/core/git-pr/branch.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"branch.d.ts","sourceRoot":"","sources":["../../../src/core/git-pr/branch.ts"],"names":[],"mappings":"AAAA;wFACwF;AACxF,wBAAgB,UAAU,CACxB,EAAE,EAAE,MAAM,GAAG,SAAS,EACtB,IAAI,EAAE,MAAM,GAAG,SAAS,EACxB,KAAK,EAAE,MAAM,GACZ,MAAM,GAAG,SAAS,CAQpB"}
|
|
@@ -1,57 +1,16 @@
|
|
|
1
1
|
import { PrInfo, ReviewThread } from '../../types/index';
|
|
2
|
-
/**
|
|
3
|
-
* The entity id a PR references — its `**Plan:** \`IDEA-N\`` body line (stamped
|
|
4
|
-
* by draft-pr.yml), falling back to the `feat/idea-N-…` id prefix of its head
|
|
5
|
-
* branch. Both key off the stable id, never the title, so a renamed entity's PR
|
|
6
|
-
* still resolves. Shared by the row-level index (`prEntityId`) and the
|
|
7
|
-
* single-ref lookup (`resolvePlanForPrRef` in `pr.ts`).
|
|
8
|
-
*/
|
|
9
2
|
export declare function resolveEntityIdFromPrRef(body: string | null | undefined, branch: string | null | undefined): string | null;
|
|
10
|
-
/**
|
|
11
|
-
* Splits a PR's `html_url` into the owner/repo/number a `gh api graphql` call
|
|
12
|
-
* needs. Also used by `pr.ts`'s consistency-comment sync to build the REST
|
|
13
|
-
* PATCH endpoint for editing an existing sticky comment.
|
|
14
|
-
*/
|
|
15
3
|
export declare function parsePrUrl(url: string): {
|
|
16
4
|
owner: string;
|
|
17
5
|
repo: string;
|
|
18
6
|
number: string;
|
|
19
7
|
} | null;
|
|
20
|
-
/**
|
|
21
|
-
* Per-comment detail for a PR's unresolved review threads, for the fix-review
|
|
22
|
-
* launch path (`POST /api/agent/launch-fix-review`) to hand to
|
|
23
|
-
* `buildFixReviewPrompt`. Each thread is represented by its first comment, since
|
|
24
|
-
* that's the one that states what needs fixing. Best-effort: resolves `[]` on
|
|
25
|
-
* any failure so a launch with no readable threads falls back to
|
|
26
|
-
* `buildFixReviewPrompt`'s own empty-threads guard rather than erroring out.
|
|
27
|
-
*/
|
|
8
|
+
/** Best-effort: resolves `[]` on any failure rather than throwing. */
|
|
28
9
|
export declare function fetchUnresolvedThreads(root: string, url: string): Promise<ReviewThread[]>;
|
|
29
|
-
/**
|
|
30
|
-
* Marks a review thread resolved. Called once the fix that addresses it is
|
|
31
|
-
* actually pushed (see the git push route) — resolving earlier would mark the
|
|
32
|
-
* thread done against code the PR can't see yet. Best-effort: returns false on
|
|
33
|
-
* any failure rather than throwing, since a failed resolve must not fail a push.
|
|
34
|
-
*/
|
|
10
|
+
/** Best-effort: returns `false` on any failure — a failed resolve must not fail the push that triggered it. */
|
|
35
11
|
export declare function resolveReviewThread(root: string, threadId: string): Promise<boolean>;
|
|
36
|
-
/**
|
|
37
|
-
* Posts a reply on a review thread — used to record why the agent deliberately
|
|
38
|
-
* skipped a comment, so a rejected suggestion reads as a reasoned decision
|
|
39
|
-
* rather than silence. Best-effort, same as resolveReviewThread.
|
|
40
|
-
*/
|
|
41
12
|
export declare function replyToReviewThread(root: string, threadId: string, body: string): Promise<boolean>;
|
|
42
|
-
/**
|
|
43
|
-
* Every PR in the repo indexed by the entity id it references, resolved via a
|
|
44
|
-
* single `gh pr list` and cached for `ttlMs`, feeding `core/status.ts`'s
|
|
45
|
-
* PR-driven status derivation. `undefined` when the lookup can't resolve at
|
|
46
|
-
* all (no `gh`, not authenticated, offline, no GitHub remote); callers fall
|
|
47
|
-
* back to stored status.
|
|
48
|
-
* An entity simply absent from the returned map has no PR (a confirmed answer).
|
|
49
|
-
*/
|
|
13
|
+
/** `undefined` means the lookup couldn't resolve at all; callers fall back to stored status. */
|
|
50
14
|
export declare function resolvePrsByEntity(root: string, ttlMs?: number): Promise<Map<string, PrInfo> | undefined>;
|
|
51
|
-
/**
|
|
52
|
-
* Clears the module-level PR cache. Used by the manual refresh route
|
|
53
|
-
* (`POST /api/refresh`) so a user-triggered refresh re-resolves PR/review state
|
|
54
|
-
* instead of replaying the TTL window, and by tests to isolate cases.
|
|
55
|
-
*/
|
|
56
15
|
export declare function clearPrCache(): void;
|
|
57
16
|
//# sourceMappingURL=pr-lookup.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pr-lookup.d.ts","sourceRoot":"","sources":["../../../src/core/git-pr/pr-lookup.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAkB,YAAY,EAAE,MAAM,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"pr-lookup.d.ts","sourceRoot":"","sources":["../../../src/core/git-pr/pr-lookup.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAkB,YAAY,EAAE,MAAM,mBAAmB,CAAC;AA2C9E,wBAAgB,wBAAwB,CACtC,IAAI,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,EAC/B,MAAM,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GAChC,MAAM,GAAG,IAAI,CAKf;AA0BD,wBAAgB,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,GAAG,IAAI,CAK9F;AA0HD,sEAAsE;AACtE,wBAAsB,sBAAsB,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,YAAY,EAAE,CAAC,CAkB/F;AAgBD,+GAA+G;AAC/G,wBAAsB,mBAAmB,CAAC,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAK1F;AAED,wBAAsB,mBAAmB,CACvC,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,MAAM,GACX,OAAO,CAAC,OAAO,CAAC,CAKlB;AA4ED,gGAAgG;AAChG,wBAAsB,kBAAkB,CACtC,IAAI,EAAE,MAAM,EACZ,KAAK,SAAkB,GACtB,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,SAAS,CAAC,CAQ1C;AAED,wBAAgB,YAAY,IAAI,IAAI,CAEnC"}
|
package/dist/core/git-pr/pr.d.ts
CHANGED
|
@@ -1,101 +1,21 @@
|
|
|
1
1
|
import { ConsistencyIssue, EntityType, PhaseItem } from '../../types/index';
|
|
2
2
|
export { clearPrCache, fetchUnresolvedThreads, replyToReviewThread, resolvePrsByEntity, resolveReviewThread, } from './pr-lookup';
|
|
3
|
-
|
|
4
|
-
export interface ResolvedPlanForPr {
|
|
3
|
+
interface ResolvedPlanForPr {
|
|
5
4
|
id: string;
|
|
6
5
|
kind?: EntityType;
|
|
7
6
|
tags: string[];
|
|
8
7
|
phases: PhaseItem[];
|
|
9
8
|
}
|
|
10
|
-
/**
|
|
11
|
-
* Resolves the plan a PR (given by number or branch) mirrors, and parses
|
|
12
|
-
* `papercamp/ideas/<ID>.md` for the fields the mirroring workflows need. `ref`
|
|
13
|
-
* is passed straight to `gh pr view`, so both a PR number and a branch name
|
|
14
|
-
* work; when no PR exists yet for a branch, falls back to reading the plan id
|
|
15
|
-
* out of the branch name itself (same convention `draft-pr.yml` uses to name
|
|
16
|
-
* the PR in the first place). Returns `undefined` when the id can't be
|
|
17
|
-
* resolved at all, or when it doesn't match a file under `papercamp/ideas/`.
|
|
18
|
-
*/
|
|
19
9
|
export declare function resolvePlanForPrRef(root: string, ref: string): Promise<ResolvedPlanForPr | undefined>;
|
|
20
|
-
/**
|
|
21
|
-
* Renders a plan's `### Phases` as a GitHub task-list checklist and
|
|
22
|
-
* inserts/replaces it in a PR body between marker comments, leaving
|
|
23
|
-
* everything else — notably the `**Plan:**` line `draft-pr.yml` stamps — untouched.
|
|
24
|
-
* Idempotent: the same `phases` always renders the same section text, so a
|
|
25
|
-
* caller can compare the result to the current body and skip the `gh pr edit`
|
|
26
|
-
* call when nothing changed.
|
|
27
|
-
*/
|
|
28
10
|
export declare function renderPlanPhasesIntoBody(body: string, phases: PhaseItem[]): string;
|
|
29
|
-
export
|
|
30
|
-
/**
|
|
31
|
-
* On push to a plan branch: rewrites the PR body's phases checklist to match
|
|
32
|
-
* `### Phases` in the plan file, preserving the `**Plan:**` line and
|
|
33
|
-
* everything else. Only calls `gh pr edit` when the rendered body actually
|
|
34
|
-
* differs from the PR's current body, so rerunning on an unchanged plan is a
|
|
35
|
-
* no-op — the idempotency `renderPlanPhasesIntoBody` makes possible.
|
|
36
|
-
*/
|
|
37
|
-
export declare function syncPlanPhasesToPr(root: string, ref: string): Promise<SyncPlanPhasesResult>;
|
|
38
|
-
/**
|
|
39
|
-
* The labels a PR should carry for a plan: its `kind` (feat/fix/…, the
|
|
40
|
-
* type-enum values) plus whichever `tags` are also recognized commit scopes
|
|
41
|
-
* (`COMMIT_SCOPES` — the same area vocabulary `.commitlintrc.json`'s
|
|
42
|
-
* `scope-enum` uses), so free-form tags that aren't area names don't leak
|
|
43
|
-
* into GitHub labels. Order-stable and de-duped.
|
|
44
|
-
*/
|
|
11
|
+
export declare function syncPlanPhasesToPr(root: string, ref: string): Promise<'updated' | 'unchanged' | 'unresolved'>;
|
|
45
12
|
export declare function derivePrLabels(plan: Pick<ResolvedPlanForPr, 'kind' | 'tags'>): string[];
|
|
46
|
-
export
|
|
47
|
-
|
|
48
|
-
* On push to a plan branch: applies the labels `derivePrLabels` derives from
|
|
49
|
-
* the plan's `kind`/`tags`, creating any that don't exist in the repo yet.
|
|
50
|
-
* Additive only — a label already on the PR (human-added or from a previous
|
|
51
|
-
* run) is left alone, and a plan label no longer implied by the file is not
|
|
52
|
-
* removed, so a human's own labeling is never clobbered. Only calls `gh` to
|
|
53
|
-
* add labels that are actually missing from the PR, so rerunning on an
|
|
54
|
-
* unchanged plan is a no-op.
|
|
55
|
-
*/
|
|
56
|
-
export declare function syncPrLabelsToPr(root: string, ref: string): Promise<SyncPrLabelsResult>;
|
|
57
|
-
export type SyncPrReadinessResult = 'ready' | 'closed' | 'unchanged' | 'unresolved';
|
|
58
|
-
/**
|
|
59
|
-
* On push to a plan branch: one-way plan → PR readiness, never plan status.
|
|
60
|
-
* A stored `dropped` override closes an open PR (abandonment leaves no other
|
|
61
|
-
* trace to derive from, per `core/status.ts`). Otherwise, once every phase in
|
|
62
|
-
* the plan is checked, a draft PR flips to ready for review — the phases list
|
|
63
|
-
* is the derived `review` signal per `core/status.ts`. Anything already in the
|
|
64
|
-
* target state (a non-draft PR with all phases done, an already-closed
|
|
65
|
-
* dropped PR) is a no-op, so rerunning on an unchanged plan doesn't call `gh`
|
|
66
|
-
* again. Marking a plan `done` on merge is deliberately not done here — that's
|
|
67
|
-
* `core/status.ts`'s derivation from the merged PR, not a write this function
|
|
68
|
-
* makes.
|
|
69
|
-
*/
|
|
70
|
-
export declare function syncPrReadinessToPr(root: string, ref: string): Promise<SyncPrReadinessResult>;
|
|
13
|
+
export declare function syncPrLabelsToPr(root: string, ref: string): Promise<'updated' | 'unchanged' | 'unresolved'>;
|
|
14
|
+
export declare function syncPrReadinessToPr(root: string, ref: string): Promise<'ready' | 'closed' | 'unchanged' | 'unresolved'>;
|
|
71
15
|
interface AuditSummary {
|
|
72
16
|
audited: string;
|
|
73
|
-
/** Whether the plan's content has changed since the stored `audited-hash`. */
|
|
74
17
|
stale: boolean;
|
|
75
18
|
}
|
|
76
|
-
/**
|
|
77
|
-
* Renders `findConsistencyIssues`' repo-wide results, plus the plan's own
|
|
78
|
-
* convergence-audit staleness where one has been recorded, as a sticky PR
|
|
79
|
-
* comment body wrapped in marker comments (same `find/replace-by-marker`
|
|
80
|
-
* shape as `renderPlanPhasesIntoBody`). Deterministic for the same inputs, so
|
|
81
|
-
* a caller can compare against the existing sticky comment and skip the `gh`
|
|
82
|
-
* call when nothing changed.
|
|
83
|
-
*/
|
|
84
19
|
export declare function renderConsistencyComment(issues: ConsistencyIssue[], audit?: AuditSummary): string;
|
|
85
|
-
export
|
|
86
|
-
/**
|
|
87
|
-
* On push to a plan branch: upserts a single sticky Scout comment on the PR with
|
|
88
|
-
* `findConsistencyIssues`' repo-wide results (dangling decision/question links, an
|
|
89
|
-
* open question blocking an already-active plan) and, when the plan carries a
|
|
90
|
-
* recorded convergence audit, whether it's gone stale since — so Paper Camp's own
|
|
91
|
-
* structured checks sit next to CI and CodeRabbit where review actually happens.
|
|
92
|
-
* Reads decisions/open-questions/plans straight off the checked-out branch (same
|
|
93
|
-
* corpus `/api/consistency` reads), not scoped to just this plan, since most issue
|
|
94
|
-
* kinds aren't plan-specific. Finds the existing sticky comment by its marker and
|
|
95
|
-
* PATCHes it via the REST id parsed from its URL rather than `gh pr comment
|
|
96
|
-
* --edit-last`, which isn't safe once Scout has posted any other unrelated comment.
|
|
97
|
-
* Only calls `gh` when the rendered body actually changed, so a rerun on an
|
|
98
|
-
* unchanged repo state is a no-op.
|
|
99
|
-
*/
|
|
100
|
-
export declare function syncConsistencyCommentToPr(root: string, ref: string): Promise<SyncConsistencyCommentResult>;
|
|
20
|
+
export declare function syncConsistencyCommentToPr(root: string, ref: string): Promise<'created' | 'updated' | 'unchanged' | 'unresolved'>;
|
|
101
21
|
//# sourceMappingURL=pr.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pr.d.ts","sourceRoot":"","sources":["../../../src/core/git-pr/pr.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,gBAAgB,EAAe,UAAU,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAY9F,OAAO,EACL,YAAY,EACZ,sBAAsB,EACtB,mBAAmB,EACnB,kBAAkB,EAClB,mBAAmB,GACpB,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"pr.d.ts","sourceRoot":"","sources":["../../../src/core/git-pr/pr.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,gBAAgB,EAAe,UAAU,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAY9F,OAAO,EACL,YAAY,EACZ,sBAAsB,EACtB,mBAAmB,EACnB,kBAAkB,EAClB,mBAAmB,GACpB,MAAM,aAAa,CAAC;AA2DrB,UAAU,iBAAiB;IACzB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,IAAI,EAAE,MAAM,EAAE,CAAC;IACf,MAAM,EAAE,SAAS,EAAE,CAAC;CACrB;AA0BD,wBAAsB,mBAAmB,CACvC,IAAI,EAAE,MAAM,EACZ,GAAG,EAAE,MAAM,GACV,OAAO,CAAC,iBAAiB,GAAG,SAAS,CAAC,CAKxC;AAMD,wBAAgB,wBAAwB,CAAC,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,SAAS,EAAE,GAAG,MAAM,CAOlF;AAeD,wBAAsB,kBAAkB,CACtC,IAAI,EAAE,MAAM,EACZ,GAAG,EAAE,MAAM,GACV,OAAO,CAAC,SAAS,GAAG,WAAW,GAAG,YAAY,CAAC,CAUjD;AAED,wBAAgB,cAAc,CAAC,IAAI,EAAE,IAAI,CAAC,iBAAiB,EAAE,MAAM,GAAG,MAAM,CAAC,GAAG,MAAM,EAAE,CAOvF;AAyDD,wBAAsB,gBAAgB,CACpC,IAAI,EAAE,MAAM,EACZ,GAAG,EAAE,MAAM,GACV,OAAO,CAAC,SAAS,GAAG,WAAW,GAAG,YAAY,CAAC,CAoBjD;AA0BD,wBAAsB,mBAAmB,CACvC,IAAI,EAAE,MAAM,EACZ,GAAG,EAAE,MAAM,GACV,OAAO,CAAC,OAAO,GAAG,QAAQ,GAAG,WAAW,GAAG,YAAY,CAAC,CAgB1D;AAKD,UAAU,YAAY;IACpB,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,OAAO,CAAC;CAChB;AAED,wBAAgB,wBAAwB,CAAC,MAAM,EAAE,gBAAgB,EAAE,EAAE,KAAK,CAAC,EAAE,YAAY,GAAG,MAAM,CAkBjG;AA2CD,wBAAsB,0BAA0B,CAC9C,IAAI,EAAE,MAAM,EACZ,GAAG,EAAE,MAAM,GACV,OAAO,CAAC,SAAS,GAAG,SAAS,GAAG,WAAW,GAAG,YAAY,CAAC,CAwC7D"}
|
|
@@ -1,8 +1,2 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Valid commit scopes — keep in sync with `.commitlintrc.json`'s `scope-enum`.
|
|
3
|
-
* Doubles as the area-label vocabulary Scout's PR label sync reuses (see
|
|
4
|
-
* `derivePrLabels` in `pr.ts`), so a plan tag only becomes a label when it's
|
|
5
|
-
* also a recognized commit scope.
|
|
6
|
-
*/
|
|
7
1
|
export declare const COMMIT_SCOPES: Set<string>;
|
|
8
2
|
//# sourceMappingURL=scopes.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scopes.d.ts","sourceRoot":"","sources":["../../../src/core/git-pr/scopes.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"scopes.d.ts","sourceRoot":"","sources":["../../../src/core/git-pr/scopes.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,aAAa,aAmBxB,CAAC"}
|
package/dist/core/index.d.ts
CHANGED
package/dist/core/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/core/index.ts"],"names":[],"mappings":"AAAA,cAAc,OAAO,CAAC;AACtB,cAAc,WAAW,CAAC;AAC1B,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,gBAAgB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/core/index.ts"],"names":[],"mappings":"AAAA,cAAc,OAAO,CAAC;AACtB,cAAc,WAAW,CAAC;AAC1B,cAAc,SAAS,CAAC;AACxB,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,WAAW,CAAC;AAC1B,cAAc,gBAAgB,CAAC"}
|
package/dist/core/index.js
CHANGED
|
@@ -1,81 +1,86 @@
|
|
|
1
|
-
import { A as e, C as r, a as n, P as t, S as i, b as o, c as
|
|
2
|
-
import { AGENT_IDS as
|
|
1
|
+
import { A as e, C as r, a as n, P as t, S as i, b as o, c as d, d as m, e as l, f as p, g as E, h as P, i as c, j as S, k as T, l as y, m as h, n as I, o as f, p as g, q as F, r as N, s as C, t as A, u as _, v, w as L, x as u, y as O, z as R, B as D, D as G, E as b, F as U, G as B, H as M, I as Q, J as j, K as k, L as w, M as x, N as z, O as K, Q as W, R as H, T as J, U as V, V as Y, W as q, X, Y as Z, Z as $, _ as aa, $ as sa, a0 as ea, a1 as ra, a2 as na, a3 as ta, a4 as ia, a5 as oa, a6 as da, a7 as ma, a8 as la, a9 as pa, aa as Ea, ab as Pa, ac as ca, ad as Sa, ae as Ta, af as ya, ag as ha, ah as Ia, ai as fa, aj as ga } from "../chunks/roadmap.C0AQ6pUX.js";
|
|
2
|
+
import { AGENT_IDS as Na, AGENT_LABELS as Ca, AGENT_OPTIONS as Aa, DEFAULT_AGENTS as _a, PLAN_KINDS as va, PLAN_STATUSES as La, coerceAgentConfig as ua } from "../types/index.js";
|
|
3
3
|
export {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
Na as AGENT_IDS,
|
|
5
|
+
Ca as AGENT_LABELS,
|
|
6
|
+
Aa as AGENT_OPTIONS,
|
|
7
7
|
e as AlreadyInitializedError,
|
|
8
8
|
r as CLAUDE_SETTINGS_JSON,
|
|
9
9
|
n as COMMIT_SCOPES,
|
|
10
|
-
|
|
10
|
+
_a as DEFAULT_AGENTS,
|
|
11
11
|
t as PAPER_CAMP_VERSION,
|
|
12
|
-
|
|
13
|
-
|
|
12
|
+
va as PLAN_KINDS,
|
|
13
|
+
La as PLAN_STATUSES,
|
|
14
14
|
i as SKILL_MD_CONTENT,
|
|
15
15
|
o as SUGGESTION_ENTRY_RE,
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
16
|
+
d as agentConfigSchema,
|
|
17
|
+
m as appendBlock,
|
|
18
|
+
l as applyEnvEntries,
|
|
19
|
+
p as archiveEntityFile,
|
|
20
|
+
E as assignEntityId,
|
|
21
|
+
P as assignPlanId,
|
|
22
|
+
c as branchName,
|
|
23
|
+
S as clearPrCache,
|
|
24
|
+
ua as coerceAgentConfig,
|
|
25
|
+
T as computePlanContentHash,
|
|
26
|
+
y as dateString,
|
|
27
27
|
h as decisionFieldsSchema,
|
|
28
28
|
I as derivePrLabels,
|
|
29
|
-
f as
|
|
29
|
+
f as ensureSubject,
|
|
30
|
+
g as entityFrontmatterSchema,
|
|
30
31
|
F as entityToIdea,
|
|
31
32
|
N as entityToPlan,
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
_ as
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
O as
|
|
39
|
-
|
|
40
|
-
D as
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
U as
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
33
|
+
C as fetchUnresolvedThreads,
|
|
34
|
+
A as findArchivableIdeas,
|
|
35
|
+
_ as findConsistencyIssues,
|
|
36
|
+
v as formatDecisionEntry,
|
|
37
|
+
L as formatEntitiesIndex,
|
|
38
|
+
u as formatEntityFile,
|
|
39
|
+
O as formatIdeaFile,
|
|
40
|
+
R as formatOpenQuestionEntry,
|
|
41
|
+
D as formatOpenQuestions,
|
|
42
|
+
G as formatPlanEntry,
|
|
43
|
+
b as formatPlanFile,
|
|
44
|
+
U as formatPlans,
|
|
45
|
+
B as formatProgressEntry,
|
|
46
|
+
M as ideaFrontmatterSchema,
|
|
47
|
+
Q as initProject,
|
|
48
|
+
j as openQuestionFieldsSchema,
|
|
49
|
+
k as paperCampConfigSchema,
|
|
48
50
|
w as parseDecisions,
|
|
49
51
|
x as parseEntityFile,
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
la as
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
52
|
+
z as parseEnv,
|
|
53
|
+
K as parseFrontmatter,
|
|
54
|
+
W as parseIdeaFile,
|
|
55
|
+
H as parseIdeas,
|
|
56
|
+
J as parseOpenQuestions,
|
|
57
|
+
V as parsePlanFile,
|
|
58
|
+
Y as parsePlans,
|
|
59
|
+
q as parseProgress,
|
|
60
|
+
X as parseRawEntries,
|
|
61
|
+
Z as parseRoadmap,
|
|
62
|
+
$ as parseSuggestions,
|
|
63
|
+
aa as parseTaskLog,
|
|
64
|
+
sa as planFieldsSchema,
|
|
65
|
+
ea as planFrontmatterSchema,
|
|
66
|
+
ra as prependProgressItem,
|
|
67
|
+
na as readEntities,
|
|
68
|
+
ta as readEntitiesWithDerivedStatus,
|
|
69
|
+
ia as readNoteEntries,
|
|
70
|
+
oa as readWorkEntries,
|
|
71
|
+
da as removeRoadmapItem,
|
|
72
|
+
ma as removeSuggestionLine,
|
|
73
|
+
la as renderConsistencyComment,
|
|
74
|
+
pa as renderPlanPhasesIntoBody,
|
|
75
|
+
Ea as replyToReviewThread,
|
|
76
|
+
Pa as resolvePlanForPrRef,
|
|
77
|
+
ca as resolvePrsByEntity,
|
|
78
|
+
Sa as resolveReviewThread,
|
|
79
|
+
Ta as serializeFrontmatter,
|
|
80
|
+
ya as syncConsistencyCommentToPr,
|
|
81
|
+
ha as syncPlanPhasesToPr,
|
|
82
|
+
Ia as syncPrLabelsToPr,
|
|
83
|
+
fa as syncPrReadinessToPr,
|
|
84
|
+
ga as todayDateString
|
|
80
85
|
};
|
|
81
86
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,11 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Re-exports from `schemas.ts` for backwards compatibility.
|
|
3
|
-
*
|
|
4
|
-
* This file is referenced by `papercamp/about.md` as the "single source of truth"
|
|
5
|
-
* for the frontmatter format. Keeping it as a thin barrel means existing docs/links
|
|
6
|
-
* don't break while the actual schemas live alongside their field-based counterparts
|
|
7
|
-
* in one file.
|
|
8
|
-
*/
|
|
9
1
|
export { dateString, planFrontmatterSchema, ideaFrontmatterSchema, } from './schemas';
|
|
10
2
|
export type { PlanFrontmatter, IdeaFrontmatter } from './schemas';
|
|
11
3
|
//# sourceMappingURL=frontmatter-schemas.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"frontmatter-schemas.d.ts","sourceRoot":"","sources":["../../../src/core/parse/frontmatter-schemas.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"frontmatter-schemas.d.ts","sourceRoot":"","sources":["../../../src/core/parse/frontmatter-schemas.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,UAAU,EACV,qBAAqB,EACrB,qBAAqB,GACtB,MAAM,WAAW,CAAC;AACnB,YAAY,EAAE,eAAe,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC"}
|
|
@@ -1,50 +1,22 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { ConsistencyIssue, DecisionEntry, EntityEntry, IdeaEntry, OpenQuestionEntry, ParseResult, ParseWarning, PlanEntry, ProgressEntry, RawEntry, SuggestionEntry } from '../../types/index';
|
|
2
|
+
import { ConsistencyIssue, DecisionEntry, EntityEntry, IdeaEntry, OpenQuestionEntry, ParseResult, ParseWarning, PlanEntry, ProgressEntry, RawEntry, SuggestionEntry, TaskLogEntry } from '../../types/index';
|
|
3
3
|
export declare function parseRawEntries(markdown: string): RawEntry[];
|
|
4
4
|
export declare function parsePlans(markdown: string): ParseResult<PlanEntry>;
|
|
5
5
|
export declare function parseDecisions(markdown: string): ParseResult<DecisionEntry>;
|
|
6
6
|
export declare function parseOpenQuestions(markdown: string): ParseResult<OpenQuestionEntry>;
|
|
7
|
-
/**
|
|
8
|
-
* Extracts and validates YAML frontmatter from a markdown string.
|
|
9
|
-
* Returns the parsed data + body without warnings on success.
|
|
10
|
-
* Returns partial data + warnings when frontmatter is absent, malformed,
|
|
11
|
-
* or fails schema validation — never throws.
|
|
12
|
-
*/
|
|
13
7
|
export declare function parseFrontmatter<T>(content: string, schema: z.ZodType<T>): {
|
|
14
8
|
data: T | null;
|
|
15
9
|
body: string;
|
|
16
10
|
warnings: ParseWarning[];
|
|
17
11
|
};
|
|
18
|
-
/**
|
|
19
|
-
* Parses a unified entity file: one file per entity — an "idea" for its whole
|
|
20
|
-
* life, plan as an optional `### Phases` body section. Same body pipeline as
|
|
21
|
-
* parsePlanFile (Phases/Log/Clarifications extraction); the frontmatter
|
|
22
|
-
* differs: `type` instead of `kind`, no `idea:` backlink, and the note/status
|
|
23
|
-
* asymmetry from the idea schema folded in.
|
|
24
|
-
*/
|
|
25
12
|
export declare function parseEntityFile(content: string): ParseResult<EntityEntry>;
|
|
26
13
|
export declare function parsePlanFile(content: string): ParseResult<PlanEntry>;
|
|
27
|
-
/**
|
|
28
|
-
* Parse a single per-idea file with YAML frontmatter.
|
|
29
|
-
*/
|
|
30
14
|
export declare function parseIdeaFile(content: string): ParseResult<IdeaEntry>;
|
|
31
|
-
/** ideas.md is split into sections by `---` separators. Each section has an optional
|
|
32
|
-
* `## IDEA-N:` heading prefix followed by a short title, and a prose body. */
|
|
33
15
|
export declare function parseIdeas(markdown: string): IdeaEntry[];
|
|
34
|
-
/** Read-only cross-reference checks over already-parsed decisions/open-questions/plans —
|
|
35
|
-
* dangling `resolved-by`/`superseded-by` titles, and open questions blocking an
|
|
36
|
-
* already-active plan. */
|
|
37
16
|
export declare function findConsistencyIssues(decisions: DecisionEntry[], openQuestions: OpenQuestionEntry[], plans: PlanEntry[]): ConsistencyIssue[];
|
|
38
|
-
/** progress.md is an append-only date log, not a record-based file — no fields, no validation. */
|
|
39
17
|
export declare function parseProgress(markdown: string): ProgressEntry[];
|
|
18
|
+
/** tasks.log is JSON Lines — one TaskLogEntry per line. Skip lines that fail to parse rather than fail the whole read (a truncated last line from a crash shouldn't hide the rest). */
|
|
19
|
+
export declare function parseTaskLog(raw: string): TaskLogEntry[];
|
|
40
20
|
export declare const SUGGESTION_ENTRY_RE: RegExp;
|
|
41
|
-
/**
|
|
42
|
-
* suggestions.md is a flat, append-only line log — sibling to decisions.md/
|
|
43
|
-
* open-questions.md/progress.md but with no `## Heading` per entry and no
|
|
44
|
-
* `**Field:**` lines: each line already carries its own date, title, and a
|
|
45
|
-
* one-line description (like plans' dated `### Log` grammar), and there is
|
|
46
|
-
* no `id` or `status` since a suggestion never counts as a plan/idea until a
|
|
47
|
-
* human promotes it.
|
|
48
|
-
*/
|
|
49
21
|
export declare function parseSuggestions(markdown: string): SuggestionEntry[];
|
|
50
22
|
//# sourceMappingURL=parser.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parser.d.ts","sourceRoot":"","sources":["../../../src/core/parse/parser.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAC7B,OAAO,KAAK,EACV,gBAAgB,EAChB,aAAa,EACb,WAAW,EACX,SAAS,
|
|
1
|
+
{"version":3,"file":"parser.d.ts","sourceRoot":"","sources":["../../../src/core/parse/parser.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAC7B,OAAO,KAAK,EACV,gBAAgB,EAChB,aAAa,EACb,WAAW,EACX,SAAS,EAGT,iBAAiB,EACjB,WAAW,EACX,YAAY,EAEZ,SAAS,EACT,aAAa,EACb,QAAQ,EACR,eAAe,EACf,YAAY,EACb,MAAM,mBAAmB,CAAC;AAqD3B,wBAAgB,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,QAAQ,EAAE,CAoC5D;AAED,wBAAgB,UAAU,CAAC,QAAQ,EAAE,MAAM,GAAG,WAAW,CAAC,SAAS,CAAC,CAqCnE;AAED,wBAAgB,cAAc,CAAC,QAAQ,EAAE,MAAM,GAAG,WAAW,CAAC,aAAa,CAAC,CAwB3E;AAED,wBAAgB,kBAAkB,CAAC,QAAQ,EAAE,MAAM,GAAG,WAAW,CAAC,iBAAiB,CAAC,CAyBnF;AAID,wBAAgB,gBAAgB,CAAC,CAAC,EAChC,OAAO,EAAE,MAAM,EACf,MAAM,EAAE,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,GACnB;IAAE,IAAI,EAAE,CAAC,GAAG,IAAI,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,YAAY,EAAE,CAAA;CAAE,CAyC5D;AAED,wBAAgB,eAAe,CAAC,OAAO,EAAE,MAAM,GAAG,WAAW,CAAC,WAAW,CAAC,CA2CzE;AAED,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,GAAG,WAAW,CAAC,SAAS,CAAC,CAkCrE;AAED,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,GAAG,WAAW,CAAC,SAAS,CAAC,CAuBrE;AAMD,wBAAgB,UAAU,CAAC,QAAQ,EAAE,MAAM,GAAG,SAAS,EAAE,CAYxD;AAED,wBAAgB,qBAAqB,CACnC,SAAS,EAAE,aAAa,EAAE,EAC1B,aAAa,EAAE,iBAAiB,EAAE,EAClC,KAAK,EAAE,SAAS,EAAE,GACjB,gBAAgB,EAAE,CA0CpB;AAKD,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,GAAG,aAAa,EAAE,CAwB/D;AAED,uLAAuL;AACvL,wBAAgB,YAAY,CAAC,GAAG,EAAE,MAAM,GAAG,YAAY,EAAE,CAUxD;AAED,eAAO,MAAM,mBAAmB,QAAkD,CAAC;AAGnF,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,MAAM,GAAG,eAAe,EAAE,CASpE"}
|
|
@@ -124,6 +124,8 @@ export declare const entityFrontmatterSchema: z.ZodObject<{
|
|
|
124
124
|
audited: z.ZodOptional<z.ZodString>;
|
|
125
125
|
'audited-hash': z.ZodOptional<z.ZodString>;
|
|
126
126
|
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
127
|
+
subject: z.ZodOptional<z.ZodString>;
|
|
128
|
+
order: z.ZodOptional<z.ZodNumber>;
|
|
127
129
|
}, z.core.$strip>;
|
|
128
130
|
export declare const paperCampConfigSchema: z.ZodObject<{
|
|
129
131
|
version: z.ZodString;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schemas.d.ts","sourceRoot":"","sources":["../../../src/core/parse/schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,eAAO,MAAM,iBAAiB;;;;;;;kBAO7B,CAAC;AAEF,eAAO,MAAM,UAAU,aAAiE,CAAC;
|
|
1
|
+
{"version":3,"file":"schemas.d.ts","sourceRoot":"","sources":["../../../src/core/parse/schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,eAAO,MAAM,iBAAiB;;;;;;;kBAO7B,CAAC;AAEF,eAAO,MAAM,UAAU,aAAiE,CAAC;AAIzF,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;iBAS3B,CAAC;AAEH,eAAO,MAAM,oBAAoB;;;;;;;iBAI/B,CAAC;AAEH,eAAO,MAAM,wBAAwB;;;;;;;;iBAKnC,CAAC;AAKH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAmBhC,CAAC;AAEH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;iBAgB9B,CAAC;AAIL,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAwDhC,CAAC;AAEL,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAyBhC,CAAC;AAEH,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAC1D,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAClE,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAC1E,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AACpE,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AACpE,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC"}
|
package/dist/core/readers.d.ts
CHANGED
|
@@ -1,37 +1,11 @@
|
|
|
1
|
-
import { EntityEntry, IdeaEntry, ParseResult, PlanEntry, PrInfo } from '../types/index';
|
|
2
|
-
/**
|
|
3
|
-
* Reads every entity from the unified directory, including its `archive/`
|
|
4
|
-
* subdirectory (done/dropped entities live there). Excludes index.md.
|
|
5
|
-
*/
|
|
1
|
+
import { ArchivableIdea, EntityEntry, IdeaEntry, ParseResult, PlanEntry, PrInfo } from '../types/index';
|
|
6
2
|
export declare function readEntities(ideasDir: string): Promise<ParseResult<EntityEntry> & {
|
|
7
3
|
fileCount: number;
|
|
8
4
|
}>;
|
|
9
|
-
/**
|
|
10
|
-
* PlanEntry view of a work entity (anything that isn't a note): `kind` is the
|
|
11
|
-
* entity's `type`. Lets the plan-shaped pipeline (API responses, prompts, UI)
|
|
12
|
-
* keep working until the UI morphs to entities directly.
|
|
13
|
-
*
|
|
14
|
-
* `status` is derived from phases + PR state rather than read straight off
|
|
15
|
-
* `e.status` — see `deriveStatus`. `pr` is the entity's resolved PR (or
|
|
16
|
-
* `undefined`); `prLookupResolved` is whether the PR listing succeeded (a
|
|
17
|
-
* failed/absent lookup falls back to the stored override). Note this only
|
|
18
|
-
* affects the *view*: `e.status` itself stays the raw stored override, so
|
|
19
|
-
* round-tripping an `EntityEntry` back to disk never persists a derived value.
|
|
20
|
-
*/
|
|
21
5
|
export declare function entityToPlan(e: EntityEntry, pr?: PrInfo, prLookupResolved?: boolean): PlanEntry;
|
|
22
|
-
/** IdeaEntry view of a note entity, for the note-shaped API/UI surface. */
|
|
23
6
|
export declare function entityToIdea(e: EntityEntry): IdeaEntry;
|
|
24
|
-
/**
|
|
25
|
-
* Every entity (including notes) with `status` replaced by its derived value —
|
|
26
|
-
* for callers that need the resolved lifecycle without the PlanEntry reshape,
|
|
27
|
-
* namely index generation and the branch-guard. One `gh` PR listing resolves
|
|
28
|
-
* every entity's PR (matched by id), cached. This is a shallow copy: it never
|
|
29
|
-
* touches disk, so it's safe to feed straight back into
|
|
30
|
-
* `entityToPlan`/`deriveStatus` elsewhere without risking a stale-status write.
|
|
31
|
-
*/
|
|
32
7
|
export declare function readEntitiesWithDerivedStatus(ideasDir: string): Promise<ParseResult<EntityEntry>>;
|
|
33
|
-
/** All work entities (non-notes) in PlanEntry shape — the `/api/plans` view. */
|
|
34
8
|
export declare function readWorkEntries(ideasDir: string): Promise<ParseResult<PlanEntry>>;
|
|
35
|
-
|
|
9
|
+
export declare function findArchivableIdeas(ideasDir: string): Promise<ArchivableIdea[]>;
|
|
36
10
|
export declare function readNoteEntries(ideasDir: string): Promise<ParseResult<IdeaEntry>>;
|
|
37
11
|
//# sourceMappingURL=readers.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"readers.d.ts","sourceRoot":"","sources":["../../src/core/readers.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EACV,WAAW,EACX,SAAS,EAET,WAAW,EAEX,SAAS,EAET,MAAM,EACP,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"readers.d.ts","sourceRoot":"","sources":["../../src/core/readers.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EACV,cAAc,EACd,WAAW,EACX,SAAS,EAET,WAAW,EAEX,SAAS,EAET,MAAM,EACP,MAAM,gBAAgB,CAAC;AAqBxB,wBAAsB,YAAY,CAChC,QAAQ,EAAE,MAAM,GACf,OAAO,CAAC,WAAW,CAAC,WAAW,CAAC,GAAG;IAAE,SAAS,EAAE,MAAM,CAAA;CAAE,CAAC,CA2B3D;AAKD,wBAAgB,YAAY,CAAC,CAAC,EAAE,WAAW,EAAE,EAAE,CAAC,EAAE,MAAM,EAAE,gBAAgB,UAAQ,GAAG,SAAS,CAqB7F;AAED,wBAAgB,YAAY,CAAC,CAAC,EAAE,WAAW,GAAG,SAAS,CAYtD;AAWD,wBAAsB,6BAA6B,CACjD,QAAQ,EAAE,MAAM,GACf,OAAO,CAAC,WAAW,CAAC,WAAW,CAAC,CAAC,CAOnC;AAED,wBAAsB,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,CAAC,SAAS,CAAC,CAAC,CAQvF;AAID,wBAAsB,mBAAmB,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,cAAc,EAAE,CAAC,CAMrF;AAED,wBAAsB,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,CAAC,SAAS,CAAC,CAAC,CAMvF"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { Roadmap } from '../types/index';
|
|
2
|
+
export declare function parseRoadmap(markdown: string): Roadmap;
|
|
3
|
+
export declare function removeRoadmapItem(markdown: string, horizonTitle: string, itemName: string, candidateName?: string): string;
|
|
4
|
+
//# sourceMappingURL=roadmap.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"roadmap.d.ts","sourceRoot":"","sources":["../../src/core/roadmap.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAe,MAAM,gBAAgB,CAAC;AAuC3D,wBAAgB,YAAY,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CA2BtD;AAMD,wBAAgB,iBAAiB,CAC/B,QAAQ,EAAE,MAAM,EAChB,YAAY,EAAE,MAAM,EACpB,QAAQ,EAAE,MAAM,EAChB,aAAa,CAAC,EAAE,MAAM,GACrB,MAAM,CAsCR"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"roadmap.test.d.ts","sourceRoot":"","sources":["../../src/core/roadmap.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/** Classification input — status must be the DERIVED status (what the UI shows),
|
|
2
|
+
* not the stored frontmatter override, or merged-PR `done` entries get ordered. */
|
|
3
|
+
export interface RunOrderEntry {
|
|
4
|
+
id: string;
|
|
5
|
+
status?: string;
|
|
6
|
+
order?: number;
|
|
7
|
+
created: string;
|
|
8
|
+
}
|
|
9
|
+
export declare function isRunOrdered(entry: Pick<RunOrderEntry, 'status'>): boolean;
|
|
10
|
+
export interface RunOrderChange {
|
|
11
|
+
id: string;
|
|
12
|
+
order: number | undefined;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Enforces the run-order invariant: every planned/in-progress/review entry
|
|
16
|
+
* carries a contiguous 1..N order, everything else carries none. `moved`
|
|
17
|
+
* places that entry at the requested slot (clamped) before renumbering.
|
|
18
|
+
*/
|
|
19
|
+
export declare function normalizeRunOrder(entries: RunOrderEntry[], moved?: {
|
|
20
|
+
id: string;
|
|
21
|
+
order: number;
|
|
22
|
+
}): RunOrderChange[];
|
|
23
|
+
//# sourceMappingURL=run-order.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"run-order.d.ts","sourceRoot":"","sources":["../../src/core/run-order.ts"],"names":[],"mappings":"AAEA;oFACoF;AACpF,MAAM,WAAW,aAAa;IAC5B,EAAE,EAAE,MAAM,CAAC;IACX,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,wBAAgB,YAAY,CAAC,KAAK,EAAE,IAAI,CAAC,aAAa,EAAE,QAAQ,CAAC,GAAG,OAAO,CAE1E;AAED,MAAM,WAAW,cAAc;IAC7B,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,GAAG,SAAS,CAAC;CAC3B;AAED;;;;GAIG;AACH,wBAAgB,iBAAiB,CAC/B,OAAO,EAAE,aAAa,EAAE,EACxB,KAAK,CAAC,EAAE;IAAE,EAAE,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,GACpC,cAAc,EAAE,CA2BlB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"run-order.test.d.ts","sourceRoot":"","sources":["../../src/core/run-order.test.ts"],"names":[],"mappings":""}
|