@takemo101/mikan 0.0.7 → 0.0.9
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 +3 -1
- package/dist/bin.js +179 -66
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -57,13 +57,15 @@ GitHub Mirror is one-way publication from local Markdown Issues to GitHub Issues
|
|
|
57
57
|
|
|
58
58
|
mikan wires into AI coding agents two independent ways. Neither models agents or adds a runtime: mikan stays **stdio MCP only** — no HTTP server, port, auth, scheduler, or workflow engine.
|
|
59
59
|
|
|
60
|
-
- `mikan mcp add --agent <agent>` registers the stdio MCP server in the agent's MCP config. Agents: `pi`, `antigravity`, `jcode`, `claude-code`, `opencode`, `codex`.
|
|
60
|
+
- `mikan mcp add --agent <agent>` registers the stdio MCP server in the agent's MCP config. Agents: `pi`, `antigravity`, `jcode`, `claude-code`, `opencode`, `codex`, `copilot-vscode`, `copilot-cli`.
|
|
61
61
|
- `mikan skills add --agent <agent>` installs a small mikan `SKILL.md` that teaches the agent to drive the board through the MCP tools, including one-way GitHub Mirror publication tools. Agents: `claude-code`, `opencode`, `codex`. This is **separate** from MCP registration — installing skills never changes MCP config.
|
|
62
62
|
|
|
63
63
|
```sh
|
|
64
64
|
mikan mcp add --agent claude-code
|
|
65
65
|
mikan mcp add --agent opencode --no-global
|
|
66
66
|
mikan mcp add --agent codex # global only
|
|
67
|
+
mikan mcp add --agent copilot-vscode --no-global # VS Code workspace only
|
|
68
|
+
mikan mcp add --agent copilot-cli # global only
|
|
67
69
|
mikan skills add --agent claude-code
|
|
68
70
|
mikan mcp llms # incur-backed discovery manifest
|
|
69
71
|
```
|
package/dist/bin.js
CHANGED
|
@@ -100489,6 +100489,7 @@ function validateStatus(config2, status) {
|
|
|
100489
100489
|
}
|
|
100490
100490
|
function validateLabels(config2, labels) {
|
|
100491
100491
|
const known = new Set(config2.labels.map((label) => label.id));
|
|
100492
|
+
const seen = new Set;
|
|
100492
100493
|
const parsed = [];
|
|
100493
100494
|
for (const label of labels) {
|
|
100494
100495
|
if (!known.has(label)) {
|
|
@@ -100504,6 +100505,13 @@ function validateLabels(config2, labels) {
|
|
|
100504
100505
|
error: { kind: "unknown_label", message: labelId.error.message }
|
|
100505
100506
|
};
|
|
100506
100507
|
}
|
|
100508
|
+
if (seen.has(label)) {
|
|
100509
|
+
return {
|
|
100510
|
+
ok: false,
|
|
100511
|
+
error: { kind: "unknown_label", message: `Duplicate Label: ${label}` }
|
|
100512
|
+
};
|
|
100513
|
+
}
|
|
100514
|
+
seen.add(label);
|
|
100507
100515
|
parsed.push(labelId.value);
|
|
100508
100516
|
}
|
|
100509
100517
|
return { ok: true, value: parsed };
|
|
@@ -106953,6 +106961,55 @@ var codexInstaller = {
|
|
|
106953
106961
|
install: installCodexMcpServer
|
|
106954
106962
|
};
|
|
106955
106963
|
|
|
106964
|
+
// ../mcp/src/installers/copilot-cli.ts
|
|
106965
|
+
var copilotCliAdapter = {
|
|
106966
|
+
agent: "copilot-cli",
|
|
106967
|
+
serversKey: "mcpServers",
|
|
106968
|
+
resolveTarget: (options) => {
|
|
106969
|
+
if (!isGlobalScope(options)) {
|
|
106970
|
+
throw new Error("GitHub Copilot CLI MCP configuration is global-only; it has no " + "verified workspace-local scope. Re-run `mikan mcp add --agent " + "copilot-cli` without --no-global to register the server in " + "~/.copilot/mcp-config.json.");
|
|
106971
|
+
}
|
|
106972
|
+
return {
|
|
106973
|
+
path: homePath(options, ".copilot", "mcp-config.json"),
|
|
106974
|
+
scope: "global"
|
|
106975
|
+
};
|
|
106976
|
+
},
|
|
106977
|
+
buildEntry: (spec) => ({
|
|
106978
|
+
type: "local",
|
|
106979
|
+
command: spec.command,
|
|
106980
|
+
args: spec.args,
|
|
106981
|
+
env: spec.env,
|
|
106982
|
+
tools: ["*"]
|
|
106983
|
+
})
|
|
106984
|
+
};
|
|
106985
|
+
var copilotCliInstaller = createInstaller(copilotCliAdapter);
|
|
106986
|
+
|
|
106987
|
+
// ../mcp/src/installers/copilot-vscode.ts
|
|
106988
|
+
var copilotVscodeAdapter = {
|
|
106989
|
+
agent: "copilot-vscode",
|
|
106990
|
+
serversKey: "servers",
|
|
106991
|
+
resolveTarget: (options) => {
|
|
106992
|
+
if (isGlobalScope(options)) {
|
|
106993
|
+
throw new Error("VS Code user-profile MCP configuration path is not verified; " + "re-run `mikan mcp add --agent copilot-vscode --no-global` " + "to register mikan in .vscode/mcp.json for this workspace.");
|
|
106994
|
+
}
|
|
106995
|
+
return {
|
|
106996
|
+
path: workspacePath(options, ".vscode", "mcp.json"),
|
|
106997
|
+
scope: "workspace"
|
|
106998
|
+
};
|
|
106999
|
+
},
|
|
107000
|
+
buildEntry: (spec) => {
|
|
107001
|
+
const entry = {
|
|
107002
|
+
type: "stdio",
|
|
107003
|
+
command: spec.command,
|
|
107004
|
+
args: spec.args
|
|
107005
|
+
};
|
|
107006
|
+
if (Object.keys(spec.env).length > 0)
|
|
107007
|
+
entry.env = spec.env;
|
|
107008
|
+
return entry;
|
|
107009
|
+
}
|
|
107010
|
+
};
|
|
107011
|
+
var copilotVscodeInstaller = createInstaller(copilotVscodeAdapter);
|
|
107012
|
+
|
|
106956
107013
|
// ../mcp/src/installers/jcode.ts
|
|
106957
107014
|
var jcodeAdapter = {
|
|
106958
107015
|
agent: "jcode",
|
|
@@ -107009,7 +107066,9 @@ var mcpAgentInstallers = [
|
|
|
107009
107066
|
jcodeInstaller,
|
|
107010
107067
|
claudeCodeInstaller,
|
|
107011
107068
|
opencodeInstaller,
|
|
107012
|
-
codexInstaller
|
|
107069
|
+
codexInstaller,
|
|
107070
|
+
copilotVscodeInstaller,
|
|
107071
|
+
copilotCliInstaller
|
|
107013
107072
|
];
|
|
107014
107073
|
function installMcpServerForAgent(agent, options = {}) {
|
|
107015
107074
|
const installer = mcpAgentInstallers.find((entry) => entry.agent === agent);
|
|
@@ -107402,7 +107461,7 @@ var import_react20 = __toESM(require_react(), 1);
|
|
|
107402
107461
|
// package.json
|
|
107403
107462
|
var package_default = {
|
|
107404
107463
|
name: "@takemo101/mikan",
|
|
107405
|
-
version: "0.0.
|
|
107464
|
+
version: "0.0.9",
|
|
107406
107465
|
private: false,
|
|
107407
107466
|
type: "module",
|
|
107408
107467
|
bin: {
|
|
@@ -107466,6 +107525,9 @@ function visibleDetailLineCount(viewportHeight) {
|
|
|
107466
107525
|
return Math.max(1, viewportHeight - 8);
|
|
107467
107526
|
}
|
|
107468
107527
|
function footerText(mode) {
|
|
107528
|
+
if (mode === "note-modal") {
|
|
107529
|
+
return "Note | Enter newline | Ctrl+S save | Esc cancel";
|
|
107530
|
+
}
|
|
107469
107531
|
if (mode === "modal") {
|
|
107470
107532
|
return "Modal | enter confirm | esc cancel | ? keys";
|
|
107471
107533
|
}
|
|
@@ -107986,7 +108048,9 @@ function moveSelection(model, selection, direction, options = {}) {
|
|
|
107986
108048
|
detailOpen: false,
|
|
107987
108049
|
moveOpen: false,
|
|
107988
108050
|
noteOpen: false,
|
|
107989
|
-
|
|
108051
|
+
noteDraft: undefined,
|
|
108052
|
+
labelOpen: false,
|
|
108053
|
+
message: selection.noteOpen ? undefined : selection.message
|
|
107990
108054
|
};
|
|
107991
108055
|
}
|
|
107992
108056
|
if (direction === "move") {
|
|
@@ -107995,6 +108059,7 @@ function moveSelection(model, selection, direction, options = {}) {
|
|
|
107995
108059
|
archiveOpen: false,
|
|
107996
108060
|
detailOpen: false,
|
|
107997
108061
|
noteOpen: false,
|
|
108062
|
+
noteDraft: undefined,
|
|
107998
108063
|
labelOpen: false,
|
|
107999
108064
|
moveOpen: true,
|
|
108000
108065
|
moveTargetIndex: 0
|
|
@@ -108007,7 +108072,9 @@ function moveSelection(model, selection, direction, options = {}) {
|
|
|
108007
108072
|
detailOpen: false,
|
|
108008
108073
|
moveOpen: false,
|
|
108009
108074
|
labelOpen: false,
|
|
108010
|
-
noteOpen: true
|
|
108075
|
+
noteOpen: true,
|
|
108076
|
+
noteDraft: "",
|
|
108077
|
+
message: undefined
|
|
108011
108078
|
};
|
|
108012
108079
|
}
|
|
108013
108080
|
if (direction === "edit-labels") {
|
|
@@ -108019,6 +108086,7 @@ function moveSelection(model, selection, direction, options = {}) {
|
|
|
108019
108086
|
githubConfirmOpen: false,
|
|
108020
108087
|
moveOpen: false,
|
|
108021
108088
|
noteOpen: false,
|
|
108089
|
+
noteDraft: undefined,
|
|
108022
108090
|
labelOpen: true,
|
|
108023
108091
|
labelFocusIndex: 0,
|
|
108024
108092
|
labelDraftIds: card?.labels.filter((label) => knownLabelIds.has(label)) ?? []
|
|
@@ -108030,6 +108098,7 @@ function moveSelection(model, selection, direction, options = {}) {
|
|
|
108030
108098
|
archiveOpen: true,
|
|
108031
108099
|
moveOpen: false,
|
|
108032
108100
|
noteOpen: false,
|
|
108101
|
+
noteDraft: undefined,
|
|
108033
108102
|
labelOpen: false,
|
|
108034
108103
|
githubConfirmOpen: false
|
|
108035
108104
|
};
|
|
@@ -108040,6 +108109,7 @@ function moveSelection(model, selection, direction, options = {}) {
|
|
|
108040
108109
|
archiveOpen: false,
|
|
108041
108110
|
moveOpen: false,
|
|
108042
108111
|
noteOpen: false,
|
|
108112
|
+
noteDraft: undefined,
|
|
108043
108113
|
labelOpen: false,
|
|
108044
108114
|
githubConfirmOpen: true
|
|
108045
108115
|
};
|
|
@@ -108093,28 +108163,17 @@ function toggleFocusedLabel(model, selection) {
|
|
|
108093
108163
|
current.add(label.id);
|
|
108094
108164
|
return { ...selection, labelDraftIds: [...current] };
|
|
108095
108165
|
}
|
|
108096
|
-
function applyNoteInput(selection, keyName2, shift = false) {
|
|
108097
|
-
if (!selection.noteOpen || !keyName2)
|
|
108098
|
-
return selection;
|
|
108099
|
-
if (keyName2 === "backspace") {
|
|
108100
|
-
return {
|
|
108101
|
-
...selection,
|
|
108102
|
-
noteDraft: (selection.noteDraft ?? "").slice(0, -1)
|
|
108103
|
-
};
|
|
108104
|
-
}
|
|
108105
|
-
const character = keyName2 === "space" ? " " : keyName2;
|
|
108106
|
-
if (character.length !== 1)
|
|
108107
|
-
return selection;
|
|
108108
|
-
const value = shift && /[a-z]/.test(character) ? character.toUpperCase() : character;
|
|
108109
|
-
return { ...selection, noteDraft: `${selection.noteDraft ?? ""}${value}` };
|
|
108110
|
-
}
|
|
108111
108166
|
function footerMode(selection) {
|
|
108112
|
-
if (selection.
|
|
108167
|
+
if (selection.noteOpen)
|
|
108168
|
+
return "note-modal";
|
|
108169
|
+
if (selection.moveOpen || selection.labelOpen || selection.archiveOpen || selection.githubConfirmOpen) {
|
|
108113
108170
|
return "modal";
|
|
108114
108171
|
}
|
|
108115
108172
|
return selection.detailOpen ? "detail" : "board";
|
|
108116
108173
|
}
|
|
108117
|
-
function keyToTuiAction(keyName2, shift = false) {
|
|
108174
|
+
function keyToTuiAction(keyName2, shift = false, ctrl = false) {
|
|
108175
|
+
if (ctrl && keyName2 === "s")
|
|
108176
|
+
return "save-note";
|
|
108118
108177
|
if (shift && keyName2 === "h")
|
|
108119
108178
|
return "move-left";
|
|
108120
108179
|
if (shift && keyName2 === "l")
|
|
@@ -108195,8 +108254,8 @@ function buildNotePromptViewModel(model, selection) {
|
|
|
108195
108254
|
return {
|
|
108196
108255
|
title: `Append note to ${card.id}`,
|
|
108197
108256
|
focused: Boolean(selection.noteOpen),
|
|
108198
|
-
|
|
108199
|
-
hint: "
|
|
108257
|
+
feedback: selection.message === "Note cannot be empty" ? selection.message : undefined,
|
|
108258
|
+
hint: "Enter newline | Ctrl+S save | Esc cancel"
|
|
108200
108259
|
};
|
|
108201
108260
|
}
|
|
108202
108261
|
function buildLabelPromptViewModel(model, selection) {
|
|
@@ -108259,17 +108318,6 @@ function renderMoveInteraction(model, selection) {
|
|
|
108259
108318
|
view.hint
|
|
108260
108319
|
];
|
|
108261
108320
|
}
|
|
108262
|
-
function renderNoteInteraction(model, selection) {
|
|
108263
|
-
const view = buildNotePromptViewModel(model, selection);
|
|
108264
|
-
if (!view)
|
|
108265
|
-
return ["Append note", "No Issue selected"];
|
|
108266
|
-
return [
|
|
108267
|
-
view.title,
|
|
108268
|
-
`Note: ${view.draft}`,
|
|
108269
|
-
...view.feedback ? [view.feedback] : [],
|
|
108270
|
-
view.hint
|
|
108271
|
-
];
|
|
108272
|
-
}
|
|
108273
108321
|
function renderLabelInteraction(model, selection) {
|
|
108274
108322
|
const view = buildLabelPromptViewModel(model, selection);
|
|
108275
108323
|
if (!view)
|
|
@@ -108314,6 +108362,7 @@ function renderKeyHelp() {
|
|
|
108314
108362
|
"H/L move Issue",
|
|
108315
108363
|
"m move menu",
|
|
108316
108364
|
"n append Note",
|
|
108365
|
+
"note: enter newline, ctrl+s save",
|
|
108317
108366
|
"e edit Labels",
|
|
108318
108367
|
"a archive Issue",
|
|
108319
108368
|
"g GitHub Mirror",
|
|
@@ -108334,13 +108383,50 @@ function MovePrompt(props) {
|
|
|
108334
108383
|
});
|
|
108335
108384
|
}
|
|
108336
108385
|
function NotePrompt(props) {
|
|
108337
|
-
|
|
108386
|
+
const view = buildNotePromptViewModel(props.model, props.selection);
|
|
108387
|
+
if (!view) {
|
|
108388
|
+
return renderModalText({
|
|
108389
|
+
theme: props.theme,
|
|
108390
|
+
backdropId: "note-modal-backdrop",
|
|
108391
|
+
panelId: "note-prompt",
|
|
108392
|
+
title: "Append Note",
|
|
108393
|
+
content: ["Append note", "No Issue selected"]
|
|
108394
|
+
});
|
|
108395
|
+
}
|
|
108396
|
+
const initialValue = props.selection.noteDraft ?? "";
|
|
108397
|
+
return renderModalShell({
|
|
108338
108398
|
theme: props.theme,
|
|
108339
108399
|
backdropId: "note-modal-backdrop",
|
|
108340
108400
|
panelId: "note-prompt",
|
|
108341
108401
|
title: "Append Note",
|
|
108342
|
-
|
|
108343
|
-
}
|
|
108402
|
+
panelStyle: { height: view.feedback ? 14 : 13 }
|
|
108403
|
+
}, import_react3.default.createElement("text", {
|
|
108404
|
+
content: [view.title, "", "Note:"].join(`
|
|
108405
|
+
`)
|
|
108406
|
+
}), import_react3.default.createElement("textarea", {
|
|
108407
|
+
id: "note-textarea",
|
|
108408
|
+
ref: props.noteTextareaRef,
|
|
108409
|
+
focused: true,
|
|
108410
|
+
initialValue,
|
|
108411
|
+
placeholder: "Write a Note...",
|
|
108412
|
+
height: 5,
|
|
108413
|
+
wrapMode: "word",
|
|
108414
|
+
keyBindings: [{ name: "s", ctrl: true, action: "submit" }],
|
|
108415
|
+
onSubmit: () => {
|
|
108416
|
+
props.onNoteSubmit?.(props.noteTextareaRef?.current?.plainText ?? "");
|
|
108417
|
+
},
|
|
108418
|
+
style: {
|
|
108419
|
+
alignSelf: "stretch",
|
|
108420
|
+
backgroundColor: props.theme?.base.canvas,
|
|
108421
|
+
textColor: props.theme?.base.text,
|
|
108422
|
+
focusedBackgroundColor: props.theme?.base.canvas,
|
|
108423
|
+
focusedTextColor: props.theme?.base.text,
|
|
108424
|
+
width: "auto"
|
|
108425
|
+
}
|
|
108426
|
+
}), import_react3.default.createElement("text", {
|
|
108427
|
+
content: ["", ...view.feedback ? [view.feedback] : [], view.hint].join(`
|
|
108428
|
+
`)
|
|
108429
|
+
}));
|
|
108344
108430
|
}
|
|
108345
108431
|
function LabelPrompt(props) {
|
|
108346
108432
|
return renderModalText({
|
|
@@ -108370,6 +108456,12 @@ function GitHubMirrorPrompt(props) {
|
|
|
108370
108456
|
});
|
|
108371
108457
|
}
|
|
108372
108458
|
function renderModalText(options) {
|
|
108459
|
+
return renderModalShell(options, import_react3.default.createElement("text", {
|
|
108460
|
+
content: options.content.join(`
|
|
108461
|
+
`)
|
|
108462
|
+
}));
|
|
108463
|
+
}
|
|
108464
|
+
function renderModalShell(options, ...children) {
|
|
108373
108465
|
const theme = options.theme ?? buildTuiTheme();
|
|
108374
108466
|
return import_react3.default.createElement("box", {
|
|
108375
108467
|
id: options.backdropId,
|
|
@@ -108382,10 +108474,7 @@ function renderModalText(options) {
|
|
|
108382
108474
|
...modalStyle(theme),
|
|
108383
108475
|
...options.panelStyle ?? {}
|
|
108384
108476
|
}
|
|
108385
|
-
},
|
|
108386
|
-
content: options.content.join(`
|
|
108387
|
-
`)
|
|
108388
|
-
})));
|
|
108477
|
+
}, ...children));
|
|
108389
108478
|
}
|
|
108390
108479
|
function modalBackdropStyle(_theme) {
|
|
108391
108480
|
return {
|
|
@@ -108765,7 +108854,7 @@ function appendSelectedIssueNote(options) {
|
|
|
108765
108854
|
return {
|
|
108766
108855
|
ok: false,
|
|
108767
108856
|
model: options.model,
|
|
108768
|
-
selection: { ...options.selection, noteOpen:
|
|
108857
|
+
selection: { ...options.selection, noteOpen: true },
|
|
108769
108858
|
message: "Note cannot be empty"
|
|
108770
108859
|
};
|
|
108771
108860
|
}
|
|
@@ -108812,7 +108901,8 @@ function appendSelectedIssueNote(options) {
|
|
|
108812
108901
|
selection: {
|
|
108813
108902
|
...selection,
|
|
108814
108903
|
detailOpen: options.selection.detailOpen,
|
|
108815
|
-
noteOpen: false
|
|
108904
|
+
noteOpen: false,
|
|
108905
|
+
noteDraft: undefined
|
|
108816
108906
|
},
|
|
108817
108907
|
message: `${card.id} note appended`
|
|
108818
108908
|
};
|
|
@@ -108829,7 +108919,9 @@ function TuiAppView({
|
|
|
108829
108919
|
theme = buildTuiTheme(),
|
|
108830
108920
|
viewportHeight,
|
|
108831
108921
|
viewportWidth,
|
|
108832
|
-
columns
|
|
108922
|
+
columns,
|
|
108923
|
+
noteTextareaRef,
|
|
108924
|
+
onNoteSubmit
|
|
108833
108925
|
}) {
|
|
108834
108926
|
const details = selection.detailOpen ? getSelectedDetails(model, selection) : undefined;
|
|
108835
108927
|
return import_react20.default.createElement("box", {
|
|
@@ -108855,7 +108947,13 @@ function TuiAppView({
|
|
|
108855
108947
|
viewportHeight,
|
|
108856
108948
|
viewportWidth,
|
|
108857
108949
|
columns
|
|
108858
|
-
})), selection.moveOpen ? import_react20.default.createElement(MovePrompt, { model, selection, theme }) : undefined, selection.noteOpen ? import_react20.default.createElement(NotePrompt, {
|
|
108950
|
+
})), selection.moveOpen ? import_react20.default.createElement(MovePrompt, { model, selection, theme }) : undefined, selection.noteOpen ? import_react20.default.createElement(NotePrompt, {
|
|
108951
|
+
model,
|
|
108952
|
+
selection,
|
|
108953
|
+
theme,
|
|
108954
|
+
noteTextareaRef,
|
|
108955
|
+
onNoteSubmit
|
|
108956
|
+
}) : undefined, selection.labelOpen ? import_react20.default.createElement(LabelPrompt, { model, selection, theme }) : undefined, selection.archiveOpen ? import_react20.default.createElement(ArchivePrompt, { model, selection, theme }) : undefined, selection.githubConfirmOpen ? import_react20.default.createElement(GitHubMirrorPrompt, { model, selection, theme }) : undefined, selection.warningsOpen ? import_react20.default.createElement(WarningPanel, { model, theme }) : undefined, selection.helpOpen ? import_react20.default.createElement(HelpPanel, { theme }) : undefined, import_react20.default.createElement(Footer, {
|
|
108859
108957
|
message: selection.message,
|
|
108860
108958
|
mode: footerMode(selection),
|
|
108861
108959
|
theme
|
|
@@ -108889,6 +108987,19 @@ async function launchTui(options = {}) {
|
|
|
108889
108987
|
const modelRef = import_react20.default.useRef(model);
|
|
108890
108988
|
const selectionRef = import_react20.default.useRef(selection);
|
|
108891
108989
|
const githubBusyRef = import_react20.default.useRef(false);
|
|
108990
|
+
const noteTextareaRef = import_react20.default.useRef(null);
|
|
108991
|
+
const submitNote = import_react20.default.useCallback((body) => {
|
|
108992
|
+
const result = appendSelectedIssueNote({
|
|
108993
|
+
cwd: options.cwd,
|
|
108994
|
+
model: modelRef.current,
|
|
108995
|
+
selection: selectionRef.current,
|
|
108996
|
+
body
|
|
108997
|
+
});
|
|
108998
|
+
modelRef.current = result.model;
|
|
108999
|
+
selectionRef.current = { ...result.selection, message: result.message };
|
|
109000
|
+
setModel(result.model);
|
|
109001
|
+
setSelection({ ...result.selection, message: result.message });
|
|
109002
|
+
}, []);
|
|
108892
109003
|
modelRef.current = model;
|
|
108893
109004
|
selectionRef.current = selection;
|
|
108894
109005
|
import_react20.default.useEffect(() => {
|
|
@@ -108906,7 +109017,7 @@ async function launchTui(options = {}) {
|
|
|
108906
109017
|
return () => clearInterval(interval);
|
|
108907
109018
|
}, []);
|
|
108908
109019
|
useKeyboard2((key) => {
|
|
108909
|
-
const action = keyToTuiAction(key.name, key.shift);
|
|
109020
|
+
const action = keyToTuiAction(key.name, key.shift, key.ctrl);
|
|
108910
109021
|
if (selection.helpOpen) {
|
|
108911
109022
|
if (action === "escape" || action === "help") {
|
|
108912
109023
|
setSelection((current) => moveSelection(model, current, action));
|
|
@@ -108914,26 +109025,10 @@ async function launchTui(options = {}) {
|
|
|
108914
109025
|
return;
|
|
108915
109026
|
}
|
|
108916
109027
|
if (selection.noteOpen) {
|
|
108917
|
-
if (action === "help") {
|
|
108918
|
-
setSelection((current) => moveSelection(model, current, action));
|
|
108919
|
-
return;
|
|
108920
|
-
}
|
|
108921
109028
|
if (action === "escape") {
|
|
108922
109029
|
setSelection((current) => moveSelection(model, current, action));
|
|
108923
109030
|
return;
|
|
108924
109031
|
}
|
|
108925
|
-
if (action === "enter") {
|
|
108926
|
-
const result = appendSelectedIssueNote({
|
|
108927
|
-
cwd: options.cwd,
|
|
108928
|
-
model,
|
|
108929
|
-
selection,
|
|
108930
|
-
body: selection.noteDraft ?? ""
|
|
108931
|
-
});
|
|
108932
|
-
setModel(result.model);
|
|
108933
|
-
setSelection({ ...result.selection, message: result.message });
|
|
108934
|
-
return;
|
|
108935
|
-
}
|
|
108936
|
-
setSelection((current) => applyNoteInput(current, key.name, key.shift));
|
|
108937
109032
|
return;
|
|
108938
109033
|
}
|
|
108939
109034
|
if (selection.archiveOpen) {
|
|
@@ -109066,6 +109161,8 @@ async function launchTui(options = {}) {
|
|
|
109066
109161
|
setSelection((current) => moveSelection(model, current, action));
|
|
109067
109162
|
return;
|
|
109068
109163
|
}
|
|
109164
|
+
if (action === "save-note")
|
|
109165
|
+
return;
|
|
109069
109166
|
if (action === "github") {
|
|
109070
109167
|
if (githubBusyRef.current)
|
|
109071
109168
|
return;
|
|
@@ -109098,7 +109195,9 @@ async function launchTui(options = {}) {
|
|
|
109098
109195
|
selection,
|
|
109099
109196
|
viewportHeight: renderer.height,
|
|
109100
109197
|
viewportWidth: renderer.width,
|
|
109101
|
-
columns: options.columns
|
|
109198
|
+
columns: options.columns,
|
|
109199
|
+
noteTextareaRef,
|
|
109200
|
+
onNoteSubmit: submitNote
|
|
109102
109201
|
});
|
|
109103
109202
|
}
|
|
109104
109203
|
root.render(import_react20.default.createElement(App));
|
|
@@ -109503,7 +109602,8 @@ function readCurrentSnapshot(loaded) {
|
|
|
109503
109602
|
function writeSnapshot(path5, snapshot) {
|
|
109504
109603
|
mkdirSync7(dirname8(path5), { recursive: true });
|
|
109505
109604
|
const tmp = `${path5}.${process.pid}.${Date.now()}.tmp`;
|
|
109506
|
-
writeFileSync7(tmp, JSON.stringify(snapshot, null, 2)
|
|
109605
|
+
writeFileSync7(tmp, `${JSON.stringify(snapshot, null, 2)}
|
|
109606
|
+
`);
|
|
109507
109607
|
renameSync4(tmp, path5);
|
|
109508
109608
|
}
|
|
109509
109609
|
function watcherSnapshotPath(projectRoot) {
|
|
@@ -109833,6 +109933,10 @@ function helpText() {
|
|
|
109833
109933
|
Usage:
|
|
109834
109934
|
mikan <command> [options]
|
|
109835
109935
|
|
|
109936
|
+
Options:
|
|
109937
|
+
-v, --version Print mikan version
|
|
109938
|
+
-h, --help Show this help
|
|
109939
|
+
|
|
109836
109940
|
Commands:
|
|
109837
109941
|
init Create .mikan project files
|
|
109838
109942
|
add Create an Issue
|
|
@@ -109992,13 +110096,14 @@ Usage:
|
|
|
109992
110096
|
mikan mcp llms [--full]
|
|
109993
110097
|
|
|
109994
110098
|
Options:
|
|
109995
|
-
-a, --agent <agent> Agent to configure: pi, antigravity, jcode, claude-code, opencode, codex
|
|
110099
|
+
-a, --agent <agent> Agent to configure: pi, antigravity, jcode, claude-code, opencode, codex, copilot-vscode, copilot-cli
|
|
109996
110100
|
--no-global Write workspace-local config instead of global config
|
|
109997
110101
|
--full With llms: print the full incur manifest
|
|
109998
110102
|
-h, --help Show this help
|
|
109999
110103
|
|
|
110000
110104
|
Notes:
|
|
110001
|
-
codex
|
|
110105
|
+
codex and copilot-cli register globally only; --no-global is rejected.
|
|
110106
|
+
copilot-vscode writes workspace .vscode/mcp.json only; use --no-global.
|
|
110002
110107
|
Use mikan mcp add for native per-agent registration. Use mikan mcp llms for
|
|
110003
110108
|
incur-backed discovery: it prints a manifest for agents that read incur
|
|
110004
110109
|
manifests directly and never installs anything. Passing --agent to llms is
|
|
@@ -110011,6 +110116,8 @@ Examples:
|
|
|
110011
110116
|
mikan mcp add --agent claude-code
|
|
110012
110117
|
mikan mcp add --agent opencode --no-global
|
|
110013
110118
|
mikan mcp add --agent codex
|
|
110119
|
+
mikan mcp add --agent copilot-vscode --no-global
|
|
110120
|
+
mikan mcp add --agent copilot-cli
|
|
110014
110121
|
mikan mcp llms
|
|
110015
110122
|
mikan mcp llms --full
|
|
110016
110123
|
`;
|
|
@@ -110063,6 +110170,9 @@ async function runCli(argv = process.argv.slice(2), options = {}) {
|
|
|
110063
110170
|
const command = argv[0];
|
|
110064
110171
|
if (!command || isHelpFlag(command))
|
|
110065
110172
|
return ok2(helpText());
|
|
110173
|
+
if (isVersionFlag(command))
|
|
110174
|
+
return ok2(`${package_default.version}
|
|
110175
|
+
`);
|
|
110066
110176
|
if (command === "help") {
|
|
110067
110177
|
const topic = argv[1];
|
|
110068
110178
|
return topic ? commandHelp(topic) : ok2(helpText());
|
|
@@ -110121,6 +110231,9 @@ Run \`mikan help tui\` for usage.`);
|
|
|
110121
110231
|
return fail2(error51 instanceof Error ? error51.message : String(error51));
|
|
110122
110232
|
}
|
|
110123
110233
|
}
|
|
110234
|
+
function isVersionFlag(input) {
|
|
110235
|
+
return input === "-v" || input === "--version";
|
|
110236
|
+
}
|
|
110124
110237
|
async function main(argv = process.argv.slice(2)) {
|
|
110125
110238
|
const result = await runInteractiveCommand(argv, { cwd: process.cwd() });
|
|
110126
110239
|
if (result.stdout)
|