intentdocs 0.8.0 → 0.10.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -1
- package/bin/intentdocs.js +2 -0
- package/dist/chunk-34JCN66H.js +170 -0
- package/dist/chunk-6X4BORMW.js +317 -0
- package/dist/{chunk-6FGYJ3W2.js → chunk-F52HPVNQ.js} +43 -4
- package/dist/{chunk-ICOMMHKG.js → chunk-JX2RLGOM.js} +13 -2
- package/dist/chunk-KPQ42YE6.js +43 -0
- package/dist/chunk-LQTPZL2Y.js +15 -0
- package/dist/{chunk-4OWPN2RE.js → chunk-NHNBCNND.js} +28 -47
- package/dist/{chunk-IKF3ZLHK.js → chunk-PUGYRSMK.js} +72 -108
- package/dist/{chunk-ITQUQYWB.js → chunk-UQDMUKLP.js} +2 -2
- package/dist/chunk-UYTVTYNB.js +11 -0
- package/dist/{chunk-WPVDURTJ.js → chunk-WRRUCCVZ.js} +27 -3
- package/dist/chunk-XZE2XP6O.js +105 -0
- package/dist/ci-XCOXFTLB.js +11 -0
- package/dist/{complexity-NSSYVT54.js → complexity-X3IJKNNV.js} +12 -7
- package/dist/{import-prd-CKV3R67G.js → import-prd-IJTM6FZE.js} +13 -11
- package/dist/index.js +435 -194
- package/dist/{keys-EDWET3WG.js → keys-UVXCCWCS.js} +8 -7
- package/dist/log-XIH4BGFL.js +206 -0
- package/dist/{map-extract-I3AACTGL.js → map-extract-V6D27I3H.js} +3 -2
- package/dist/{map-import-IYUMRASO.js → map-import-LORTI4K4.js} +12 -10
- package/dist/{map-schema-JVL3O2TJ.js → map-schema-5BEIJM2J.js} +1 -1
- package/dist/projects-AYAYVFKL.js +37 -0
- package/dist/{prompt-WAWCRGHN.js → prompt-GOAFIKBZ.js} +3 -1
- package/dist/{research-6SXJ37TI.js → research-CO3W7PLC.js} +12 -10
- package/dist/scope-ZZLKQEF5.js +11 -0
- package/dist/setup-WSYIG2CR.js +14 -0
- package/package.json +4 -2
- package/dist/chunk-6XKB6RTU.js +0 -123
- package/dist/chunk-PCNDP5SX.js +0 -34
- package/dist/log-TT2UCJP7.js +0 -94
- package/dist/scope-OGKQ472D.js +0 -10
- package/dist/setup-SOI2HQAL.js +0 -11
package/dist/log-TT2UCJP7.js
DELETED
|
@@ -1,94 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
appendNoteToContext,
|
|
3
|
-
storyContextPath
|
|
4
|
-
} from "./chunk-6FGYJ3W2.js";
|
|
5
|
-
import {
|
|
6
|
-
ask,
|
|
7
|
-
closePrompt
|
|
8
|
-
} from "./chunk-WPVDURTJ.js";
|
|
9
|
-
import {
|
|
10
|
-
apiFetch
|
|
11
|
-
} from "./chunk-6XKB6RTU.js";
|
|
12
|
-
import {
|
|
13
|
-
requireConfig
|
|
14
|
-
} from "./chunk-ICOMMHKG.js";
|
|
15
|
-
import "./chunk-PCNDP5SX.js";
|
|
16
|
-
|
|
17
|
-
// src/commands/log.ts
|
|
18
|
-
async function logDecision(title, opts) {
|
|
19
|
-
const config = requireConfig();
|
|
20
|
-
if (!title) {
|
|
21
|
-
title = await ask(" Decision title: ");
|
|
22
|
-
}
|
|
23
|
-
let description = opts?.description;
|
|
24
|
-
if (!description) {
|
|
25
|
-
description = await ask(" Description (what was decided and why): ");
|
|
26
|
-
}
|
|
27
|
-
if (!title?.trim() || !description?.trim()) {
|
|
28
|
-
console.log(" Title and description required.");
|
|
29
|
-
closePrompt();
|
|
30
|
-
return;
|
|
31
|
-
}
|
|
32
|
-
const res = await apiFetch(config, "/decisions", {
|
|
33
|
-
method: "POST",
|
|
34
|
-
headers: { "Content-Type": "application/json" },
|
|
35
|
-
body: JSON.stringify({
|
|
36
|
-
title: title.trim(),
|
|
37
|
-
description: description.trim(),
|
|
38
|
-
category: opts?.category ?? "technical",
|
|
39
|
-
story_id: opts?.story ?? void 0
|
|
40
|
-
})
|
|
41
|
-
});
|
|
42
|
-
if (res.ok) {
|
|
43
|
-
console.log(` \u2713 Decision logged: ${title}`);
|
|
44
|
-
} else {
|
|
45
|
-
console.error(" Failed to log decision.");
|
|
46
|
-
}
|
|
47
|
-
closePrompt();
|
|
48
|
-
}
|
|
49
|
-
async function logNote(storyId, note) {
|
|
50
|
-
const config = requireConfig();
|
|
51
|
-
if (!note) {
|
|
52
|
-
note = await ask(" Note: ");
|
|
53
|
-
}
|
|
54
|
-
if (!note?.trim()) {
|
|
55
|
-
console.log(" Note required.");
|
|
56
|
-
closePrompt();
|
|
57
|
-
return;
|
|
58
|
-
}
|
|
59
|
-
const listRes = await apiFetch(config, "/stories");
|
|
60
|
-
if (!listRes.ok) {
|
|
61
|
-
console.error(" Failed to fetch stories.");
|
|
62
|
-
closePrompt();
|
|
63
|
-
return;
|
|
64
|
-
}
|
|
65
|
-
const data = await listRes.json();
|
|
66
|
-
const match = data.stories.find((s) => s.id.startsWith(storyId));
|
|
67
|
-
if (!match) {
|
|
68
|
-
console.error(` No story found matching "${storyId}"`);
|
|
69
|
-
closePrompt();
|
|
70
|
-
return;
|
|
71
|
-
}
|
|
72
|
-
const res = await apiFetch(config, "/stories", {
|
|
73
|
-
method: "PATCH",
|
|
74
|
-
headers: { "Content-Type": "application/json" },
|
|
75
|
-
body: JSON.stringify({
|
|
76
|
-
stories: [{ id: match.id, notes: note.trim() }]
|
|
77
|
-
})
|
|
78
|
-
});
|
|
79
|
-
if (res.ok) {
|
|
80
|
-
console.log(` \u2713 Note added to: ${match.title.slice(0, 60)}`);
|
|
81
|
-
} else {
|
|
82
|
-
console.error(" Failed to add note.");
|
|
83
|
-
}
|
|
84
|
-
const appended = appendNoteToContext(match.id, note.trim());
|
|
85
|
-
if (appended) {
|
|
86
|
-
const relPath = storyContextPath(match.id).replace(process.cwd() + "/", "");
|
|
87
|
-
console.log(` \u2713 Updated local context: ${relPath}`);
|
|
88
|
-
}
|
|
89
|
-
closePrompt();
|
|
90
|
-
}
|
|
91
|
-
export {
|
|
92
|
-
logDecision,
|
|
93
|
-
logNote
|
|
94
|
-
};
|
package/dist/scope-OGKQ472D.js
DELETED
package/dist/setup-SOI2HQAL.js
DELETED