brainfile 0.21.2 → 0.22.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.
Files changed (233) hide show
  1. package/README.md +1 -1
  2. package/dist/__tests__/helpers/mcp-wire.d.ts +2 -0
  3. package/dist/__tests__/helpers/mcp-wire.d.ts.map +1 -1
  4. package/dist/__tests__/helpers/mcp-wire.js +4 -2
  5. package/dist/__tests__/helpers/mcp-wire.js.map +1 -1
  6. package/dist/chunk-CWUTU5VV.mjs +5585 -0
  7. package/dist/chunk-L4WSDMK3.mjs +1973 -0
  8. package/dist/{chunk-7KU2R7QC.mjs → chunk-XFDTTLSW.mjs} +3230 -4322
  9. package/dist/cli.js +7 -1
  10. package/dist/cli.mjs +8078 -5357
  11. package/dist/commands/add.d.ts +4 -0
  12. package/dist/commands/add.d.ts.map +1 -1
  13. package/dist/commands/add.js +68 -72
  14. package/dist/commands/add.js.map +1 -1
  15. package/dist/commands/boards.d.ts +18 -0
  16. package/dist/commands/boards.d.ts.map +1 -0
  17. package/dist/commands/boards.js +166 -0
  18. package/dist/commands/boards.js.map +1 -0
  19. package/dist/commands/brief.d.ts +17 -11
  20. package/dist/commands/brief.d.ts.map +1 -1
  21. package/dist/commands/brief.js +38 -35
  22. package/dist/commands/brief.js.map +1 -1
  23. package/dist/commands/check.d.ts +47 -0
  24. package/dist/commands/check.d.ts.map +1 -0
  25. package/dist/commands/check.js +134 -0
  26. package/dist/commands/check.js.map +1 -0
  27. package/dist/commands/columns.d.ts +48 -0
  28. package/dist/commands/columns.d.ts.map +1 -0
  29. package/dist/commands/columns.js +132 -0
  30. package/dist/commands/columns.js.map +1 -0
  31. package/dist/commands/complete.js +9 -4
  32. package/dist/commands/complete.js.map +1 -1
  33. package/dist/commands/decide.d.ts +72 -0
  34. package/dist/commands/decide.d.ts.map +1 -0
  35. package/dist/commands/decide.js +264 -0
  36. package/dist/commands/decide.js.map +1 -0
  37. package/dist/commands/hooks.d.ts +5 -1
  38. package/dist/commands/hooks.d.ts.map +1 -1
  39. package/dist/commands/hooks.js +10 -11
  40. package/dist/commands/hooks.js.map +1 -1
  41. package/dist/commands/init.d.ts.map +1 -1
  42. package/dist/commands/init.js +8 -0
  43. package/dist/commands/init.js.map +1 -1
  44. package/dist/commands/lint.d.ts +27 -0
  45. package/dist/commands/lint.d.ts.map +1 -1
  46. package/dist/commands/lint.js +127 -20
  47. package/dist/commands/lint.js.map +1 -1
  48. package/dist/commands/list.d.ts +6 -0
  49. package/dist/commands/list.d.ts.map +1 -1
  50. package/dist/commands/list.js +216 -7
  51. package/dist/commands/list.js.map +1 -1
  52. package/dist/commands/log.d.ts +51 -0
  53. package/dist/commands/log.d.ts.map +1 -1
  54. package/dist/commands/log.js +113 -84
  55. package/dist/commands/log.js.map +1 -1
  56. package/dist/commands/mcp.d.ts +5 -2
  57. package/dist/commands/mcp.d.ts.map +1 -1
  58. package/dist/commands/mcp.js +44 -9
  59. package/dist/commands/mcp.js.map +1 -1
  60. package/dist/commands/memory-index.d.ts +34 -0
  61. package/dist/commands/memory-index.d.ts.map +1 -0
  62. package/dist/commands/memory-index.js +135 -0
  63. package/dist/commands/memory-index.js.map +1 -0
  64. package/dist/commands/merge-driver.d.ts +1 -15
  65. package/dist/commands/merge-driver.d.ts.map +1 -1
  66. package/dist/commands/merge-driver.js +8 -134
  67. package/dist/commands/merge-driver.js.map +1 -1
  68. package/dist/commands/migrate-tracked.d.ts +1 -1
  69. package/dist/commands/migrate-tracked.d.ts.map +1 -1
  70. package/dist/commands/migrate-tracked.js +21 -10
  71. package/dist/commands/migrate-tracked.js.map +1 -1
  72. package/dist/commands/patch.d.ts +23 -4
  73. package/dist/commands/patch.d.ts.map +1 -1
  74. package/dist/commands/patch.js +149 -91
  75. package/dist/commands/patch.js.map +1 -1
  76. package/dist/commands/plan.d.ts.map +1 -1
  77. package/dist/commands/plan.js +11 -5
  78. package/dist/commands/plan.js.map +1 -1
  79. package/dist/commands/schema.d.ts +12 -0
  80. package/dist/commands/schema.d.ts.map +1 -1
  81. package/dist/commands/schema.js +28 -10
  82. package/dist/commands/schema.js.map +1 -1
  83. package/dist/commands/search.d.ts +46 -12
  84. package/dist/commands/search.d.ts.map +1 -1
  85. package/dist/commands/search.js +89 -44
  86. package/dist/commands/search.js.map +1 -1
  87. package/dist/commands/show.d.ts.map +1 -1
  88. package/dist/commands/show.js +175 -10
  89. package/dist/commands/show.js.map +1 -1
  90. package/dist/commands/template.d.ts +2 -0
  91. package/dist/commands/template.d.ts.map +1 -1
  92. package/dist/commands/template.js +2 -1
  93. package/dist/commands/template.js.map +1 -1
  94. package/dist/commands/types.d.ts +31 -1
  95. package/dist/commands/types.d.ts.map +1 -1
  96. package/dist/commands/types.js +122 -22
  97. package/dist/commands/types.js.map +1 -1
  98. package/dist/commands/where.d.ts +20 -1
  99. package/dist/commands/where.d.ts.map +1 -1
  100. package/dist/commands/where.js +56 -6
  101. package/dist/commands/where.js.map +1 -1
  102. package/dist/hook.mjs +15 -0
  103. package/dist/hooks/session-start.d.ts +39 -0
  104. package/dist/hooks/session-start.d.ts.map +1 -0
  105. package/dist/hooks/session-start.js +181 -0
  106. package/dist/hooks/session-start.js.map +1 -0
  107. package/dist/lib/contractRunner.d.ts.map +1 -1
  108. package/dist/lib/contractRunner.js +8 -0
  109. package/dist/lib/contractRunner.js.map +1 -1
  110. package/dist/mcp/helpers.d.ts +29 -1
  111. package/dist/mcp/helpers.d.ts.map +1 -1
  112. package/dist/mcp/helpers.js +57 -2
  113. package/dist/mcp/helpers.js.map +1 -1
  114. package/dist/mcp/instructions.d.ts +5 -0
  115. package/dist/mcp/instructions.d.ts.map +1 -0
  116. package/dist/mcp/instructions.js +57 -0
  117. package/dist/mcp/instructions.js.map +1 -0
  118. package/dist/mcp/resources.d.ts +9 -0
  119. package/dist/mcp/resources.d.ts.map +1 -0
  120. package/dist/mcp/resources.js +29 -0
  121. package/dist/mcp/resources.js.map +1 -0
  122. package/dist/mcp/schemas.d.ts +600 -9
  123. package/dist/mcp/schemas.d.ts.map +1 -1
  124. package/dist/mcp/schemas.js +374 -12
  125. package/dist/mcp/schemas.js.map +1 -1
  126. package/dist/mcp/tools/adr_promote_tool.d.ts +7 -0
  127. package/dist/mcp/tools/adr_promote_tool.d.ts.map +1 -0
  128. package/dist/mcp/tools/adr_promote_tool.js +37 -0
  129. package/dist/mcp/tools/adr_promote_tool.js.map +1 -0
  130. package/dist/mcp/tools/board_tool.d.ts +7 -0
  131. package/dist/mcp/tools/board_tool.d.ts.map +1 -0
  132. package/dist/mcp/tools/board_tool.js +61 -0
  133. package/dist/mcp/tools/board_tool.js.map +1 -0
  134. package/dist/mcp/tools/brief_tool.d.ts.map +1 -1
  135. package/dist/mcp/tools/brief_tool.js +13 -5
  136. package/dist/mcp/tools/brief_tool.js.map +1 -1
  137. package/dist/mcp/tools/check_tool.d.ts +6 -0
  138. package/dist/mcp/tools/check_tool.d.ts.map +1 -0
  139. package/dist/mcp/tools/check_tool.js +54 -0
  140. package/dist/mcp/tools/check_tool.js.map +1 -0
  141. package/dist/mcp/tools/columns_tool.d.ts +7 -0
  142. package/dist/mcp/tools/columns_tool.d.ts.map +1 -0
  143. package/dist/mcp/tools/columns_tool.js +94 -0
  144. package/dist/mcp/tools/columns_tool.js.map +1 -0
  145. package/dist/mcp/tools/decide_tool.d.ts +91 -0
  146. package/dist/mcp/tools/decide_tool.d.ts.map +1 -0
  147. package/dist/mcp/tools/decide_tool.js +141 -0
  148. package/dist/mcp/tools/decide_tool.js.map +1 -0
  149. package/dist/mcp/tools/get_task_tool.d.ts.map +1 -1
  150. package/dist/mcp/tools/get_task_tool.js +62 -4
  151. package/dist/mcp/tools/get_task_tool.js.map +1 -1
  152. package/dist/mcp/tools/lint_tool.d.ts +7 -0
  153. package/dist/mcp/tools/lint_tool.d.ts.map +1 -0
  154. package/dist/mcp/tools/lint_tool.js +48 -0
  155. package/dist/mcp/tools/lint_tool.js.map +1 -0
  156. package/dist/mcp/tools/list_tasks_tool.d.ts.map +1 -1
  157. package/dist/mcp/tools/list_tasks_tool.js +132 -15
  158. package/dist/mcp/tools/list_tasks_tool.js.map +1 -1
  159. package/dist/mcp/tools/log_tool.d.ts +4 -0
  160. package/dist/mcp/tools/log_tool.d.ts.map +1 -0
  161. package/dist/mcp/tools/log_tool.js +52 -0
  162. package/dist/mcp/tools/log_tool.js.map +1 -0
  163. package/dist/mcp/tools/note_tool.d.ts +7 -0
  164. package/dist/mcp/tools/note_tool.d.ts.map +1 -0
  165. package/dist/mcp/tools/note_tool.js +39 -0
  166. package/dist/mcp/tools/note_tool.js.map +1 -0
  167. package/dist/mcp/tools/retire_tool.d.ts +4 -0
  168. package/dist/mcp/tools/retire_tool.d.ts.map +1 -0
  169. package/dist/mcp/tools/retire_tool.js +81 -0
  170. package/dist/mcp/tools/retire_tool.js.map +1 -0
  171. package/dist/mcp/tools/search_tool.d.ts.map +1 -1
  172. package/dist/mcp/tools/search_tool.js +36 -19
  173. package/dist/mcp/tools/search_tool.js.map +1 -1
  174. package/dist/mcp/tools/supersede_tool.d.ts +4 -0
  175. package/dist/mcp/tools/supersede_tool.d.ts.map +1 -0
  176. package/dist/mcp/tools/supersede_tool.js +72 -0
  177. package/dist/mcp/tools/supersede_tool.js.map +1 -0
  178. package/dist/mcp/tools/sync_tool.d.ts +9 -0
  179. package/dist/mcp/tools/sync_tool.d.ts.map +1 -0
  180. package/dist/mcp/tools/sync_tool.js +87 -0
  181. package/dist/mcp/tools/sync_tool.js.map +1 -0
  182. package/dist/mcp/tools/task_add_tool.d.ts.map +1 -1
  183. package/dist/mcp/tools/task_add_tool.js +39 -17
  184. package/dist/mcp/tools/task_add_tool.js.map +1 -1
  185. package/dist/mcp/tools/task_complete_tool.d.ts.map +1 -1
  186. package/dist/mcp/tools/task_complete_tool.js +3 -2
  187. package/dist/mcp/tools/task_complete_tool.js.map +1 -1
  188. package/dist/mcp/tools/task_patch_tool.d.ts.map +1 -1
  189. package/dist/mcp/tools/task_patch_tool.js +30 -5
  190. package/dist/mcp/tools/task_patch_tool.js.map +1 -1
  191. package/dist/mcp/tools/template_tool.d.ts +4 -0
  192. package/dist/mcp/tools/template_tool.d.ts.map +1 -0
  193. package/dist/mcp/tools/template_tool.js +70 -0
  194. package/dist/mcp/tools/template_tool.js.map +1 -0
  195. package/dist/mcp/tools/types_tool.d.ts +4 -0
  196. package/dist/mcp/tools/types_tool.d.ts.map +1 -0
  197. package/dist/mcp/tools/types_tool.js +61 -0
  198. package/dist/mcp/tools/types_tool.js.map +1 -0
  199. package/dist/mcp/tools/where_tool.d.ts +4 -0
  200. package/dist/mcp/tools/where_tool.d.ts.map +1 -0
  201. package/dist/mcp/tools/where_tool.js +73 -0
  202. package/dist/mcp/tools/where_tool.js.map +1 -0
  203. package/dist/schemas/board.json +29 -8
  204. package/dist/{tui-3Z7ZJV7M.mjs → tui-D6RMFL6X.mjs} +994 -315
  205. package/dist/utils/board-autosync.d.ts +1 -10
  206. package/dist/utils/board-autosync.d.ts.map +1 -1
  207. package/dist/utils/board-autosync.js +11 -29
  208. package/dist/utils/board-autosync.js.map +1 -1
  209. package/dist/utils/board-commit-hooks.d.ts +8 -0
  210. package/dist/utils/board-commit-hooks.d.ts.map +1 -1
  211. package/dist/utils/board-commit-hooks.js +45 -1
  212. package/dist/utils/board-commit-hooks.js.map +1 -1
  213. package/dist/utils/board-repo.d.ts +1 -119
  214. package/dist/utils/board-repo.d.ts.map +1 -1
  215. package/dist/utils/board-repo.js +43 -571
  216. package/dist/utils/board-repo.js.map +1 -1
  217. package/dist/utils/board-sync.d.ts +3 -123
  218. package/dist/utils/board-sync.d.ts.map +1 -1
  219. package/dist/utils/board-sync.js +34 -551
  220. package/dist/utils/board-sync.js.map +1 -1
  221. package/dist/utils/graph.d.ts +20 -0
  222. package/dist/utils/graph.d.ts.map +1 -0
  223. package/dist/utils/graph.js +61 -0
  224. package/dist/utils/graph.js.map +1 -0
  225. package/dist/utils/related.d.ts +21 -0
  226. package/dist/utils/related.d.ts.map +1 -0
  227. package/dist/utils/related.js +36 -0
  228. package/dist/utils/related.js.map +1 -0
  229. package/package.json +2 -2
  230. package/dist/tui/theme.d.ts +0 -98
  231. package/dist/tui/theme.d.ts.map +0 -1
  232. package/dist/tui/theme.js +0 -141
  233. package/dist/tui/theme.js.map +0 -1
@@ -0,0 +1,20 @@
1
+ import { readBoardGraph, type BoardGraph, type DocGraph, type LinkChange, type LinkCheckResult, type ResolvedDocType, type TypesConfig } from '@brainfile/core';
2
+ import { type Logger } from './logger';
3
+ export { readBoardGraph, type BoardGraph };
4
+ /** Throw on refusals; print warnings. */
5
+ export declare function applyLinkCheck(result: LinkCheckResult, logger: Logger): void;
6
+ /** Check the links a write would set against the board, refusing or warning as the board's strictness says. */
7
+ export declare function checkLinks(board: BoardGraph, change: LinkChange, logger: Logger): void;
8
+ /** `▸ epic`, `◆ spec`, `task`: a type with its glyph, for prose. */
9
+ export declare function typeWithGlyph(type: ResolvedDocType): string;
10
+ /** Comma-separated IDs, trimmed, empties dropped. */
11
+ export declare function splitIds(value: string | undefined): string[];
12
+ /**
13
+ * The board's documents as a graph, board/ in column order then position,
14
+ * logs/ after, so an outline reads the way the columns do. `onBoard` holds
15
+ * the IDs read from board/.
16
+ */
17
+ export declare function readOrderedGraph(filePath: string, columnOrder: string[], types: TypesConfig | undefined): DocGraph & {
18
+ onBoard: ReadonlySet<string>;
19
+ };
20
+ //# sourceMappingURL=graph.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"graph.d.ts","sourceRoot":"","sources":["../../src/utils/graph.ts"],"names":[],"mappings":"AAKA,OAAO,EAIL,cAAc,EAEd,KAAK,UAAU,EACf,KAAK,QAAQ,EACb,KAAK,UAAU,EACf,KAAK,eAAe,EACpB,KAAK,eAAe,EAEpB,KAAK,WAAW,EACjB,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,UAAU,CAAC;AAEvC,OAAO,EAAE,cAAc,EAAE,KAAK,UAAU,EAAE,CAAC;AAE3C,yCAAyC;AACzC,wBAAgB,cAAc,CAAC,MAAM,EAAE,eAAe,EAAE,MAAM,EAAE,MAAM,GAAG,IAAI,CAQ5E;AAED,+GAA+G;AAC/G,wBAAgB,UAAU,CAAC,KAAK,EAAE,UAAU,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,MAAM,GAAG,IAAI,CAKtF;AAED,oEAAoE;AACpE,wBAAgB,aAAa,CAAC,IAAI,EAAE,eAAe,GAAG,MAAM,CAE3D;AAED,qDAAqD;AACrD,wBAAgB,QAAQ,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,GAAG,MAAM,EAAE,CAG5D;AAED;;;;GAIG;AACH,wBAAgB,gBAAgB,CAC9B,QAAQ,EAAE,MAAM,EAChB,WAAW,EAAE,MAAM,EAAE,EACrB,KAAK,EAAE,WAAW,GAAG,SAAS,GAC7B,QAAQ,GAAG;IAAE,OAAO,EAAE,WAAW,CAAC,MAAM,CAAC,CAAA;CAAE,CAY7C"}
@@ -0,0 +1,61 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.readBoardGraph = void 0;
7
+ exports.applyLinkCheck = applyLinkCheck;
8
+ exports.checkLinks = checkLinks;
9
+ exports.typeWithGlyph = typeWithGlyph;
10
+ exports.splitIds = splitIds;
11
+ exports.readOrderedGraph = readOrderedGraph;
12
+ /**
13
+ * CLI glue for the document graph (spec-12): read a board's graph, and turn a
14
+ * link check into a refusal or warnings.
15
+ */
16
+ const chalk_1 = __importDefault(require("chalk"));
17
+ const core_1 = require("@brainfile/core");
18
+ Object.defineProperty(exports, "readBoardGraph", { enumerable: true, get: function () { return core_1.readBoardGraph; } });
19
+ const cli_error_1 = require("./cli-error");
20
+ /** Throw on refusals; print warnings. */
21
+ function applyLinkCheck(result, logger) {
22
+ if (result.errors.length > 0) {
23
+ const [first, ...rest] = result.errors;
24
+ throw new cli_error_1.CLIError(first, undefined, rest.length > 0 ? rest.join('\n') : undefined);
25
+ }
26
+ for (const warning of result.warnings) {
27
+ logger.warn(chalk_1.default.yellow(`Warning: ${warning}`));
28
+ }
29
+ }
30
+ /** Check the links a write would set against the board, refusing or warning as the board's strictness says. */
31
+ function checkLinks(board, change, logger) {
32
+ applyLinkCheck((0, core_1.checkDocumentLinks)(board.graph, change, { strict: board.config?.strict === true }), logger);
33
+ }
34
+ /** `▸ epic`, `◆ spec`, `task`: a type with its glyph, for prose. */
35
+ function typeWithGlyph(type) {
36
+ return type.glyph ? `${type.glyph} ${type.name}` : type.name;
37
+ }
38
+ /** Comma-separated IDs, trimmed, empties dropped. */
39
+ function splitIds(value) {
40
+ if (!value)
41
+ return [];
42
+ return value.split(',').map((item) => item.trim()).filter(Boolean);
43
+ }
44
+ /**
45
+ * The board's documents as a graph, board/ in column order then position,
46
+ * logs/ after, so an outline reads the way the columns do. `onBoard` holds
47
+ * the IDs read from board/.
48
+ */
49
+ function readOrderedGraph(filePath, columnOrder, types) {
50
+ const dirs = (0, core_1.getV2Dirs)(filePath);
51
+ const rank = (task) => {
52
+ const index = columnOrder.indexOf(task.column ?? '');
53
+ return index === -1 ? columnOrder.length : index;
54
+ };
55
+ const open = (0, core_1.readTasksDir)(dirs.boardDir).map((doc) => doc.task).sort((a, b) => rank(a) - rank(b)
56
+ || (a.position ?? Number.MAX_SAFE_INTEGER) - (b.position ?? Number.MAX_SAFE_INTEGER)
57
+ || a.id.localeCompare(b.id, undefined, { numeric: true }));
58
+ const done = (0, core_1.readTasksDir)(dirs.logsDir).map((doc) => doc.task);
59
+ return Object.assign((0, core_1.buildDocGraph)([...open, ...done], { types }), { onBoard: new Set(open.map((task) => task.id)) });
60
+ }
61
+ //# sourceMappingURL=graph.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"graph.js","sourceRoot":"","sources":["../../src/utils/graph.ts"],"names":[],"mappings":";;;;;;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AAE,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IAC/D,OAAO,MAAM,CAAC,MAAM,CAAC,IAAA,oBAAa,EAAC,CAAC,GAAG,IAAI,EAAE,GAAG,IAAI,CAAC,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,IAAI,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC;AACxH,CAAC"}
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Reading a task on a related board (spec-10) — shared by `show` and the MCP
3
+ * `get_task` tool so both say the same thing when the board is not there.
4
+ */
5
+ import { type RelatedBoard } from '@brainfile/core/repo';
6
+ export type FoundRelatedBoard = Extract<RelatedBoard, {
7
+ status: 'found';
8
+ }>;
9
+ export type RelatedTaskTarget = {
10
+ ok: true;
11
+ board: FoundRelatedBoard;
12
+ id: string;
13
+ } | {
14
+ ok: false;
15
+ kind: 'malformed' | 'unknown-alias' | 'unavailable' | 'not-found';
16
+ message: string;
17
+ details?: string;
18
+ };
19
+ /** Resolve `alias:id` from the board at `brainfilePath` to the board and ID to read. */
20
+ export declare function resolveRelatedTask(brainfilePath: string, ref: string): RelatedTaskTarget;
21
+ //# sourceMappingURL=related.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"related.d.ts","sourceRoot":"","sources":["../../src/utils/related.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,EAAuC,KAAK,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAE9F,MAAM,MAAM,iBAAiB,GAAG,OAAO,CAAC,YAAY,EAAE;IAAE,MAAM,EAAE,OAAO,CAAA;CAAE,CAAC,CAAC;AAE3E,MAAM,MAAM,iBAAiB,GACzB;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,KAAK,EAAE,iBAAiB,CAAC;IAAC,EAAE,EAAE,MAAM,CAAA;CAAE,GAClD;IAAE,EAAE,EAAE,KAAK,CAAC;IAAC,IAAI,EAAE,WAAW,GAAG,eAAe,GAAG,aAAa,GAAG,WAAW,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,OAAO,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC;AAExH,wFAAwF;AACxF,wBAAgB,kBAAkB,CAAC,aAAa,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,iBAAiB,CAyBxF"}
@@ -0,0 +1,36 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.resolveRelatedTask = resolveRelatedTask;
4
+ /**
5
+ * Reading a task on a related board (spec-10) — shared by `show` and the MCP
6
+ * `get_task` tool so both say the same thing when the board is not there.
7
+ */
8
+ const repo_1 = require("@brainfile/core/repo");
9
+ /** Resolve `alias:id` from the board at `brainfilePath` to the board and ID to read. */
10
+ function resolveRelatedTask(brainfilePath, ref) {
11
+ const hit = (0, repo_1.relatedBoards)(brainfilePath).lookup(ref);
12
+ switch (hit.state) {
13
+ case 'malformed':
14
+ return { ok: false, kind: 'malformed', message: `${ref} is not a task reference; use alias:task-id` };
15
+ case 'unknown-alias':
16
+ return {
17
+ ok: false,
18
+ kind: 'unknown-alias',
19
+ message: `No related board named '${hit.alias}'`,
20
+ details: `Name it under related: in brainfile.md, e.g.\n related:\n ${hit.alias}: ../folder`,
21
+ };
22
+ case 'missing':
23
+ case 'no-board':
24
+ return {
25
+ ok: false,
26
+ kind: 'unavailable',
27
+ message: (0, repo_1.describeRelatedBoard)(hit.board),
28
+ details: `Looked in ${hit.board.folder}`,
29
+ };
30
+ case 'not-found':
31
+ return { ok: false, kind: 'not-found', message: `Task not found: ${ref}` };
32
+ default:
33
+ return { ok: true, board: hit.board, id: hit.id };
34
+ }
35
+ }
36
+ //# sourceMappingURL=related.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"related.js","sourceRoot":"","sources":["../../src/utils/related.ts"],"names":[],"mappings":";;AAaA,gDAyBC;AAtCD;;;GAGG;AACH,+CAA8F;AAQ9F,wFAAwF;AACxF,SAAgB,kBAAkB,CAAC,aAAqB,EAAE,GAAW;IACnE,MAAM,GAAG,GAAG,IAAA,oBAAa,EAAC,aAAa,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;IACrD,QAAQ,GAAG,CAAC,KAAK,EAAE,CAAC;QAClB,KAAK,WAAW;YACd,OAAO,EAAE,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,WAAW,EAAE,OAAO,EAAE,GAAG,GAAG,6CAA6C,EAAE,CAAC;QACxG,KAAK,eAAe;YAClB,OAAO;gBACL,EAAE,EAAE,KAAK;gBACT,IAAI,EAAE,eAAe;gBACrB,OAAO,EAAE,2BAA2B,GAAG,CAAC,KAAK,GAAG;gBAChD,OAAO,EAAE,iEAAiE,GAAG,CAAC,KAAK,aAAa;aACjG,CAAC;QACJ,KAAK,SAAS,CAAC;QACf,KAAK,UAAU;YACb,OAAO;gBACL,EAAE,EAAE,KAAK;gBACT,IAAI,EAAE,aAAa;gBACnB,OAAO,EAAE,IAAA,2BAAoB,EAAC,GAAG,CAAC,KAAM,CAAC;gBACzC,OAAO,EAAE,aAAa,GAAG,CAAC,KAAM,CAAC,MAAM,EAAE;aAC1C,CAAC;QACJ,KAAK,WAAW;YACd,OAAO,EAAE,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,WAAW,EAAE,OAAO,EAAE,mBAAmB,GAAG,EAAE,EAAE,CAAC;QAC7E;YACE,OAAO,EAAE,EAAE,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,CAAC,KAA0B,EAAE,EAAE,EAAE,GAAG,CAAC,EAAE,EAAE,CAAC;IAC3E,CAAC;AACH,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "brainfile",
3
- "version": "0.21.2",
3
+ "version": "0.22.1",
4
4
  "description": "Command-line interface for Brainfile task management",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -37,7 +37,7 @@
37
37
  "access": "public"
38
38
  },
39
39
  "dependencies": {
40
- "@brainfile/core": "^0.21.2",
40
+ "@brainfile/core": "^0.22.1",
41
41
  "chalk": "^4.1.2",
42
42
  "chokidar": "^4.0.3",
43
43
  "commander": "^14.0.3",
@@ -1,98 +0,0 @@
1
- /**
2
- * Brainfile TUI v3 design system.
3
- *
4
- * Two rules drive everything here:
5
- *
6
- * 1. **Colour is signal only.** Priority, contract state and selection get
7
- * colour; nothing else does. IDs and metadata are dim, titles are default
8
- * foreground. There are no decorative accents and no theme colours for
9
- * "chrome", because v3 has no chrome.
10
- * 2. **Structure comes from typography.** A document's kind is a single glyph
11
- * in column 1; hierarchy is two spaces of indent; separation is whitespace.
12
- * The only box-drawing character that survives is the horizontal rule used
13
- * for the header and footer boundaries.
14
- */
15
- declare const RAW_PALETTE: {
16
- readonly text: "#ffffff";
17
- readonly textSecondary: "#a0a0a0";
18
- readonly textMuted: "#606060";
19
- readonly textDim: "#404040";
20
- readonly critical: "#ef4444";
21
- readonly high: "#f59e0b";
22
- readonly medium: "#3b82f6";
23
- readonly low: "#6b7280";
24
- readonly contractDraft: "#606060";
25
- readonly contractReady: "#06b6d4";
26
- readonly contractInProgress: "#eab308";
27
- readonly contractDelivered: "#c026d3";
28
- readonly contractDone: "#22c55e";
29
- readonly contractFailed: "#ef4444";
30
- readonly success: "#22c55e";
31
- readonly warning: "#eab308";
32
- readonly error: "#ef4444";
33
- readonly info: "#3b82f6";
34
- readonly accent: "#7c3aed";
35
- };
36
- /**
37
- * `NO_COLOR` (https://no-color.org): any non-empty value disables colour. The
38
- * empty string is falsy in JS, which happens to be exactly the spec's rule.
39
- *
40
- * Gating happens HERE, at the prop layer, rather than by forcing `chalk.level`
41
- * to 0 globally. Ink still applies `inverse` through `chalk.inverse`, and chalk
42
- * level 0 (NO_COLOR / FORCE_COLOR=0) is a no-op — so selection also puts a
43
- * cursor glyph in column 1 of `DocumentRow`. The palette gate keeps colour
44
- * props `undefined`; the glyph is what a no-colour terminal can actually see.
45
- *
46
- * The Proxy means all ~107 `PALETTE.x` call sites need no change, and the check
47
- * is a plain runtime read at module init, so it survives the esbuild bundle
48
- * without depending on import order the way a `FORCE_COLOR` shim would.
49
- */
50
- export declare function isNoColor(env?: NodeJS.ProcessEnv): boolean;
51
- /**
52
- * The palette the views see. Exported as a factory so the gate is testable
53
- * without module-cache gymnastics — `PALETTE` itself is the one-shot
54
- * application of it to the real environment.
55
- */
56
- export declare function makePalette(noColor: boolean): typeof RAW_PALETTE;
57
- export declare const NO_COLOR: boolean;
58
- export declare const PALETTE: typeof RAW_PALETTE;
59
- /** The only box-drawing character v3 uses: header and footer rules. */
60
- export declare const RULE = "\u2500";
61
- /**
62
- * Document-type glyphs (column 1). A plain task deliberately renders *no*
63
- * glyph — the blank column is what makes typed documents stand out.
64
- */
65
- export declare const TYPE_GLYPHS: Record<string, string>;
66
- export declare function getTypeGlyph(type?: string): string;
67
- /**
68
- * Plain (non-emoji) glyphs used by the chrome-free views. The v2 emoji set
69
- * (📄 📁 🔍 📦 📋 🗑 …) is gone: emoji have unreliable terminal widths and
70
- * broke column alignment, which is the whole point of the v3 list.
71
- */
72
- export declare const GLYPHS: {
73
- readonly pointer: "▸";
74
- readonly cursor: "▌";
75
- readonly collapsed: "▶";
76
- readonly success: "✓";
77
- readonly error: "✗";
78
- readonly warning: "⚠";
79
- readonly live: "●";
80
- readonly subtaskOpen: "◻";
81
- readonly subtaskDone: "☑";
82
- readonly orphanParent: "←";
83
- /** Board-list row glyph for a parent-with-children that is expanded (§A1). */
84
- readonly parentExpanded: "▾";
85
- /** Board-list row glyph for a parent-with-children that is collapsed (§A1). */
86
- readonly parentCollapsed: "▸";
87
- /** Detail body scroll indicator (§B2), e.g. `↕ 2/9`. */
88
- readonly scroll: "↕";
89
- };
90
- export type ContractState = 'draft' | 'ready' | 'in_progress' | 'delivered' | 'done' | 'failed' | 'blocked';
91
- /**
92
- * Contract state → colour. Unlike v2 (which had two divergent, both-incomplete
93
- * switch statements in TaskCard and TaskDetail) this is the single mapping, and
94
- * it covers all six states the schema can produce.
95
- */
96
- export declare function getContractStateColor(state?: string): string;
97
- export {};
98
- //# sourceMappingURL=theme.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../src/tui/theme.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;CA6BP,CAAC;AAEX;;;;;;;;;;;;;GAaG;AACH,wBAAgB,SAAS,CAAC,GAAG,GAAE,MAAM,CAAC,UAAwB,GAAG,OAAO,CAEvE;AAED;;;;GAIG;AACH,wBAAgB,WAAW,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,WAAW,CAGhE;AAED,eAAO,MAAM,QAAQ,SAAc,CAAC;AAEpC,eAAO,MAAM,OAAO,EAAE,OAAO,WAAmC,CAAC;AAEjE,uEAAuE;AACvE,eAAO,MAAM,IAAI,WAAM,CAAC;AAExB;;;GAGG;AACH,eAAO,MAAM,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAM9C,CAAC;AAEF,wBAAgB,YAAY,CAAC,IAAI,CAAC,EAAE,MAAM,GAAG,MAAM,CAGlD;AAED;;;;GAIG;AACH,eAAO,MAAM,MAAM;;;;;;;;;;;IAWjB,8EAA8E;;IAE9E,+EAA+E;;IAE/E,wDAAwD;;CAEhD,CAAC;AAEX,MAAM,MAAM,aAAa,GACrB,OAAO,GACP,OAAO,GACP,aAAa,GACb,WAAW,GACX,MAAM,GACN,QAAQ,GACR,SAAS,CAAC;AAEd;;;;GAIG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAiB5D"}
package/dist/tui/theme.js DELETED
@@ -1,141 +0,0 @@
1
- "use strict";
2
- /**
3
- * Brainfile TUI v3 design system.
4
- *
5
- * Two rules drive everything here:
6
- *
7
- * 1. **Colour is signal only.** Priority, contract state and selection get
8
- * colour; nothing else does. IDs and metadata are dim, titles are default
9
- * foreground. There are no decorative accents and no theme colours for
10
- * "chrome", because v3 has no chrome.
11
- * 2. **Structure comes from typography.** A document's kind is a single glyph
12
- * in column 1; hierarchy is two spaces of indent; separation is whitespace.
13
- * The only box-drawing character that survives is the horizontal rule used
14
- * for the header and footer boundaries.
15
- */
16
- Object.defineProperty(exports, "__esModule", { value: true });
17
- exports.GLYPHS = exports.TYPE_GLYPHS = exports.RULE = exports.PALETTE = exports.NO_COLOR = void 0;
18
- exports.isNoColor = isNoColor;
19
- exports.makePalette = makePalette;
20
- exports.getTypeGlyph = getTypeGlyph;
21
- exports.getContractStateColor = getContractStateColor;
22
- const RAW_PALETTE = {
23
- // Text hierarchy
24
- text: '#ffffff',
25
- textSecondary: '#a0a0a0',
26
- textMuted: '#606060',
27
- textDim: '#404040',
28
- // Priority signal
29
- critical: '#ef4444',
30
- high: '#f59e0b',
31
- medium: '#3b82f6',
32
- low: '#6b7280',
33
- // Contract-state signal (design §3: draft dim · ready cyan · in_progress
34
- // yellow · delivered magenta · done green · failed/blocked red)
35
- contractDraft: '#606060',
36
- contractReady: '#06b6d4',
37
- contractInProgress: '#eab308',
38
- contractDelivered: '#c026d3',
39
- contractDone: '#22c55e',
40
- contractFailed: '#ef4444',
41
- // Feedback
42
- success: '#22c55e',
43
- warning: '#eab308',
44
- error: '#ef4444',
45
- info: '#3b82f6',
46
- accent: '#7c3aed',
47
- };
48
- /**
49
- * `NO_COLOR` (https://no-color.org): any non-empty value disables colour. The
50
- * empty string is falsy in JS, which happens to be exactly the spec's rule.
51
- *
52
- * Gating happens HERE, at the prop layer, rather than by forcing `chalk.level`
53
- * to 0 globally. Ink still applies `inverse` through `chalk.inverse`, and chalk
54
- * level 0 (NO_COLOR / FORCE_COLOR=0) is a no-op — so selection also puts a
55
- * cursor glyph in column 1 of `DocumentRow`. The palette gate keeps colour
56
- * props `undefined`; the glyph is what a no-colour terminal can actually see.
57
- *
58
- * The Proxy means all ~107 `PALETTE.x` call sites need no change, and the check
59
- * is a plain runtime read at module init, so it survives the esbuild bundle
60
- * without depending on import order the way a `FORCE_COLOR` shim would.
61
- */
62
- function isNoColor(env = process.env) {
63
- return Boolean(env.NO_COLOR);
64
- }
65
- /**
66
- * The palette the views see. Exported as a factory so the gate is testable
67
- * without module-cache gymnastics — `PALETTE` itself is the one-shot
68
- * application of it to the real environment.
69
- */
70
- function makePalette(noColor) {
71
- if (!noColor)
72
- return RAW_PALETTE;
73
- return new Proxy(RAW_PALETTE, { get: () => undefined });
74
- }
75
- exports.NO_COLOR = isNoColor();
76
- exports.PALETTE = makePalette(exports.NO_COLOR);
77
- /** The only box-drawing character v3 uses: header and footer rules. */
78
- exports.RULE = '─';
79
- /**
80
- * Document-type glyphs (column 1). A plain task deliberately renders *no*
81
- * glyph — the blank column is what makes typed documents stand out.
82
- */
83
- exports.TYPE_GLYPHS = {
84
- epic: '▸',
85
- spec: '◆',
86
- adr: '●',
87
- plan: '⎘',
88
- task: '',
89
- };
90
- function getTypeGlyph(type) {
91
- if (!type)
92
- return '';
93
- return exports.TYPE_GLYPHS[type.toLowerCase()] ?? '';
94
- }
95
- /**
96
- * Plain (non-emoji) glyphs used by the chrome-free views. The v2 emoji set
97
- * (📄 📁 🔍 📦 📋 🗑 …) is gone: emoji have unreliable terminal widths and
98
- * broke column alignment, which is the whole point of the v3 list.
99
- */
100
- exports.GLYPHS = {
101
- pointer: '▸',
102
- cursor: '▌',
103
- collapsed: '▶',
104
- success: '✓',
105
- error: '✗',
106
- warning: '⚠',
107
- live: '●',
108
- subtaskOpen: '◻',
109
- subtaskDone: '☑',
110
- orphanParent: '←',
111
- /** Board-list row glyph for a parent-with-children that is expanded (§A1). */
112
- parentExpanded: '▾',
113
- /** Board-list row glyph for a parent-with-children that is collapsed (§A1). */
114
- parentCollapsed: '▸',
115
- /** Detail body scroll indicator (§B2), e.g. `↕ 2/9`. */
116
- scroll: '↕',
117
- };
118
- /**
119
- * Contract state → colour. Unlike v2 (which had two divergent, both-incomplete
120
- * switch statements in TaskCard and TaskDetail) this is the single mapping, and
121
- * it covers all six states the schema can produce.
122
- */
123
- function getContractStateColor(state) {
124
- switch (state?.toLowerCase()) {
125
- case 'ready':
126
- return exports.PALETTE.contractReady;
127
- case 'in_progress':
128
- return exports.PALETTE.contractInProgress;
129
- case 'delivered':
130
- return exports.PALETTE.contractDelivered;
131
- case 'done':
132
- return exports.PALETTE.contractDone;
133
- case 'failed':
134
- case 'blocked':
135
- return exports.PALETTE.contractFailed;
136
- case 'draft':
137
- default:
138
- return exports.PALETTE.contractDraft;
139
- }
140
- }
141
- //# sourceMappingURL=theme.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"theme.js","sourceRoot":"","sources":["../../src/tui/theme.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;GAaG;;;AA+CH,8BAEC;AAOD,kCAGC;AAqBD,oCAGC;AAwCD,sDAiBC;AA1ID,MAAM,WAAW,GAAG;IAClB,iBAAiB;IACjB,IAAI,EAAE,SAAS;IACf,aAAa,EAAE,SAAS;IACxB,SAAS,EAAE,SAAS;IACpB,OAAO,EAAE,SAAS;IAElB,kBAAkB;IAClB,QAAQ,EAAE,SAAS;IACnB,IAAI,EAAE,SAAS;IACf,MAAM,EAAE,SAAS;IACjB,GAAG,EAAE,SAAS;IAEd,yEAAyE;IACzE,gEAAgE;IAChE,aAAa,EAAE,SAAS;IACxB,aAAa,EAAE,SAAS;IACxB,kBAAkB,EAAE,SAAS;IAC7B,iBAAiB,EAAE,SAAS;IAC5B,YAAY,EAAE,SAAS;IACvB,cAAc,EAAE,SAAS;IAEzB,WAAW;IACX,OAAO,EAAE,SAAS;IAClB,OAAO,EAAE,SAAS;IAClB,KAAK,EAAE,SAAS;IAChB,IAAI,EAAE,SAAS;IACf,MAAM,EAAE,SAAS;CAET,CAAC;AAEX;;;;;;;;;;;;;GAaG;AACH,SAAgB,SAAS,CAAC,MAAyB,OAA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