@dendelion/paper-camp 0.8.0 → 0.9.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-DGXi8vpJ.js → index-C0wWs5ba.js} +2 -2
- package/dist/app/assets/index-C0wWs5ba.js.map +1 -0
- package/dist/app/assets/{index-CF8jC3IN.js → index-D-nmg_4I.js} +2 -2
- package/dist/app/assets/{index-CF8jC3IN.js.map → index-D-nmg_4I.js.map} +1 -1
- package/dist/app/assets/index-Djq8LvrZ.js +3 -0
- package/dist/app/assets/index-Djq8LvrZ.js.map +1 -0
- package/dist/app/assets/main-BA1w2y_E.css +1 -0
- package/dist/app/assets/main-DUy5DFoq.js +218 -0
- package/dist/app/assets/main-DUy5DFoq.js.map +1 -0
- package/dist/app/assets/{sidebar-section-C2j12TzE.js → sidebar-section-mXpllayv.js} +2 -2
- package/dist/app/assets/{sidebar-section-C2j12TzE.js.map → sidebar-section-mXpllayv.js.map} +1 -1
- package/dist/app/index.html +2 -2
- package/dist/chunks/{serializer.BfH7zTwv.js → serializer.DqcFa2e1.js} +75 -66
- package/dist/chunks/serializer.DqcFa2e1.js.map +1 -0
- package/dist/cli/index.js +6187 -6079
- 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 +0 -76
- 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.js +36 -35
- 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.map +1 -1
- package/dist/core/readers.d.ts +0 -27
- package/dist/core/readers.d.ts.map +1 -1
- 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/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 +0 -60
- package/dist/core/serialize/serializer.d.ts.map +1 -1
- package/dist/core/status/status.d.ts +0 -19
- package/dist/core/status/status.d.ts.map +1 -1
- package/dist/types/index.d.ts +12 -29
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/index.js.map +1 -1
- package/package.json +1 -1
- 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/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;AA8BD,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,25 @@
|
|
|
1
1
|
import { ConsistencyIssue, EntityType, PhaseItem } from '../../types/index';
|
|
2
2
|
export { clearPrCache, fetchUnresolvedThreads, replyToReviewThread, resolvePrsByEntity, resolveReviewThread, } from './pr-lookup';
|
|
3
|
-
/** The fields later Scout workflows need to mirror a plan onto its PR. */
|
|
4
3
|
export 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
11
|
export type SyncPlanPhasesResult = 'updated' | 'unchanged' | 'unresolved';
|
|
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
12
|
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
|
-
*/
|
|
45
13
|
export declare function derivePrLabels(plan: Pick<ResolvedPlanForPr, 'kind' | 'tags'>): string[];
|
|
46
14
|
export type SyncPrLabelsResult = 'updated' | 'unchanged' | 'unresolved';
|
|
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
15
|
export declare function syncPrLabelsToPr(root: string, ref: string): Promise<SyncPrLabelsResult>;
|
|
57
16
|
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
17
|
export declare function syncPrReadinessToPr(root: string, ref: string): Promise<SyncPrReadinessResult>;
|
|
71
18
|
interface AuditSummary {
|
|
72
19
|
audited: string;
|
|
73
|
-
/** Whether the plan's content has changed since the stored `audited-hash`. */
|
|
74
20
|
stale: boolean;
|
|
75
21
|
}
|
|
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
22
|
export declare function renderConsistencyComment(issues: ConsistencyIssue[], audit?: AuditSummary): string;
|
|
85
23
|
export type SyncConsistencyCommentResult = 'created' | 'updated' | 'unchanged' | 'unresolved';
|
|
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
24
|
export declare function syncConsistencyCommentToPr(root: string, ref: string): Promise<SyncConsistencyCommentResult>;
|
|
101
25
|
//# 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,MAAM,WAAW,iBAAiB;IAChC,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,MAAM,MAAM,oBAAoB,GAAG,SAAS,GAAG,WAAW,GAAG,YAAY,CAAC;AAE1E,wBAAsB,kBAAkB,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,oBAAoB,CAAC,CAUjG;AAED,wBAAgB,cAAc,CAAC,IAAI,EAAE,IAAI,CAAC,iBAAiB,EAAE,MAAM,GAAG,MAAM,CAAC,GAAG,MAAM,EAAE,CAOvF;AAyDD,MAAM,MAAM,kBAAkB,GAAG,SAAS,GAAG,WAAW,GAAG,YAAY,CAAC;AAExE,wBAAsB,gBAAgB,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,kBAAkB,CAAC,CAoB7F;AA0BD,MAAM,MAAM,qBAAqB,GAAG,OAAO,GAAG,QAAQ,GAAG,WAAW,GAAG,YAAY,CAAC;AAEpF,wBAAsB,mBAAmB,CACvC,IAAI,EAAE,MAAM,EACZ,GAAG,EAAE,MAAM,GACV,OAAO,CAAC,qBAAqB,CAAC,CAgBhC;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;AAiDD,MAAM,MAAM,4BAA4B,GAAG,SAAS,GAAG,SAAS,GAAG,WAAW,GAAG,YAAY,CAAC;AAE9F,wBAAsB,0BAA0B,CAC9C,IAAI,EAAE,MAAM,EACZ,GAAG,EAAE,MAAM,GACV,OAAO,CAAC,4BAA4B,CAAC,CAuCvC"}
|
|
@@ -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.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { A as e, C as r, a as n, P as t, S as i, b as o, c as l, d as E, e as d, f as m, g as P, h as p, i as S, j as c, k as
|
|
2
|
-
import { AGENT_IDS as ha, AGENT_LABELS as Ia, AGENT_OPTIONS as
|
|
1
|
+
import { A as e, C as r, a as n, P as t, S as i, b as o, c as l, d as E, e as d, f as m, g as P, h as p, i as S, j as c, k as T, l as y, m as f, n as h, o as I, p as g, q as F, r as N, s as C, t as _, u as A, v, w as L, x as O, y as u, z as D, B as R, D as G, E as U, F as b, G as B, H as M, I as Q, J as k, K as w, L as x, M as z, N as K, O as W, Q as j, 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 la, a7 as Ea, a8 as da, a9 as ma, aa as Pa, ab as pa, ac as Sa, ad as ca, ae as Ta, af as ya } from "../chunks/serializer.DqcFa2e1.js";
|
|
2
|
+
import { AGENT_IDS as ha, AGENT_LABELS as Ia, AGENT_OPTIONS as ga, DEFAULT_AGENTS as Fa, PLAN_KINDS as Na, PLAN_STATUSES as Ca, coerceAgentConfig as _a } from "../types/index.js";
|
|
3
3
|
export {
|
|
4
4
|
ha as AGENT_IDS,
|
|
5
5
|
Ia as AGENT_LABELS,
|
|
6
|
-
|
|
6
|
+
ga as AGENT_OPTIONS,
|
|
7
7
|
e as AlreadyInitializedError,
|
|
8
8
|
r as CLAUDE_SETTINGS_JSON,
|
|
9
9
|
n as COMMIT_SCOPES,
|
|
10
10
|
Fa as DEFAULT_AGENTS,
|
|
11
11
|
t as PAPER_CAMP_VERSION,
|
|
12
12
|
Na as PLAN_KINDS,
|
|
13
|
-
|
|
13
|
+
Ca as PLAN_STATUSES,
|
|
14
14
|
i as SKILL_MD_CONTENT,
|
|
15
15
|
o as SUGGESTION_ENTRY_RE,
|
|
16
16
|
l as agentConfigSchema,
|
|
@@ -21,15 +21,15 @@ export {
|
|
|
21
21
|
p as assignPlanId,
|
|
22
22
|
S as branchName,
|
|
23
23
|
c as clearPrCache,
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
24
|
+
_a as coerceAgentConfig,
|
|
25
|
+
T as computePlanContentHash,
|
|
26
|
+
y as dateString,
|
|
27
|
+
f as decisionFieldsSchema,
|
|
28
|
+
h as derivePrLabels,
|
|
29
|
+
I as entityFrontmatterSchema,
|
|
30
|
+
g as entityToIdea,
|
|
31
|
+
F as entityToPlan,
|
|
32
|
+
N as fetchUnresolvedThreads,
|
|
33
33
|
C as findConsistencyIssues,
|
|
34
34
|
_ as formatDecisionEntry,
|
|
35
35
|
A as formatEntitiesIndex,
|
|
@@ -45,9 +45,9 @@ export {
|
|
|
45
45
|
B as initProject,
|
|
46
46
|
M as openQuestionFieldsSchema,
|
|
47
47
|
Q as paperCampConfigSchema,
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
48
|
+
k as parseDecisions,
|
|
49
|
+
w as parseEntityFile,
|
|
50
|
+
x as parseEnv,
|
|
51
51
|
z as parseFrontmatter,
|
|
52
52
|
K as parseIdeaFile,
|
|
53
53
|
W as parseIdeas,
|
|
@@ -57,25 +57,26 @@ export {
|
|
|
57
57
|
V as parseProgress,
|
|
58
58
|
Y as parseRawEntries,
|
|
59
59
|
q as parseSuggestions,
|
|
60
|
-
X as
|
|
61
|
-
Z as
|
|
62
|
-
$ as
|
|
63
|
-
aa as
|
|
64
|
-
sa as
|
|
65
|
-
ea as
|
|
66
|
-
ra as
|
|
67
|
-
na as
|
|
68
|
-
ta as
|
|
69
|
-
ia as
|
|
70
|
-
oa as
|
|
71
|
-
la as
|
|
72
|
-
Ea as
|
|
73
|
-
da as
|
|
74
|
-
ma as
|
|
75
|
-
Pa as
|
|
76
|
-
pa as
|
|
77
|
-
Sa as
|
|
78
|
-
ca as
|
|
60
|
+
X as parseTaskLog,
|
|
61
|
+
Z as planFieldsSchema,
|
|
62
|
+
$ as planFrontmatterSchema,
|
|
63
|
+
aa as prependProgressItem,
|
|
64
|
+
sa as readEntities,
|
|
65
|
+
ea as readEntitiesWithDerivedStatus,
|
|
66
|
+
ra as readNoteEntries,
|
|
67
|
+
na as readWorkEntries,
|
|
68
|
+
ta as removeSuggestionLine,
|
|
69
|
+
ia as renderConsistencyComment,
|
|
70
|
+
oa as renderPlanPhasesIntoBody,
|
|
71
|
+
la as replyToReviewThread,
|
|
72
|
+
Ea as resolvePlanForPrRef,
|
|
73
|
+
da as resolvePrsByEntity,
|
|
74
|
+
ma as resolveReviewThread,
|
|
75
|
+
Pa as serializeFrontmatter,
|
|
76
|
+
pa as syncConsistencyCommentToPr,
|
|
77
|
+
Sa as syncPlanPhasesToPr,
|
|
78
|
+
ca as syncPrLabelsToPr,
|
|
79
|
+
Ta as syncPrReadinessToPr,
|
|
79
80
|
ya as todayDateString
|
|
80
81
|
};
|
|
81
82
|
//# 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,EAET,iBAAiB,EACjB,WAAW,EACX,YAAY,EAEZ,SAAS,EACT,aAAa,EACb,QAAQ,EACR,eAAe,
|
|
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,EAET,iBAAiB,EACjB,WAAW,EACX,YAAY,EAEZ,SAAS,EACT,aAAa,EACb,QAAQ,EACR,eAAe,EACf,YAAY,EACb,MAAM,mBAAmB,CAAC;AA4H3B,wBAAgB,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,QAAQ,EAAE,CAwC5D;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,CA+CzE;AAED,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,GAAG,WAAW,CAAC,SAAS,CAAC,CAwCrE;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"}
|
|
@@ -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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA+ChC,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,10 @@
|
|
|
1
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
|
-
*/
|
|
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
|
-
/** All note entities in IdeaEntry shape — the `/api/ideas` view. */
|
|
36
9
|
export declare function readNoteEntries(ideasDir: string): Promise<ParseResult<IdeaEntry>>;
|
|
37
10
|
//# 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,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,CAwB3D;AAKD,wBAAgB,YAAY,CAAC,CAAC,EAAE,WAAW,EAAE,EAAE,CAAC,EAAE,MAAM,EAAE,gBAAgB,UAAQ,GAAG,SAAS,CAmB7F;AAED,wBAAgB,YAAY,CAAC,CAAC,EAAE,WAAW,GAAG,SAAS,CAStD;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;AAED,wBAAsB,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,CAAC,SAAS,CAAC,CAAC,CAMvF"}
|
|
@@ -6,11 +6,5 @@ export interface InitOptions {
|
|
|
6
6
|
projectName: string;
|
|
7
7
|
intent?: string;
|
|
8
8
|
}
|
|
9
|
-
/**
|
|
10
|
-
* Scaffolds papercamp/config.json and papercamp/ directory structure.
|
|
11
|
-
* Creates per-file plan/idea directories and index files, plus monolithic
|
|
12
|
-
* files for the remaining sections (progress, decisions, open-questions).
|
|
13
|
-
* Never overwrites existing files.
|
|
14
|
-
*/
|
|
15
9
|
export declare function initProject(targetDir: string, options: InitOptions): Promise<void>;
|
|
16
10
|
//# sourceMappingURL=scaffold.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scaffold.d.ts","sourceRoot":"","sources":["../../../src/core/scaffold/scaffold.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,kBAAkB,UAAU,CAAC;AAE1C,qBAAa,uBAAwB,SAAQ,KAAK;gBACpC,SAAS,EAAE,MAAM;CAG9B;AAaD,MAAM,WAAW,WAAW;IAC1B,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED
|
|
1
|
+
{"version":3,"file":"scaffold.d.ts","sourceRoot":"","sources":["../../../src/core/scaffold/scaffold.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,kBAAkB,UAAU,CAAC;AAE1C,qBAAa,uBAAwB,SAAQ,KAAK;gBACpC,SAAS,EAAE,MAAM;CAG9B;AAaD,MAAM,WAAW,WAAW;IAC1B,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,wBAAsB,WAAW,CAAC,SAAS,EAAE,MAAM,EAAE,OAAO,EAAE,WAAW,GAAG,OAAO,CAAC,IAAI,CAAC,CAwCxF"}
|
|
@@ -1,9 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Static file contents scaffolded by `paper-camp init` for the Claude Code
|
|
3
|
-
* native integration: the discoverable skill and the SessionStart/PostToolUse
|
|
4
|
-
* hook wiring. Kept in one place so `init`'s no-clobber writes stay simple
|
|
5
|
-
* string dumps.
|
|
6
|
-
*/
|
|
7
1
|
export declare const SKILL_MD_CONTENT = "---\nname: paper-camp\ndescription: Work inside a project that has a papercamp/ folder \u2014 its unified idea entities (each holding its plan as a section), decisions log, open questions, and progress log. Use this whenever the working directory contains papercamp/ (papercamp/ideas/, papercamp/decisions.md, papercamp/open-questions.md, papercamp/progress.md), and especially before starting, continuing, or completing any plan phase, drafting an idea, logging a decision, or answering \"what are we working on / what's next\".\n---\n\n# Paper Camp\n\nPaper Camp is this project's planning methodology: plans, ideas, decisions, and\nopen questions live as markdown files under `papercamp/`, and an append-only\n`papercamp/progress.md` is the changelog. This skill tells you how to read that\nstate before acting and how to keep it honest as you work.\n\nIf a `papercamp` MCP server is connected in this session, prefer its tools\n(list/get plans, update phase, append progress, etc.) over raw file access \u2014\nthey enforce the same guards (id allocation, branch conflicts) that the file\ngrammar below assumes. Everything in this skill still applies conceptually;\nonly the mechanism changes.\n\n## Before doing any work\n\nRead, in this order, whatever exists:\n\n1. `papercamp/ideas/index.md` \u2014 every entity's id/title/type/status/tags, at\n a glance. Ideas and plans are one thing: an entity is an *idea* for its\n whole life, and its plan is a `### Phases` section inside the same file.\n2. The specific entity file at `papercamp/ideas/<ID>.md` (e.g. `IDEA-43.md`)\n for the work you're about to do \u2014 YAML frontmatter (`id`, `title`,\n `type`, `status`, `tags`, ...) plus prose rationale, then optionally a\n `### Phases` list of `- [ ]`/`- [x]` checkboxes with an indented\n description under each. Done/dropped entities live in\n `papercamp/ideas/archive/`.\n3. `papercamp/decisions.md` \u2014 settled calls that constrain your approach.\n Don't re-litigate a logged decision without flagging it to the user first.\n4. `papercamp/open-questions.md` \u2014 unresolved questions that might block or\n redirect the work you're about to start.\n5. The last handful of entries in `papercamp/progress.md` for recent context\n on what just happened.\n\nSkip files that don't exist yet (a fresh project may have empty logs).\n\n## While working\n\n- Work one plan phase at a time unless told otherwise \u2014 don't cascade into\n later phases just because they look quick.\n- If a phase's boundary or intent is unclear, ask before continuing.\n- Prose in plans and ideas is more current than your memory of past\n conversations. If they conflict, the files win \u2014 say so and resync.\n\n## Keep the project current as you go\n\n- **Plan phases**: when you finish a phase, flip its checkbox from `- [ ]` to\n `- [x]` in the plan's frontmatter file. Change only that line \u2014 don't touch\n other phases or prose.\n- **Plan status**: keep the plan's `status:` frontmatter honest\n (`planned` / `in-progress` / `review` / `done`). When every phase is\n checked, set status to `review` \u2014 never `done`. `done` is a human-only\n promotion after review; an agent finishing the last phase does not close\n the plan itself.\n- **Progress log**: add one bullet describing what you did under today's\n `## YYYY-MM-DD` heading at the top of `papercamp/progress.md` (newest day\n first; create the heading if today's isn't there yet). Be specific enough\n that a future read of the log alone explains what changed and why, without\n needing to re-read the diff.\n- **Decisions / open questions**: if you settle something ambiguous while\n working, log it in `papercamp/decisions.md`; if you surface a question you\n can't resolve yourself, add it to `papercamp/open-questions.md` rather than\n guessing silently.\n\n## What this skill deliberately does not do\n\nIt does not maintain a separate \"current focus\" file \u2014 that's derived at\nsession start from live plan/progress data, not hand-maintained here. It does\nnot define the file formats in full; treat the existing files under\n`papercamp/` as the grammar reference (mirror their structure exactly rather\nthan inventing a new shape).\n";
|
|
8
2
|
export declare const CLAUDE_SETTINGS_JSON: string;
|
|
9
3
|
//# sourceMappingURL=templates.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"templates.d.ts","sourceRoot":"","sources":["../../../src/core/scaffold/templates.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"templates.d.ts","sourceRoot":"","sources":["../../../src/core/scaffold/templates.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,gBAAgB,0pIA2E5B,CAAC;AAIF,eAAO,MAAM,oBAAoB,QAmB5B,CAAC"}
|
|
@@ -3,12 +3,6 @@ interface PlanContentInput {
|
|
|
3
3
|
body: string;
|
|
4
4
|
phases: PhaseItem[];
|
|
5
5
|
}
|
|
6
|
-
/**
|
|
7
|
-
* Hashes a plan's meaningful content (phases + body prose), deliberately
|
|
8
|
-
* ignoring `audited`/`audited-hash` and any other metadata so that
|
|
9
|
-
* stamping the audit fields never changes the hash of the content it
|
|
10
|
-
* describes.
|
|
11
|
-
*/
|
|
12
6
|
export declare function computePlanContentHash(plan: PlanContentInput): string;
|
|
13
7
|
export {};
|
|
14
8
|
//# sourceMappingURL=content-hash.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"content-hash.d.ts","sourceRoot":"","sources":["../../../src/core/serialize/content-hash.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAEnD,UAAU,gBAAgB;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,SAAS,EAAE,CAAC;CACrB;
|
|
1
|
+
{"version":3,"file":"content-hash.d.ts","sourceRoot":"","sources":["../../../src/core/serialize/content-hash.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAEnD,UAAU,gBAAgB;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,SAAS,EAAE,CAAC;CACrB;AAID,wBAAgB,sBAAsB,CAAC,IAAI,EAAE,gBAAgB,GAAG,MAAM,CAWrE"}
|