@dendelion/paper-camp 0.31.1 → 0.32.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/chunks/{phase-progress.CazP7K7B.js → phase-progress.Cos0IBFk.js} +136 -133
- package/dist/chunks/phase-progress.Cos0IBFk.js.map +1 -0
- package/dist/cli/index.js +6309 -5997
- package/dist/cli/index.js.map +1 -1
- package/dist/core/chat-file.d.ts +9 -0
- package/dist/core/chat-file.d.ts.map +1 -0
- package/dist/core/chat-file.test.d.ts +2 -0
- package/dist/core/chat-file.test.d.ts.map +1 -0
- package/dist/core/commit-convention.d.ts +13 -0
- package/dist/core/commit-convention.d.ts.map +1 -0
- package/dist/core/commit-convention.test.d.ts +2 -0
- package/dist/core/commit-convention.test.d.ts.map +1 -0
- package/dist/core/desk-discovery/evidence.d.ts +9 -0
- package/dist/core/desk-discovery/evidence.d.ts.map +1 -1
- package/dist/core/index.js +1 -1
- package/dist/core/sections.d.ts.map +1 -1
- package/dist/core/serialize/entity-file.d.ts +1 -1
- package/dist/core/serialize/entity-file.d.ts.map +1 -1
- package/dist/toolbar/toolbar.js +1372 -1343
- package/dist/toolbar/toolbar.js.map +1 -1
- package/dist/types/index.d.ts +4 -1
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/index.js.map +1 -1
- package/package.json +1 -1
- package/dist/chunks/phase-progress.CazP7K7B.js.map +0 -1
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { readFile as q, mkdir as oe, writeFile as B, readdir as ct, stat as wi, rename as bi, access as ki } from "node:fs/promises";
|
|
2
|
-
import { dirname as Xe, join as
|
|
2
|
+
import { dirname as Xe, join as $, basename as Si } from "node:path";
|
|
3
3
|
import { spawn as D } from "node:child_process";
|
|
4
4
|
import { AGENT_IDS as Pe, NIGHT_CHECK_IDS as Ei, PLAN_KINDS as Ni } from "../types/index.js";
|
|
5
5
|
import { createHash as vi } from "node:crypto";
|
|
6
|
-
import { existsSync as Ii, readFileSync as
|
|
7
|
-
import { fileURLToPath as
|
|
6
|
+
import { existsSync as Ii, readFileSync as $i } from "node:fs";
|
|
7
|
+
import { fileURLToPath as Ai } from "node:url";
|
|
8
8
|
import { y as Ti, z as Oi, e as Ci, n as _i, a as Li, t as Ri } from "./daemon-state.61FBbbsV.js";
|
|
9
9
|
import { z as g } from "zod";
|
|
10
10
|
const Pi = /^([A-Za-z_][A-Za-z0-9_]*)\s*=\s*(.*)$/;
|
|
@@ -204,7 +204,7 @@ async function Vn(n) {
|
|
|
204
204
|
}
|
|
205
205
|
return s;
|
|
206
206
|
}
|
|
207
|
-
const X = /* @__PURE__ */ new Map(), Yi = 5 * 60 * 1e3, Kt = (n) =>
|
|
207
|
+
const X = /* @__PURE__ */ new Map(), Yi = 5 * 60 * 1e3, Kt = (n) => $(n, "papercamp", "pr-map.json");
|
|
208
208
|
async function Vi(n, e, t) {
|
|
209
209
|
const s = Kt(n);
|
|
210
210
|
try {
|
|
@@ -1305,13 +1305,13 @@ function ze({ comment: n, type: e, value: t }, s, i, r) {
|
|
|
1305
1305
|
if (n && (S += " " + a(n.replace(/ ?[\r\n]+/g, " ")), i && i()), !f) {
|
|
1306
1306
|
const N = t.replace(/\n+/g, `
|
|
1307
1307
|
$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g, "$1$2").replace(/\n+/g, `$&${l}`);
|
|
1308
|
-
let
|
|
1308
|
+
let A = !1;
|
|
1309
1309
|
const I = ft(s, !0);
|
|
1310
1310
|
o !== "folded" && e !== v.BLOCK_FOLDED && (I.onOverflow = () => {
|
|
1311
|
-
|
|
1311
|
+
A = !0;
|
|
1312
1312
|
});
|
|
1313
1313
|
const k = ut(`${b}${N}${p}`, l, _t, I);
|
|
1314
|
-
if (
|
|
1314
|
+
if (!A)
|
|
1315
1315
|
return `>${S}
|
|
1316
1316
|
${l}${k}`;
|
|
1317
1317
|
}
|
|
@@ -1505,18 +1505,18 @@ ${a}:`) : (m = `${m}:`, h && (m += se(m, t.indent, l(h))));
|
|
|
1505
1505
|
_(e) ? (w = !!e.spaceBefore, b = e.commentBefore, E = e.comment) : (w = !1, b = null, E = null, e && typeof e == "object" && (e = o.createNode(e))), t.implicitKey = !1, !p && !h && O(e) && (t.indentAtStart = m.length + 1), d = !1, !f && c.length >= 2 && !t.inFlow && !p && Be(e) && !e.flow && !e.tag && !e.anchor && (t.indent = t.indent.substring(2));
|
|
1506
1506
|
let S = !1;
|
|
1507
1507
|
const N = ye(e, t, () => S = !0, () => d = !0);
|
|
1508
|
-
let
|
|
1508
|
+
let A = " ";
|
|
1509
1509
|
if (h || w || b) {
|
|
1510
|
-
if (
|
|
1510
|
+
if (A = w ? `
|
|
1511
1511
|
` : "", b) {
|
|
1512
1512
|
const I = l(b);
|
|
1513
|
-
|
|
1513
|
+
A += `
|
|
1514
1514
|
${J(I, t.indent)}`;
|
|
1515
1515
|
}
|
|
1516
|
-
N === "" && !t.inFlow ?
|
|
1517
|
-
` && E && (
|
|
1516
|
+
N === "" && !t.inFlow ? A === `
|
|
1517
|
+
` && E && (A = `
|
|
1518
1518
|
|
|
1519
|
-
`) :
|
|
1519
|
+
`) : A += `
|
|
1520
1520
|
${t.indent}`;
|
|
1521
1521
|
} else if (!p && C(e)) {
|
|
1522
1522
|
const I = N[0], k = N.indexOf(`
|
|
@@ -1527,12 +1527,12 @@ ${t.indent}`;
|
|
|
1527
1527
|
let U = N.indexOf(" ");
|
|
1528
1528
|
I === "&" && U !== -1 && U < k && N[U + 1] === "!" && (U = N.indexOf(" ", U + 1)), (U === -1 || k < U) && (V = !0);
|
|
1529
1529
|
}
|
|
1530
|
-
V || (
|
|
1530
|
+
V || (A = `
|
|
1531
1531
|
${t.indent}`);
|
|
1532
1532
|
}
|
|
1533
1533
|
} else (N === "" || N[0] === `
|
|
1534
|
-
`) && (
|
|
1535
|
-
return m +=
|
|
1534
|
+
`) && (A = "");
|
|
1535
|
+
return m += A + N, t.inFlow ? S && s && s() : E && !S ? m += se(m, t.indent, l(E)) : d && i && i(), m;
|
|
1536
1536
|
}
|
|
1537
1537
|
function fs(n, e) {
|
|
1538
1538
|
(n === "debug" || n === "warn") && console.warn(e);
|
|
@@ -2086,14 +2086,14 @@ const Ge = ({ value: n }) => JSON.stringify(n), Ir = [
|
|
|
2086
2086
|
resolve: (n) => parseFloat(n),
|
|
2087
2087
|
stringify: Ge
|
|
2088
2088
|
}
|
|
2089
|
-
],
|
|
2089
|
+
], $r = {
|
|
2090
2090
|
default: !0,
|
|
2091
2091
|
tag: "",
|
|
2092
2092
|
test: /^/,
|
|
2093
2093
|
resolve(n, e) {
|
|
2094
2094
|
return e(`Unresolved plain scalar ${JSON.stringify(n)}`), n;
|
|
2095
2095
|
}
|
|
2096
|
-
},
|
|
2096
|
+
}, Ar = [ve, Ie].concat(Ir, $r), Jt = {
|
|
2097
2097
|
identify: (n) => n instanceof Uint8Array,
|
|
2098
2098
|
// Buffer inherits from Uint8Array
|
|
2099
2099
|
default: !1,
|
|
@@ -2234,16 +2234,16 @@ const zt = {
|
|
|
2234
2234
|
createNode: (n, e, t) => pe.from(n, e, t)
|
|
2235
2235
|
};
|
|
2236
2236
|
function Is({ value: n, source: e }, t) {
|
|
2237
|
-
return e && (n ?
|
|
2237
|
+
return e && (n ? $s : As).test.test(e) ? e : n ? t.options.trueStr : t.options.falseStr;
|
|
2238
2238
|
}
|
|
2239
|
-
const
|
|
2239
|
+
const $s = {
|
|
2240
2240
|
identify: (n) => n === !0,
|
|
2241
2241
|
default: !0,
|
|
2242
2242
|
tag: "tag:yaml.org,2002:bool",
|
|
2243
2243
|
test: /^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,
|
|
2244
2244
|
resolve: () => new v(!0),
|
|
2245
2245
|
stringify: Is
|
|
2246
|
-
},
|
|
2246
|
+
}, As = {
|
|
2247
2247
|
identify: (n) => n === !1,
|
|
2248
2248
|
default: !0,
|
|
2249
2249
|
tag: "tag:yaml.org,2002:bool",
|
|
@@ -2459,8 +2459,8 @@ const Os = {
|
|
|
2459
2459
|
Ie,
|
|
2460
2460
|
ht,
|
|
2461
2461
|
pt,
|
|
2462
|
-
As,
|
|
2463
2462
|
$s,
|
|
2463
|
+
As,
|
|
2464
2464
|
_r,
|
|
2465
2465
|
Lr,
|
|
2466
2466
|
Rr,
|
|
@@ -2479,7 +2479,7 @@ const Os = {
|
|
|
2479
2479
|
], vn = /* @__PURE__ */ new Map([
|
|
2480
2480
|
["core", vr],
|
|
2481
2481
|
["failsafe", [ve, Ie, ht]],
|
|
2482
|
-
["json",
|
|
2482
|
+
["json", Ar],
|
|
2483
2483
|
["yaml11", Nn],
|
|
2484
2484
|
["yaml-1.1", Nn]
|
|
2485
2485
|
]), In = {
|
|
@@ -2818,7 +2818,7 @@ class Br extends _s {
|
|
|
2818
2818
|
super("YAMLWarning", e, t, s);
|
|
2819
2819
|
}
|
|
2820
2820
|
}
|
|
2821
|
-
const
|
|
2821
|
+
const $n = (n, e) => (t) => {
|
|
2822
2822
|
if (t.pos[0] === -1)
|
|
2823
2823
|
return;
|
|
2824
2824
|
t.linePos = t.pos.map((a) => e.linePos(a));
|
|
@@ -2880,7 +2880,7 @@ function we(n, { flow: e, indicator: t, next: s, offset: i, onError: r, parentIn
|
|
|
2880
2880
|
default:
|
|
2881
2881
|
r(k, "UNEXPECTED_TOKEN", `Unexpected ${k.type} token`), l = !1, f = !1;
|
|
2882
2882
|
}
|
|
2883
|
-
const
|
|
2883
|
+
const A = n[n.length - 1], I = A ? A.offset + A.source.length : i;
|
|
2884
2884
|
return y && s && s.type !== "space" && s.type !== "newline" && s.type !== "comma" && (s.type !== "scalar" || s.source !== "") && r(s.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space"), d && (l && d.indent <= o || (s == null ? void 0 : s.type) === "block-map" || (s == null ? void 0 : s.type) === "block-seq") && r(d, "TAB_AS_INDENT", "Tabs are not allowed as indentation"), {
|
|
2885
2885
|
comma: E,
|
|
2886
2886
|
found: S,
|
|
@@ -2942,7 +2942,7 @@ function Ls(n, e, t) {
|
|
|
2942
2942
|
const i = typeof s == "function" ? s : (r, o) => r === o || O(r) && O(o) && r.value === o.value;
|
|
2943
2943
|
return e.some((r) => i(r.key, t));
|
|
2944
2944
|
}
|
|
2945
|
-
const
|
|
2945
|
+
const An = "All mapping items must start at the same column";
|
|
2946
2946
|
function Fr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
|
|
2947
2947
|
var f;
|
|
2948
2948
|
const o = (r == null ? void 0 : r.nodeClass) ?? j, a = new o(t.schema);
|
|
@@ -2958,13 +2958,13 @@ function Fr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
|
|
|
2958
2958
|
startOnNewline: !0
|
|
2959
2959
|
}), w = !m.found;
|
|
2960
2960
|
if (w) {
|
|
2961
|
-
if (p && (p.type === "block-seq" ? i(c, "BLOCK_AS_IMPLICIT_KEY", "A block sequence may not be used as an implicit map key") : "indent" in p && p.indent !== s.indent && i(c, "BAD_INDENT",
|
|
2961
|
+
if (p && (p.type === "block-seq" ? i(c, "BLOCK_AS_IMPLICIT_KEY", "A block sequence may not be used as an implicit map key") : "indent" in p && p.indent !== s.indent && i(c, "BAD_INDENT", An)), !m.anchor && !m.tag && !y) {
|
|
2962
2962
|
l = m.end, m.comment && (a.comment ? a.comment += `
|
|
2963
2963
|
` + m.comment : a.comment = m.comment);
|
|
2964
2964
|
continue;
|
|
2965
2965
|
}
|
|
2966
2966
|
(m.newlineAfterProp || Re(p)) && i(p ?? h[h.length - 1], "MULTILINE_IMPLICIT_KEY", "Implicit keys need to be on a single line");
|
|
2967
|
-
} else ((f = m.found) == null ? void 0 : f.indent) !== s.indent && i(c, "BAD_INDENT",
|
|
2967
|
+
} else ((f = m.found) == null ? void 0 : f.indent) !== s.indent && i(c, "BAD_INDENT", An);
|
|
2968
2968
|
t.atKey = !0;
|
|
2969
2969
|
const b = m.end, E = p ? n(t, p, m, i) : e(t, b, h, null, m, i);
|
|
2970
2970
|
t.schema.compat && Pt(s.indent, p, i), t.atKey = !1, Ls(t, a.items, E) && i(b, "DUPLICATE_KEY", "Map keys must be unique");
|
|
@@ -2980,8 +2980,8 @@ function Fr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
|
|
|
2980
2980
|
w && ((d == null ? void 0 : d.type) === "block-map" && !S.hasNewline && i(c, "BLOCK_AS_IMPLICIT_KEY", "Nested mappings are not allowed in compact mappings"), t.options.strict && m.start < S.found.offset - 1024 && i(E.range, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit block mapping key"));
|
|
2981
2981
|
const N = d ? n(t, d, S, i) : e(t, c, y, null, S, i);
|
|
2982
2982
|
t.schema.compat && Pt(s.indent, d, i), c = N.range[2];
|
|
2983
|
-
const
|
|
2984
|
-
t.options.keepSourceTokens && (
|
|
2983
|
+
const A = new M(E, N);
|
|
2984
|
+
t.options.keepSourceTokens && (A.srcToken = u), a.items.push(A);
|
|
2985
2985
|
} else {
|
|
2986
2986
|
w && i(E.range, "MISSING_CHAR", "Implicit map keys need to be followed by map values"), S.comment && (E.comment ? E.comment += `
|
|
2987
2987
|
` + S.comment : E.comment = S.comment);
|
|
@@ -3052,7 +3052,7 @@ function qr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
|
|
|
3052
3052
|
f && (t.atRoot = !1), t.atKey && (t.atKey = !1);
|
|
3053
3053
|
let u = s.offset + s.start.source.length;
|
|
3054
3054
|
for (let w = 0; w < s.items.length; ++w) {
|
|
3055
|
-
const b = s.items[w], { start: E, key: S, sep: N, value:
|
|
3055
|
+
const b = s.items[w], { start: E, key: S, sep: N, value: A } = b, I = we(E, {
|
|
3056
3056
|
flow: a,
|
|
3057
3057
|
indicator: "explicit-key-ind",
|
|
3058
3058
|
next: S ?? (N == null ? void 0 : N[0]),
|
|
@@ -3062,7 +3062,7 @@ function qr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
|
|
|
3062
3062
|
startOnNewline: !1
|
|
3063
3063
|
});
|
|
3064
3064
|
if (!I.found) {
|
|
3065
|
-
if (!I.anchor && !I.tag && !N &&
|
|
3065
|
+
if (!I.anchor && !I.tag && !N && !A) {
|
|
3066
3066
|
w === 0 && I.comma ? i(I.comma, "UNEXPECTED_TOKEN", `Unexpected , in ${a}`) : w < s.items.length - 1 && i(I.start, "UNEXPECTED_TOKEN", `Unexpected empty item in ${a}`), I.comment && (l.comment ? l.comment += `
|
|
3067
3067
|
` + I.comment : l.comment = I.comment), u = I.end;
|
|
3068
3068
|
continue;
|
|
@@ -3096,8 +3096,8 @@ function qr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
|
|
|
3096
3096
|
}
|
|
3097
3097
|
}
|
|
3098
3098
|
if (!o && !N && !I.found) {
|
|
3099
|
-
const k =
|
|
3100
|
-
l.items.push(k), u = k.range[2], It(
|
|
3099
|
+
const k = A ? n(t, A, I, i) : e(t, I.end, N, null, I, i);
|
|
3100
|
+
l.items.push(k), u = k.range[2], It(A) && i(k.range, "BLOCK_IN_FLOW", vt);
|
|
3101
3101
|
} else {
|
|
3102
3102
|
t.atKey = !0;
|
|
3103
3103
|
const k = I.end, T = S ? n(t, S, I, i) : e(t, k, E, null, I, i);
|
|
@@ -3105,7 +3105,7 @@ function qr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
|
|
|
3105
3105
|
const R = we(N ?? [], {
|
|
3106
3106
|
flow: a,
|
|
3107
3107
|
indicator: "map-value-ind",
|
|
3108
|
-
next:
|
|
3108
|
+
next: A,
|
|
3109
3109
|
offset: T.range[2],
|
|
3110
3110
|
onError: i,
|
|
3111
3111
|
parentIndent: s.indent,
|
|
@@ -3124,9 +3124,9 @@ function qr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
|
|
|
3124
3124
|
}
|
|
3125
3125
|
I.start < R.found.offset - 1024 && i(R.found, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit flow sequence key");
|
|
3126
3126
|
}
|
|
3127
|
-
} else
|
|
3128
|
-
const V =
|
|
3129
|
-
V ? It(
|
|
3127
|
+
} else A && ("source" in A && ((m = A.source) == null ? void 0 : m[0]) === ":" ? i(A, "MISSING_CHAR", `Missing space after : in ${a}`) : i(R.start, "MISSING_CHAR", `Missing , or : between ${a} items`));
|
|
3128
|
+
const V = A ? n(t, A, R, i) : R.found ? e(t, R.end, N, null, R, i) : null;
|
|
3129
|
+
V ? It(A) && i(V.range, "BLOCK_IN_FLOW", vt) : R.comment && (T.comment ? T.comment += `
|
|
3130
3130
|
` + R.comment : T.comment = R.comment);
|
|
3131
3131
|
const U = new M(T, V);
|
|
3132
3132
|
if (t.options.keepSourceTokens && (U.srcToken = b), o) {
|
|
@@ -3157,7 +3157,7 @@ function qr({ composeNode: n, composeEmptyNode: e }, t, s, i, r) {
|
|
|
3157
3157
|
l.range = [s.offset, d, d];
|
|
3158
3158
|
return l;
|
|
3159
3159
|
}
|
|
3160
|
-
function
|
|
3160
|
+
function $t(n, e, t, s, i, r) {
|
|
3161
3161
|
const o = t.type === "block-map" ? Fr(n, e, t, s, r) : t.type === "block-seq" ? Kr(n, e, t, s, r) : qr(n, e, t, s, r), a = o.constructor;
|
|
3162
3162
|
return i === "!" || i === a.tagName ? (o.tag = a.tagName, o) : (i && (o.tag = i), o);
|
|
3163
3163
|
}
|
|
@@ -3170,16 +3170,16 @@ function Ur(n, e, t, s, i) {
|
|
|
3170
3170
|
}
|
|
3171
3171
|
const a = t.type === "block-map" ? "map" : t.type === "block-seq" ? "seq" : t.start.source === "{" ? "map" : "seq";
|
|
3172
3172
|
if (!r || !o || o === "!" || o === j.tagName && a === "map" || o === ae.tagName && a === "seq")
|
|
3173
|
-
return
|
|
3173
|
+
return $t(n, e, t, i, o);
|
|
3174
3174
|
let c = e.schema.tags.find((p) => p.tag === o && p.collection === a);
|
|
3175
3175
|
if (!c) {
|
|
3176
3176
|
const p = e.schema.knownTags[o];
|
|
3177
3177
|
if ((p == null ? void 0 : p.collection) === a)
|
|
3178
3178
|
e.schema.tags.push(Object.assign({}, p, { default: !1 })), c = p;
|
|
3179
3179
|
else
|
|
3180
|
-
return p ? i(r, "BAD_COLLECTION_TYPE", `${p.tag} used for ${a} collection, but expects ${p.collection ?? "scalar"}`, !0) : i(r, "TAG_RESOLVE_FAILED", `Unresolved tag: ${o}`, !0),
|
|
3180
|
+
return p ? i(r, "BAD_COLLECTION_TYPE", `${p.tag} used for ${a} collection, but expects ${p.collection ?? "scalar"}`, !0) : i(r, "TAG_RESOLVE_FAILED", `Unresolved tag: ${o}`, !0), $t(n, e, t, i, o);
|
|
3181
3181
|
}
|
|
3182
|
-
const l =
|
|
3182
|
+
const l = $t(n, e, t, i, o, c), f = ((h = c.resolve) == null ? void 0 : h.call(c, l, (p) => i(r, "TAG_RESOLVE_FAILED", p), e.options)) ?? l, u = _(f) ? f : new v(f);
|
|
3183
3183
|
return u.range = l.range, u.tag = o, c != null && c.format && (u.format = c.format), u;
|
|
3184
3184
|
}
|
|
3185
3185
|
function xr(n, e, t) {
|
|
@@ -3607,7 +3607,7 @@ function io(n, e, { offset: t, start: s, value: i, end: r }, o) {
|
|
|
3607
3607
|
const u = c.contents.range[2], h = qe(r, u, !1, o);
|
|
3608
3608
|
return h.comment && (c.comment = h.comment), c.range = [t, u, h.offset], c;
|
|
3609
3609
|
}
|
|
3610
|
-
function
|
|
3610
|
+
function Ae(n) {
|
|
3611
3611
|
if (typeof n == "number")
|
|
3612
3612
|
return [n, n + 1];
|
|
3613
3613
|
if (Array.isArray(n))
|
|
@@ -3639,7 +3639,7 @@ function Tn(n) {
|
|
|
3639
3639
|
class ro {
|
|
3640
3640
|
constructor(e = {}) {
|
|
3641
3641
|
this.doc = null, this.atDirectives = !1, this.prelude = [], this.errors = [], this.warnings = [], this.onError = (t, s, i, r) => {
|
|
3642
|
-
const o =
|
|
3642
|
+
const o = Ae(t);
|
|
3643
3643
|
r ? this.warnings.push(new Br(o, s, i)) : this.errors.push(new Oe(o, s, i));
|
|
3644
3644
|
}, this.directives = new P({ version: e.version || "1.2" }), this.options = e;
|
|
3645
3645
|
}
|
|
@@ -3702,7 +3702,7 @@ ${o}` : s;
|
|
|
3702
3702
|
switch (e.type) {
|
|
3703
3703
|
case "directive":
|
|
3704
3704
|
this.directives.add(e.source, (t, s, i) => {
|
|
3705
|
-
const r =
|
|
3705
|
+
const r = Ae(e);
|
|
3706
3706
|
r[0] += t, this.onError(r, "BAD_DIRECTIVE", s, i);
|
|
3707
3707
|
}), this.prelude.push(e.source), this.atDirectives = !0;
|
|
3708
3708
|
break;
|
|
@@ -3719,14 +3719,14 @@ ${o}` : s;
|
|
|
3719
3719
|
this.prelude.push(e.source);
|
|
3720
3720
|
break;
|
|
3721
3721
|
case "error": {
|
|
3722
|
-
const t = e.source ? `${e.message}: ${JSON.stringify(e.source)}` : e.message, s = new Oe(
|
|
3722
|
+
const t = e.source ? `${e.message}: ${JSON.stringify(e.source)}` : e.message, s = new Oe(Ae(e), "UNEXPECTED_TOKEN", t);
|
|
3723
3723
|
this.atDirectives || !this.doc ? this.errors.push(s) : this.doc.errors.push(s);
|
|
3724
3724
|
break;
|
|
3725
3725
|
}
|
|
3726
3726
|
case "doc-end": {
|
|
3727
3727
|
if (!this.doc) {
|
|
3728
3728
|
const s = "Unexpected doc-end without preceding document";
|
|
3729
|
-
this.errors.push(new Oe(
|
|
3729
|
+
this.errors.push(new Oe(Ae(e), "UNEXPECTED_TOKEN", s));
|
|
3730
3730
|
break;
|
|
3731
3731
|
}
|
|
3732
3732
|
this.doc.directives.docEnd = !0;
|
|
@@ -3740,7 +3740,7 @@ ${t.comment}` : t.comment;
|
|
|
3740
3740
|
break;
|
|
3741
3741
|
}
|
|
3742
3742
|
default:
|
|
3743
|
-
this.errors.push(new Oe(
|
|
3743
|
+
this.errors.push(new Oe(Ae(e), "UNEXPECTED_TOKEN", `Unsupported token ${e.type}`));
|
|
3744
3744
|
}
|
|
3745
3745
|
}
|
|
3746
3746
|
/**
|
|
@@ -3834,7 +3834,7 @@ function H(n) {
|
|
|
3834
3834
|
}
|
|
3835
3835
|
}
|
|
3836
3836
|
const On = new Set("0123456789ABCDEFabcdef"), ao = new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"), Ye = new Set(",[]{}"), co = new Set(` ,[]{}
|
|
3837
|
-
\r `),
|
|
3837
|
+
\r `), At = (n) => !n || co.has(n);
|
|
3838
3838
|
class lo {
|
|
3839
3839
|
constructor() {
|
|
3840
3840
|
this.atEnd = !1, this.blockScalarIndent = -1, this.blockScalarKeep = !1, this.buffer = "", this.flowKey = !1, this.flowLevel = 0, this.indentNext = 0, this.indentValue = 0, this.lineEndPos = null, this.next = null, this.pos = 0;
|
|
@@ -3994,7 +3994,7 @@ class lo {
|
|
|
3994
3994
|
case "]":
|
|
3995
3995
|
return yield* this.pushCount(1), "doc";
|
|
3996
3996
|
case "*":
|
|
3997
|
-
return yield* this.pushUntil(
|
|
3997
|
+
return yield* this.pushUntil(At), "doc";
|
|
3998
3998
|
case '"':
|
|
3999
3999
|
case "'":
|
|
4000
4000
|
return yield* this.parseQuotedScalar();
|
|
@@ -4030,7 +4030,7 @@ class lo {
|
|
|
4030
4030
|
case "]":
|
|
4031
4031
|
return yield* this.pushCount(1), this.flowKey = !0, this.flowLevel -= 1, this.flowLevel ? "flow" : "doc";
|
|
4032
4032
|
case "*":
|
|
4033
|
-
return yield* this.pushUntil(
|
|
4033
|
+
return yield* this.pushUntil(At), "flow";
|
|
4034
4034
|
case '"':
|
|
4035
4035
|
case "'":
|
|
4036
4036
|
return this.flowKey = !0, yield* this.parseQuotedScalar();
|
|
@@ -4198,7 +4198,7 @@ class lo {
|
|
|
4198
4198
|
e += yield* this.pushTag(), e += yield* this.pushSpaces(!0);
|
|
4199
4199
|
continue e;
|
|
4200
4200
|
case "&":
|
|
4201
|
-
e += yield* this.pushUntil(
|
|
4201
|
+
e += yield* this.pushUntil(At), e += yield* this.pushSpaces(!0);
|
|
4202
4202
|
continue e;
|
|
4203
4203
|
case "-":
|
|
4204
4204
|
case "?":
|
|
@@ -4939,7 +4939,7 @@ function po(n, e = {}) {
|
|
|
4939
4939
|
o.errors.push(new Oe(a.range.slice(0, 2), "MULTIPLE_DOCS", "Source contains multiple documents; please use YAML.parseAllDocuments()"));
|
|
4940
4940
|
break;
|
|
4941
4941
|
}
|
|
4942
|
-
return s && t && (o.errors.forEach(
|
|
4942
|
+
return s && t && (o.errors.forEach($n(n, t)), o.warnings.forEach($n(n, t))), o;
|
|
4943
4943
|
}
|
|
4944
4944
|
function wt(n, e, t) {
|
|
4945
4945
|
let s;
|
|
@@ -4962,7 +4962,7 @@ function mo(n, e, t) {
|
|
|
4962
4962
|
}
|
|
4963
4963
|
return De(n) && !s ? n.toString(t) : new Ke(n, s, t).toString(t);
|
|
4964
4964
|
}
|
|
4965
|
-
const Ks = /^#{2,3}\s+/, nt = /^[-*]\s+\[([ xX])\]\s+(.*)$/, go = /^\[(review|manual|issue)\]\s+(.*)$/, yo = /^run:\s*(.+)$/, Ln = /^-\s+(\d{4}-\d{2}-\d{2}):\s*(.*)$/, wo = /^\[(?:phase:(\d+)|body)\]\s+(?:\[(decision|question)\]\s+)?(.*)$/, Rn = /^-\s+\[([ xX])\]\s+(?:(\d{4}-\d{2}-\d{2})\s+)?\[(log|clarification|review|note|decision|question|chat)\]\s+(\[agent\]\s+)?(.*)$/, bo = ["note", "decision", "question"];
|
|
4965
|
+
const Ks = /^#{2,3}\s+/, nt = /^[-*]\s+\[([ xX])\]\s+(.*)$/, go = /^\[(review|manual|issue)\]\s+(.*)$/, yo = /^run:\s*(.+)$/, Ln = /^-\s+(\d{4}-\d{2}-\d{2}):\s*(.*)$/, wo = /^\[(?:phase:(\d+)|body)\]\s+(?:\[(decision|question)\]\s+)?(.*)$/, Rn = /^-\s+\[([ xX])\]\s+(?:(\d{4}-\d{2}-\d{2})\s+)?\[(log|clarification|review|note|decision|question|chat)\]\s+(\[agent\]\s+)?(?:\[\[([A-Za-z]+-\d+)\]\]\s+)?(.*)$/, bo = ["note", "decision", "question"];
|
|
4966
4966
|
function nn(n, e, t, s) {
|
|
4967
4967
|
const i = [];
|
|
4968
4968
|
let r = e;
|
|
@@ -5102,16 +5102,16 @@ function vo(n, e, t) {
|
|
|
5102
5102
|
i++;
|
|
5103
5103
|
continue;
|
|
5104
5104
|
}
|
|
5105
|
-
const o = r[3], a = nn(n, i + 1, t, Rn), c = { kind: o, text: sn(r[
|
|
5106
|
-
r[2] && (c.date = r[2]), r[4] && (c.from = "agent"), bo.includes(o) && (c.state = r[1].toLowerCase() === "x" ? "resolved" : "open"), s.push(c), i = a.next;
|
|
5105
|
+
const o = r[3], a = nn(n, i + 1, t, Rn), c = { kind: o, text: sn(r[6], a.text) };
|
|
5106
|
+
r[2] && (c.date = r[2]), r[4] && (c.from = "agent"), r[5] && (c.entityId = r[5]), bo.includes(o) && (c.state = r[1].toLowerCase() === "x" ? "resolved" : "open"), s.push(c), i = a.next;
|
|
5107
5107
|
}
|
|
5108
5108
|
return s;
|
|
5109
5109
|
}
|
|
5110
5110
|
function Io(n) {
|
|
5111
5111
|
const e = ["### Thread"];
|
|
5112
5112
|
for (const t of n) {
|
|
5113
|
-
const s = t.state ? t.state === "resolved" : !0, i = t.date ? `${t.date} ` : "", r = t.from === "agent" ? "[agent] " : "";
|
|
5114
|
-
e.push(`- [${s ? "x" : " "}] ${i}[${t.kind}] ${r}${t.text}`);
|
|
5113
|
+
const s = t.state ? t.state === "resolved" : !0, i = t.date ? `${t.date} ` : "", r = t.from === "agent" ? "[agent] " : "", o = t.entityId ? `[[${t.entityId}]] ` : "";
|
|
5114
|
+
e.push(`- [${s ? "x" : " "}] ${i}[${t.kind}] ${r}${o}${t.text}`);
|
|
5115
5115
|
}
|
|
5116
5116
|
return e;
|
|
5117
5117
|
}
|
|
@@ -5126,7 +5126,7 @@ const Hs = {
|
|
|
5126
5126
|
model: g.string().optional(),
|
|
5127
5127
|
effort: g.string().optional()
|
|
5128
5128
|
})
|
|
5129
|
-
), ee = g.string().regex(/^\d{4}-\d{2}-\d{2}$/, "expected YYYY-MM-DD"),
|
|
5129
|
+
), ee = g.string().regex(/^\d{4}-\d{2}-\d{2}$/, "expected YYYY-MM-DD"), $o = g.object({
|
|
5130
5130
|
status: g.enum(["idea", "planned", "in-progress", "review", "done", "dropped"]),
|
|
5131
5131
|
kind: g.enum(["feat", "fix", "chore", "docs", "refactor"]).optional(),
|
|
5132
5132
|
id: g.string().optional(),
|
|
@@ -5135,7 +5135,7 @@ const Hs = {
|
|
|
5135
5135
|
created: ee,
|
|
5136
5136
|
updated: ee.optional(),
|
|
5137
5137
|
tags: g.string().optional()
|
|
5138
|
-
}),
|
|
5138
|
+
}), Ao = g.object({
|
|
5139
5139
|
id: g.string().describe("Permanent plan ID, e.g. FEAT-24"),
|
|
5140
5140
|
title: g.string().describe('Human-readable plan name, e.g. "Plan storage architecture"'),
|
|
5141
5141
|
kind: g.enum(["feat", "fix", "chore", "docs", "refactor"]).describe("Plan kind matching Conventional Commits types"),
|
|
@@ -5335,7 +5335,7 @@ function qo(n) {
|
|
|
5335
5335
|
function zc(n) {
|
|
5336
5336
|
const e = [], t = [];
|
|
5337
5337
|
for (const s of qo(n)) {
|
|
5338
|
-
const i =
|
|
5338
|
+
const i = $o.safeParse(s.fields);
|
|
5339
5339
|
if (!i.success) {
|
|
5340
5340
|
t.push({
|
|
5341
5341
|
title: s.title,
|
|
@@ -5450,7 +5450,7 @@ function Qc(n) {
|
|
|
5450
5450
|
data: t,
|
|
5451
5451
|
body: s,
|
|
5452
5452
|
warnings: i
|
|
5453
|
-
} = un(n,
|
|
5453
|
+
} = un(n, Ao);
|
|
5454
5454
|
if (e.push(...i), !t)
|
|
5455
5455
|
return { entries: [], warnings: e };
|
|
5456
5456
|
const { body: r, phases: o, log: a, clarifications: c, notes: l, review: f } = ln(s);
|
|
@@ -5595,19 +5595,19 @@ async function Ws(n) {
|
|
|
5595
5595
|
}
|
|
5596
5596
|
}
|
|
5597
5597
|
async function zo(n) {
|
|
5598
|
-
const e = await Ws(
|
|
5598
|
+
const e = await Ws($(n, "..", "run-order.md"));
|
|
5599
5599
|
return new Map(Jo(e).map((t, s) => [t.id, s + 1]));
|
|
5600
5600
|
}
|
|
5601
|
-
async function
|
|
5601
|
+
async function $e(n) {
|
|
5602
5602
|
const e = [], t = [];
|
|
5603
5603
|
let s = 0;
|
|
5604
5604
|
const i = await zo(n);
|
|
5605
|
-
for (const r of [n,
|
|
5605
|
+
for (const r of [n, $(n, "archive")]) {
|
|
5606
5606
|
const o = r !== n, a = (await Wo(r)).filter((l) => l.endsWith(".md") && l !== "index.md");
|
|
5607
5607
|
s += a.length;
|
|
5608
5608
|
const c = await Promise.all(
|
|
5609
5609
|
a.map(async (l) => {
|
|
5610
|
-
const f = await Ws(
|
|
5610
|
+
const f = await Ws($(r, l));
|
|
5611
5611
|
return f ? Vs(f) : { warnings: [{ title: l, message: "Could not read entity file" }] };
|
|
5612
5612
|
})
|
|
5613
5613
|
);
|
|
@@ -5624,7 +5624,7 @@ async function Ae(n) {
|
|
|
5624
5624
|
return { entries: e, warnings: t, fileCount: s };
|
|
5625
5625
|
}
|
|
5626
5626
|
async function fn(n, e) {
|
|
5627
|
-
const { entries: t, warnings: s } = await
|
|
5627
|
+
const { entries: t, warnings: s } = await $e(n), i = $(n, "..", ".."), [r, o] = await Promise.all([
|
|
5628
5628
|
ts(i, e),
|
|
5629
5629
|
Vn(i)
|
|
5630
5630
|
]);
|
|
@@ -5664,7 +5664,7 @@ async function rl(n) {
|
|
|
5664
5664
|
};
|
|
5665
5665
|
}
|
|
5666
5666
|
async function ol(n) {
|
|
5667
|
-
const { entries: e, warnings: t } = await
|
|
5667
|
+
const { entries: e, warnings: t } = await $e(n);
|
|
5668
5668
|
return {
|
|
5669
5669
|
entries: e.filter((s) => s.kind === "note").map(Ui),
|
|
5670
5670
|
warnings: t
|
|
@@ -6047,13 +6047,13 @@ async function Ia(n) {
|
|
|
6047
6047
|
return null;
|
|
6048
6048
|
}
|
|
6049
6049
|
}
|
|
6050
|
-
async function
|
|
6051
|
-
const e =
|
|
6050
|
+
async function $a(n) {
|
|
6051
|
+
const e = $(n, "ideas"), t = [], s = [
|
|
6052
6052
|
{ dir: e, archived: !1, names: await ct(e) },
|
|
6053
6053
|
{
|
|
6054
|
-
dir:
|
|
6054
|
+
dir: $(e, "archive"),
|
|
6055
6055
|
archived: !0,
|
|
6056
|
-
names: await va(
|
|
6056
|
+
names: await va($(e, "archive"))
|
|
6057
6057
|
}
|
|
6058
6058
|
];
|
|
6059
6059
|
for (const { dir: i, archived: r, names: o } of s) {
|
|
@@ -6062,17 +6062,17 @@ async function Aa(n) {
|
|
|
6062
6062
|
t.push({
|
|
6063
6063
|
id: Si(c, ".md"),
|
|
6064
6064
|
path: `papercamp/ideas${r ? "/archive" : ""}/${c}`,
|
|
6065
|
-
content: await q(
|
|
6065
|
+
content: await q($(i, c), "utf-8"),
|
|
6066
6066
|
archived: r
|
|
6067
6067
|
});
|
|
6068
6068
|
}
|
|
6069
|
-
return { files: t, config: await Ia(
|
|
6069
|
+
return { files: t, config: await Ia($(n, "config.json")) };
|
|
6070
6070
|
}
|
|
6071
|
-
function
|
|
6071
|
+
function Aa(n) {
|
|
6072
6072
|
return Na.flatMap((e) => e(n));
|
|
6073
6073
|
}
|
|
6074
6074
|
async function fl(n) {
|
|
6075
|
-
return
|
|
6075
|
+
return Aa(await $a(n));
|
|
6076
6076
|
}
|
|
6077
6077
|
const Ta = {
|
|
6078
6078
|
rule: "archive-placement",
|
|
@@ -6150,7 +6150,7 @@ async function ja(n, e) {
|
|
|
6150
6150
|
if (!xi.test(e)) return null;
|
|
6151
6151
|
const t = await ke(n, ["log", "-1", "--format=%B", e]), s = t ? Ot(t) : null;
|
|
6152
6152
|
if (s) return s;
|
|
6153
|
-
const i = await rt(
|
|
6153
|
+
const i = await rt($(n, "CHANGELOG.md")), r = Ra(i, e);
|
|
6154
6154
|
return r ? Ot(r) : null;
|
|
6155
6155
|
}
|
|
6156
6156
|
async function Ba(n, e) {
|
|
@@ -6165,10 +6165,10 @@ async function Ba(n, e) {
|
|
|
6165
6165
|
}
|
|
6166
6166
|
async function hl(n, e) {
|
|
6167
6167
|
const [{ entries: t }, s, i, r, o, a] = await Promise.all([
|
|
6168
|
-
|
|
6168
|
+
$e($(n, "papercamp", "ideas")),
|
|
6169
6169
|
ts(n),
|
|
6170
|
-
rt(
|
|
6171
|
-
rt(
|
|
6170
|
+
rt($(n, "papercamp", "tasks.log")),
|
|
6171
|
+
rt($(n, "CHANGELOG.md")),
|
|
6172
6172
|
Da(n, e),
|
|
6173
6173
|
Vn(n)
|
|
6174
6174
|
]), c = t.find((h) => h.id === e), l = s == null ? void 0 : s.get(e), f = Vo(i).filter((h) => h.planId === e), u = ii(r, e);
|
|
@@ -6458,8 +6458,8 @@ function bl(n, e, t = Va) {
|
|
|
6458
6458
|
});
|
|
6459
6459
|
}
|
|
6460
6460
|
async function Ja(n, e) {
|
|
6461
|
-
for (const t of ["ideas",
|
|
6462
|
-
const s =
|
|
6461
|
+
for (const t of ["ideas", $("ideas", "archive")]) {
|
|
6462
|
+
const s = $(n, "papercamp", t, `${e}.md`);
|
|
6463
6463
|
try {
|
|
6464
6464
|
return await wi(s), s;
|
|
6465
6465
|
} catch {
|
|
@@ -6651,7 +6651,7 @@ function rc(n, e) {
|
|
|
6651
6651
|
}), s.on("close", (r) => t(r === 0)), s.on("error", () => t(!1));
|
|
6652
6652
|
});
|
|
6653
6653
|
}
|
|
6654
|
-
async function
|
|
6654
|
+
async function $l(n, e) {
|
|
6655
6655
|
const t = await ce(n, e);
|
|
6656
6656
|
if (!(t != null && t.view)) return "unresolved";
|
|
6657
6657
|
const { view: s, entry: i } = t;
|
|
@@ -6702,13 +6702,13 @@ function lc(n, e, t, s, i) {
|
|
|
6702
6702
|
}), o.on("close", (l) => r(l === 0)), o.on("error", () => r(!1)), (c = o.stdin) == null || c.end(i);
|
|
6703
6703
|
});
|
|
6704
6704
|
}
|
|
6705
|
-
async function
|
|
6705
|
+
async function Al(n, e) {
|
|
6706
6706
|
var y, d;
|
|
6707
6707
|
const t = await ce(n, e);
|
|
6708
6708
|
if (!((y = t == null ? void 0 : t.view) != null && y.url)) return "unresolved";
|
|
6709
6709
|
const { view: s, entry: i } = t, [{ entries: r }, o] = await Promise.all([
|
|
6710
|
-
|
|
6711
|
-
q(
|
|
6710
|
+
$e($(n, "papercamp", "ideas")),
|
|
6711
|
+
q($(n, "ROADMAP.md"), "utf-8").catch(() => "")
|
|
6712
6712
|
]), a = r.filter((m) => m.kind !== "note").map((m) => Gn(m)), c = o ? xa(Ua(o)) : [], l = Yo(a, c), f = i.audited && i.auditedHash ? {
|
|
6713
6713
|
audited: i.audited,
|
|
6714
6714
|
stale: Ga(i) !== i.auditedHash
|
|
@@ -6733,13 +6733,14 @@ function kt(n, e) {
|
|
|
6733
6733
|
function pi() {
|
|
6734
6734
|
return (/* @__PURE__ */ new Date()).toISOString().slice(0, 10);
|
|
6735
6735
|
}
|
|
6736
|
-
function Ol(n, e = "log") {
|
|
6736
|
+
function Ol(n, e = "log", t) {
|
|
6737
6737
|
return {
|
|
6738
6738
|
kind: e,
|
|
6739
6739
|
date: pi(),
|
|
6740
6740
|
text: n,
|
|
6741
6741
|
from: "agent",
|
|
6742
|
-
...e === "question" ? { state: "open" } : {}
|
|
6742
|
+
...e === "question" ? { state: "open" } : {},
|
|
6743
|
+
...t ? { entityId: t } : {}
|
|
6743
6744
|
};
|
|
6744
6745
|
}
|
|
6745
6746
|
function uc(n) {
|
|
@@ -6833,10 +6834,10 @@ function Rl(n, e) {
|
|
|
6833
6834
|
let at = Promise.resolve();
|
|
6834
6835
|
async function dc(n, e) {
|
|
6835
6836
|
const t = new RegExp(`^${e.toUpperCase()}-(\\d+)\\.md$`), s = [
|
|
6836
|
-
|
|
6837
|
-
|
|
6838
|
-
|
|
6839
|
-
|
|
6837
|
+
$(n, "ideas"),
|
|
6838
|
+
$(n, "ideas", "archive"),
|
|
6839
|
+
$(n, "plans"),
|
|
6840
|
+
$(n, "plans", "archive")
|
|
6840
6841
|
];
|
|
6841
6842
|
let i = 0;
|
|
6842
6843
|
for (const r of s) {
|
|
@@ -6891,7 +6892,7 @@ async function Dl(n, e) {
|
|
|
6891
6892
|
}), t;
|
|
6892
6893
|
}
|
|
6893
6894
|
async function jl(n, e) {
|
|
6894
|
-
const t =
|
|
6895
|
+
const t = $(n, "papercamp", "ideas"), s = $(t, "archive"), i = $(t, `${e}.md`), r = $(s, `${e}.md`);
|
|
6895
6896
|
await oe(s, { recursive: !0 });
|
|
6896
6897
|
try {
|
|
6897
6898
|
return await bi(i, r), !0;
|
|
@@ -6986,11 +6987,11 @@ than inventing a new shape).
|
|
|
6986
6987
|
`, gc = 5;
|
|
6987
6988
|
function yc() {
|
|
6988
6989
|
try {
|
|
6989
|
-
let n = Xe(
|
|
6990
|
+
let n = Xe(Ai(import.meta.url));
|
|
6990
6991
|
for (let e = 0; e < gc; e++) {
|
|
6991
|
-
const t =
|
|
6992
|
+
const t = $(n, "package.json");
|
|
6992
6993
|
if (Ii(t))
|
|
6993
|
-
return JSON.parse(
|
|
6994
|
+
return JSON.parse($i(t, "utf-8")).version ?? "0.0.0";
|
|
6994
6995
|
n = Xe(n);
|
|
6995
6996
|
}
|
|
6996
6997
|
return "0.0.0";
|
|
@@ -7013,7 +7014,7 @@ async function ge(n) {
|
|
|
7013
7014
|
}
|
|
7014
7015
|
const bc = ["suggestions.md"];
|
|
7015
7016
|
async function Fl(n, e) {
|
|
7016
|
-
const t =
|
|
7017
|
+
const t = $(n, "papercamp"), s = $(t, "config.json");
|
|
7017
7018
|
if (await ge(s))
|
|
7018
7019
|
throw new wc(n);
|
|
7019
7020
|
const i = {
|
|
@@ -7023,11 +7024,11 @@ async function Fl(n, e) {
|
|
|
7023
7024
|
nextId: { idea: 2 }
|
|
7024
7025
|
};
|
|
7025
7026
|
jo.parse(i), await oe(t, { recursive: !0 });
|
|
7026
|
-
const r =
|
|
7027
|
+
const r = $(t, "ideas");
|
|
7027
7028
|
await oe(r, { recursive: !0 });
|
|
7028
|
-
const o =
|
|
7029
|
+
const o = $(r, "archive");
|
|
7029
7030
|
await oe(o, { recursive: !0 });
|
|
7030
|
-
const a =
|
|
7031
|
+
const a = $(r, "IDEA-1.md");
|
|
7031
7032
|
if (!await ge(a)) {
|
|
7032
7033
|
const c = fc({
|
|
7033
7034
|
id: "IDEA-1",
|
|
@@ -7042,7 +7043,7 @@ Use the New idea button to capture what you're building next, or ask an agent fo
|
|
|
7042
7043
|
`, "utf-8");
|
|
7043
7044
|
}
|
|
7044
7045
|
for (const c of bc) {
|
|
7045
|
-
const l =
|
|
7046
|
+
const l = $(t, c);
|
|
7046
7047
|
await ge(l) || await B(l, "", "utf-8");
|
|
7047
7048
|
}
|
|
7048
7049
|
await B(s, `${JSON.stringify(i, null, 2)}
|
|
@@ -7054,7 +7055,7 @@ async function kc(n, e) {
|
|
|
7054
7055
|
}
|
|
7055
7056
|
const Tt = "papercamp/.pairing.json";
|
|
7056
7057
|
async function Sc(n) {
|
|
7057
|
-
const e =
|
|
7058
|
+
const e = $(n, ".gitignore"), t = await ge(e) ? await q(e, "utf-8") : "", s = t.length > 0 ? t.split(`
|
|
7058
7059
|
`) : [];
|
|
7059
7060
|
if (s.some((r) => r.trim() === Tt)) return;
|
|
7060
7061
|
const i = s.reduce(
|
|
@@ -7073,13 +7074,13 @@ async function Sc(n) {
|
|
|
7073
7074
|
`), "utf-8");
|
|
7074
7075
|
}
|
|
7075
7076
|
async function Ec(n) {
|
|
7076
|
-
const e =
|
|
7077
|
+
const e = $(n, ".claude", "skills", "paper-camp");
|
|
7077
7078
|
await oe(e, { recursive: !0 });
|
|
7078
|
-
const t =
|
|
7079
|
+
const t = $(e, "SKILL.md");
|
|
7079
7080
|
await ge(t) || await B(t, hc, "utf-8");
|
|
7080
|
-
const s =
|
|
7081
|
+
const s = $(n, ".claude");
|
|
7081
7082
|
await oe(s, { recursive: !0 });
|
|
7082
|
-
const i =
|
|
7083
|
+
const i = $(s, "settings.json");
|
|
7083
7084
|
await ge(i) || await B(i, mc, "utf-8");
|
|
7084
7085
|
}
|
|
7085
7086
|
const gi = {
|
|
@@ -7090,10 +7091,10 @@ const gi = {
|
|
|
7090
7091
|
chore: "Miscellaneous"
|
|
7091
7092
|
}, Nc = Array.from(new Set(Object.values(gi)));
|
|
7092
7093
|
async function Kl(n, e) {
|
|
7093
|
-
const t = await rt(
|
|
7094
|
+
const t = await rt($(n, "CHANGELOG.md")), s = La(t).find((a) => a.version === e);
|
|
7094
7095
|
if (!s) return null;
|
|
7095
7096
|
const [{ entries: i }, r] = await Promise.all([
|
|
7096
|
-
|
|
7097
|
+
$e($(n, "papercamp", "ideas")),
|
|
7097
7098
|
Ba(n, s.range)
|
|
7098
7099
|
]), o = /* @__PURE__ */ new Map();
|
|
7099
7100
|
for (const a of r.keys()) {
|
|
@@ -7121,7 +7122,7 @@ function vc(n) {
|
|
|
7121
7122
|
return Math.floor((Date.now() - Date.parse(n)) / 864e5);
|
|
7122
7123
|
}
|
|
7123
7124
|
const Ic = (n, e) => n === "question" && (e ?? "open") === "open";
|
|
7124
|
-
function
|
|
7125
|
+
function $c(n) {
|
|
7125
7126
|
return n.flatMap(
|
|
7126
7127
|
(e) => (e.thread ?? []).filter((t) => Ic(t.kind, t.state)).map((t) => ({
|
|
7127
7128
|
entityId: e.id,
|
|
@@ -7133,8 +7134,8 @@ function Ac(n) {
|
|
|
7133
7134
|
).sort((e, t) => t.ageDays - e.ageDays);
|
|
7134
7135
|
}
|
|
7135
7136
|
async function Ul(n) {
|
|
7136
|
-
const { entries: e } = await
|
|
7137
|
-
return
|
|
7137
|
+
const { entries: e } = await $e(n);
|
|
7138
|
+
return $c(e);
|
|
7138
7139
|
}
|
|
7139
7140
|
const jt = 0.95, yi = 3e4, Bt = {
|
|
7140
7141
|
implement: { from: 0, to: 0.6 },
|
|
@@ -7166,7 +7167,7 @@ function Hl(n, e) {
|
|
|
7166
7167
|
function Gl(n, e) {
|
|
7167
7168
|
return n === void 0 ? !1 : e - n >= yi;
|
|
7168
7169
|
}
|
|
7169
|
-
function
|
|
7170
|
+
function Ac(n) {
|
|
7170
7171
|
const e = [...n].sort((s, i) => s - i), t = Math.floor(e.length / 2);
|
|
7171
7172
|
return e.length % 2 === 0 ? (e[t - 1] + e[t]) / 2 : e[t];
|
|
7172
7173
|
}
|
|
@@ -7175,7 +7176,7 @@ function Yl(n) {
|
|
|
7175
7176
|
(i) => (i.endedAt ? Date.parse(i.endedAt) : Number.NaN) - Date.parse(i.startedAt)
|
|
7176
7177
|
).filter((i) => Number.isFinite(i) && i > 0);
|
|
7177
7178
|
if (e.length === 0) return {};
|
|
7178
|
-
const t =
|
|
7179
|
+
const t = Ac(e), s = {};
|
|
7179
7180
|
for (const i of ["implement", "verify"]) {
|
|
7180
7181
|
const r = Bt[i].to - Bt[i].from;
|
|
7181
7182
|
s[i] = t * r / jt;
|
|
@@ -7257,13 +7258,13 @@ export {
|
|
|
7257
7258
|
Hc as aR,
|
|
7258
7259
|
wl as aS,
|
|
7259
7260
|
fl as aT,
|
|
7260
|
-
|
|
7261
|
+
Aa as aU,
|
|
7261
7262
|
Qi as aV,
|
|
7262
7263
|
yn as aW,
|
|
7263
7264
|
zs as aX,
|
|
7264
7265
|
Il as aY,
|
|
7265
7266
|
Bo as aZ,
|
|
7266
|
-
|
|
7267
|
+
Al as a_,
|
|
7267
7268
|
yl as aa,
|
|
7268
7269
|
Yl as ab,
|
|
7269
7270
|
Do as ac,
|
|
@@ -7283,30 +7284,32 @@ export {
|
|
|
7283
7284
|
tl as aq,
|
|
7284
7285
|
Vl as ar,
|
|
7285
7286
|
dl as as,
|
|
7286
|
-
|
|
7287
|
-
|
|
7288
|
-
|
|
7287
|
+
$o as at,
|
|
7288
|
+
Ao as au,
|
|
7289
|
+
$e as av,
|
|
7289
7290
|
sl as aw,
|
|
7290
7291
|
rt as ax,
|
|
7291
7292
|
ol as ay,
|
|
7292
7293
|
Ul as az,
|
|
7293
7294
|
xi as b,
|
|
7294
7295
|
El as b0,
|
|
7295
|
-
|
|
7296
|
+
$l as b1,
|
|
7296
7297
|
Nl as b2,
|
|
7297
7298
|
pi as b3,
|
|
7298
7299
|
vl as b4,
|
|
7299
|
-
|
|
7300
|
-
|
|
7301
|
-
|
|
7302
|
-
|
|
7303
|
-
|
|
7304
|
-
|
|
7305
|
-
|
|
7306
|
-
|
|
7307
|
-
|
|
7308
|
-
|
|
7309
|
-
|
|
7300
|
+
Hs as b5,
|
|
7301
|
+
ll as b6,
|
|
7302
|
+
Jo as b7,
|
|
7303
|
+
nl as b8,
|
|
7304
|
+
Fc as b9,
|
|
7305
|
+
qc as ba,
|
|
7306
|
+
Hn as bb,
|
|
7307
|
+
ke as bc,
|
|
7308
|
+
wt as bd,
|
|
7309
|
+
Uc as be,
|
|
7310
|
+
Kc as bf,
|
|
7311
|
+
Bi as bg,
|
|
7312
|
+
ul as bh,
|
|
7310
7313
|
Oa as c,
|
|
7311
7314
|
Qo as d,
|
|
7312
7315
|
Xo as e,
|
|
@@ -7326,10 +7329,10 @@ export {
|
|
|
7326
7329
|
Tl as s,
|
|
7327
7330
|
xl as t,
|
|
7328
7331
|
Wc as u,
|
|
7329
|
-
|
|
7330
|
-
|
|
7332
|
+
$a as v,
|
|
7333
|
+
$c as w,
|
|
7331
7334
|
Ga as x,
|
|
7332
7335
|
di as y,
|
|
7333
7336
|
Yc as z
|
|
7334
7337
|
};
|
|
7335
|
-
//# sourceMappingURL=phase-progress.
|
|
7338
|
+
//# sourceMappingURL=phase-progress.Cos0IBFk.js.map
|