@ksm0709/context 0.0.34 → 0.0.36

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 CHANGED
@@ -10,7 +10,20 @@ Context plugin for Bun
10
10
 
11
11
  ## MCP Server
12
12
 
13
- This plugin automatically registers an MCP (Model Context Protocol) server named `context-mcp` with OpenCode. The server provides tools for searching knowledge base files (`.md` files in `docs/` and `.context/` directories).
13
+ This plugin automatically registers an MCP (Model Context Protocol) server named `context-mcp` with OpenCode. The server provides metadata-first knowledge discovery for `.md` files in `docs/` and `.context/`.
14
+
15
+ Recommended workflow:
16
+
17
+ 1. Run `search_knowledge` to get ranked candidate notes.
18
+ 2. Compare each result's path, title, description, tags, score, and snippet.
19
+ 3. Open the best match with `read_knowledge`.
20
+ 4. Use the related-note metadata appended to `read_knowledge` output to continue exploring linked notes.
21
+
22
+ Core knowledge tools:
23
+
24
+ - `search_knowledge` — returns ranked note summaries so agents can choose what to open next without relying on exact full-text matches.
25
+ - `read_knowledge` — opens a selected note and appends linked-note metadata for relevant `[[wikilink]]` references.
26
+ - `create_knowledge_note` / `update_knowledge_note` — create and maintain knowledge notes once the relevant context is understood.
14
27
 
15
28
  ## OMX Support
16
29
 
package/dist/cli/index.js CHANGED
@@ -2,9 +2,9 @@
2
2
  // @bun
3
3
 
4
4
  // src/cli/commands/update.ts
5
- import { resolve as resolve3, join as join7 } from "path";
6
- import { existsSync as existsSync8 } from "fs";
7
- import { homedir as homedir3 } from "os";
5
+ import { resolve as resolve3, join as join8 } from "path";
6
+ import { existsSync as existsSync9 } from "fs";
7
+ import { homedir as homedir4 } from "os";
8
8
 
9
9
  // src/lib/scaffold.ts
10
10
  import { existsSync as existsSync2, mkdirSync, readFileSync, writeFileSync } from "fs";
@@ -27,7 +27,7 @@ function resolveContextDir(projectDir) {
27
27
  // package.json
28
28
  var package_default = {
29
29
  name: "@ksm0709/context",
30
- version: "0.0.34",
30
+ version: "0.0.36",
31
31
  author: {
32
32
  name: "TaehoKang",
33
33
  email: "ksm07091@gmail.com"
@@ -69,24 +69,23 @@ var package_default = {
69
69
  "@opencode-ai/plugin": ">=1.0.0"
70
70
  },
71
71
  dependencies: {
72
- "@ksm0709/context": "^0.0.33",
73
72
  "@modelcontextprotocol/sdk": "^1.27.1",
74
73
  "jsonc-parser": "^3.0.0"
75
74
  },
76
75
  devDependencies: {
77
- "@opencode-ai/plugin": "^1.2.10",
78
76
  "@eslint/js": "^9.39.1",
77
+ "@opencode-ai/plugin": "^1.2.10",
79
78
  "@types/node": "^20.11.5",
80
79
  "@typescript-eslint/eslint-plugin": "8.47.0",
81
80
  "@typescript-eslint/parser": "8.47.0",
81
+ "@vitest/coverage-v8": "^3.2.4",
82
82
  "bun-types": "latest",
83
83
  eslint: "^9.39.1",
84
84
  "eslint-config-prettier": "10.1.8",
85
85
  "eslint-plugin-prettier": "^5.1.3",
86
86
  prettier: "^3.2.4",
87
87
  "typescript-eslint": "^8.47.0",
88
- vitest: "^3.2.4",
89
- "@vitest/coverage-v8": "^3.2.4"
88
+ vitest: "^3.2.4"
90
89
  }
91
90
  };
92
91
 
@@ -326,6 +325,8 @@ var DEFAULT_DAILY_NOTE_GUIDE = `# \uB370\uC77C\uB9AC \uB178\uD2B8 \uAE30\uB85D \
326
325
  var DEFAULT_NOTE_GUIDE = `# \uC9C0\uC2DD \uB178\uD2B8 \uC791\uC131 \uBC0F \uAD00\uB9AC \uAC00\uC774\uB4DC
327
326
 
328
327
  - [ ] **\uB178\uD2B8 \uC0DD\uC131**: \`context_mcp_create_knowledge_note\` \uB3C4\uAD6C\uB97C \uC0AC\uC6A9\uD558\uC5EC \uC0DD\uC131\uD558\uC138\uC694.
328
+ - [ ] \uD15C\uD50C\uB9BF \uBAA8\uB4DC\uC5D0\uC11C\uB294 \uBA3C\uC800 \`.context/templates/<template>.md\`\uB97C \uC77D\uACE0, **\uC644\uC131\uB41C markdown \uC804\uCCB4**\uB97C \`content\`\uB85C \uC804\uB2EC\uD558\uC138\uC694.
329
+ - [ ] \uD15C\uD50C\uB9BF \uBAA8\uB4DC\uC5D0\uC11C\uB294 \`tags\`/\`linked_notes\`\uB97C \uB530\uB85C \uB118\uAE30\uC9C0 \uB9C8\uC138\uC694. \uAD00\uB828 \uB178\uD2B8\uC640 \uBA54\uD0C0\uB370\uC774\uD130\uB294 markdown \uBCF8\uBB38\uC5D0 \uC9C1\uC811 \uC791\uC131\uD574\uC57C \uD569\uB2C8\uB2E4.
329
330
  - [ ] \uC81C\uD154\uCE74\uC2A4\uD150(Zettelkasten) 3\uB300 \uC6D0\uCE59 \uC900\uC218:
330
331
  - [ ] \uC6D0\uC790\uC131: \uD55C \uB178\uD2B8\uB2F9 \uD55C \uC8FC\uC81C
331
332
  - [ ] \uC5F0\uACB0: \uACE0\uB9BD\uB41C \uB178\uD2B8 \uBC29\uC9C0
@@ -450,8 +451,8 @@ function writeVersion(contextDir, version) {
450
451
  }
451
452
 
452
453
  // src/cli/commands/install.ts
453
- import { join as join6, resolve as resolve2, dirname as dirname5 } from "path";
454
- import { existsSync as existsSync7, mkdirSync as mkdirSync5, copyFileSync } from "fs";
454
+ import { join as join7, resolve as resolve2, dirname as dirname5 } from "path";
455
+ import { existsSync as existsSync8, mkdirSync as mkdirSync5, copyFileSync } from "fs";
455
456
  import { fileURLToPath as fileURLToPath2 } from "url";
456
457
  import { createRequire as createRequire2 } from "module";
457
458
  import { execSync as execSync2 } from "child_process";
@@ -622,14 +623,17 @@ var STATIC_KNOWLEDGE_CONTEXT = `## Knowledge Context
622
623
  3. **\uC790\uAE30 \uC5B8\uC5B4** -- \uBCF5\uC0AC-\uBD99\uC5EC\uB123\uAE30\uAC00 \uC544\uB2CC, \uD575\uC2EC\uC744 \uC774\uD574\uD558\uACE0 \uAC04\uACB0\uD558\uAC8C \uC11C\uC220\uD558\uC138\uC694.
623
624
 
624
625
  ### MCP Tools
625
- - **\uC9C0\uC2DD \uAD00\uB9AC**: \`context_mcp_search_knowledge\`, \`context_mcp_read_knowledge\`, \`context_mcp_create_knowledge_note\`, \`context_mcp_update_knowledge_note\`
626
+ - **\uC9C0\uC2DD \uD0D0\uC0C9**: \`context_mcp_search_knowledge\`\uB85C \uD6C4\uBCF4 \uB178\uD2B8\uB97C \uCC3E\uACE0, \uACB0\uACFC\uC758 title / description / tags / path / score\uB97C \uBA3C\uC800 \uBE44\uAD50\uD558\uC138\uC694.
627
+ - **\uB178\uD2B8 \uC5F4\uAE30**: \`context_mcp_read_knowledge\`\uB85C \uC120\uD0DD\uD55C \uB178\uD2B8\uB97C \uC5F4\uACE0, \uB05D\uC5D0 \uBD99\uB294 related notes \uBA54\uD0C0\uB370\uC774\uD130\uB85C \uB2E4\uC74C \uD0D0\uC0C9 \uACBD\uB85C\uB97C \uC815\uD558\uC138\uC694.
628
+ - **\uB178\uD2B8 \uC791\uC131/\uC218\uC815**: \`context_mcp_create_knowledge_note\`, \`context_mcp_update_knowledge_note\`
626
629
  - **\uB370\uC77C\uB9AC \uB178\uD2B8**: \`context_mcp_read_daily_note\`, \`context_mcp_append_daily_note\`
627
630
  - **\uC791\uC5C5 \uC644\uB8CC**: \`context_mcp_submit_turn_complete\` (\uC791\uC5C5 \uC885\uB8CC \uC2DC \uD544\uC218 \uD638\uCD9C)
628
631
 
629
632
  ### \uC791\uC5C5 \uC804 \uD544\uC218
630
633
  - **\uB370\uC77C\uB9AC \uB178\uD2B8 \uD655\uC778**: \uAC00\uC7A5 \uCD5C\uADFC\uC758 \uB370\uC77C\uB9AC \uB178\uD2B8\uB97C \uC77D\uACE0 \uC774\uC804 \uC138\uC158\uC758 \uCEE8\uD14D\uC2A4\uD2B8\uC640 \uBBF8\uD574\uACB0 \uC774\uC288\uB97C \uD30C\uC545\uD558\uC138\uC694.
631
634
  - **\uC791\uC5C5 \uC758\uB3C4 \uC120\uC5B8**: \uC791\uC5C5 \uC2DC\uC791 \uC804, \uD604\uC7AC \uC138\uC158\uC758 \uBAA9\uD45C\uC640 \uC791\uC5C5 \uC758\uB3C4\uB97C \uBA85\uD655\uD788 \uD30C\uC545\uD558\uACE0 \uC120\uC5B8\uD558\uC138\uC694.
632
- - **\uC9C0\uC2DD \uAC80\uC0C9**: \uC791\uC5C5\uACFC \uAD00\uB828\uB41C \uBB38\uC11C\uB97C **\uC9C1\uC811 \uBA3C\uC800** \uAC80\uC0C9\uD558\uACE0 \uC77D\uC73C\uC138\uC694.
635
+ - **\uBA54\uD0C0\uB370\uC774\uD130 \uC6B0\uC120 \uAC80\uC0C9**: \uBA3C\uC800 \`search_knowledge\`\uB85C \uAD00\uB828 \uD6C4\uBCF4\uB97C \uCC3E\uACE0, \uBA54\uD0C0\uB370\uC774\uD130\uB97C \uBE44\uAD50\uD55C \uB4A4 \uAC00\uC7A5 \uC720\uB825\uD55C \uB178\uD2B8\uB97C \`read_knowledge\`\uB85C \uC5EC\uC138\uC694.
636
+ - **\uAD00\uB828 \uB178\uD2B8 \uCD94\uC801**: \`read_knowledge\` \uB05D\uC758 related notes \uC139\uC158\uC5D0\uC11C \uC5F0\uACB0\uB41C \uB178\uD2B8\uC758 title / description / tags / path\uB97C \uD655\uC778\uD558\uACE0 \uD544\uC694\uC2DC \uC5F0\uC1C4 \uD0D0\uC0C9\uD558\uC138\uC694.
633
637
  - \uC9C0\uC2DD \uD30C\uC77C\uC5D0 \uAE30\uB85D\uB41C \uC544\uD0A4\uD14D\uCC98 \uACB0\uC815, \uD328\uD134, \uC81C\uC57D\uC0AC\uD56D\uC744 \uBC18\uB4DC\uC2DC \uB530\uB974\uC138\uC694.
634
638
 
635
639
  ### \uAC1C\uBC1C \uC6D0\uCE59
@@ -647,10 +651,63 @@ var STATIC_KNOWLEDGE_CONTEXT = `## Knowledge Context
647
651
  - \uC774 \uD638\uCD9C \uC5C6\uC774 \uC138\uC158\uC744 \uC885\uB8CC\uD558\uBA74 \uC791\uC5C5 \uAE30\uB85D\uC774 \uBCF4\uC874\uB418\uC9C0 \uC54A\uC2B5\uB2C8\uB2E4.
648
652
  - \uD544\uC694\uD55C \uC778\uC790: daily_note_update_proof, knowledge_note_proof, quality_check_output, checkpoint_commit_hashes, scope_review_notes`;
649
653
 
650
- // src/shared/claude-settings.ts
651
- import { existsSync as existsSync6, readFileSync as readFileSync4, writeFileSync as writeFileSync4, renameSync as renameSync2, mkdirSync as mkdirSync4 } from "fs";
652
- import { dirname as dirname4, join as join5 } from "path";
654
+ // src/shared/codex-settings.ts
655
+ import { existsSync as existsSync6, readFileSync as readFileSync4, writeFileSync as writeFileSync4 } from "fs";
653
656
  import { homedir as homedir2 } from "os";
657
+ import { isAbsolute, join as join5 } from "path";
658
+ var STALE_MOCK_MCP_SERVER_NAME = "mock-mcp";
659
+ var codexConfigPath = join5(homedir2(), ".codex", "config.toml");
660
+ function findMcpServerBlockRange(lines, serverName) {
661
+ const header = `[mcp_servers.${serverName}]`;
662
+ const start = lines.findIndex((line) => line.trim() === header);
663
+ if (start === -1) {
664
+ return null;
665
+ }
666
+ let end = lines.length;
667
+ for (let index = start + 1;index < lines.length; index += 1) {
668
+ if (lines[index].startsWith("[")) {
669
+ end = index;
670
+ break;
671
+ }
672
+ }
673
+ return { start, end };
674
+ }
675
+ function resolveFirstArgPath(blockLines) {
676
+ for (const line of blockLines) {
677
+ const match = line.match(/^\s*args\s*=\s*\[\s*["']([^"']+)["']/);
678
+ if (!match) {
679
+ continue;
680
+ }
681
+ return match[1];
682
+ }
683
+ return null;
684
+ }
685
+ function pruneStaleMockMcpServer() {
686
+ if (!existsSync6(codexConfigPath)) {
687
+ return false;
688
+ }
689
+ const content = readFileSync4(codexConfigPath, "utf8");
690
+ const lines = content.split(`
691
+ `);
692
+ const blockRange = findMcpServerBlockRange(lines, STALE_MOCK_MCP_SERVER_NAME);
693
+ if (!blockRange) {
694
+ return false;
695
+ }
696
+ const blockLines = lines.slice(blockRange.start, blockRange.end);
697
+ const firstArgPath = resolveFirstArgPath(blockLines);
698
+ if (!firstArgPath || !isAbsolute(firstArgPath) || existsSync6(firstArgPath)) {
699
+ return false;
700
+ }
701
+ const nextLines = [...lines.slice(0, blockRange.start), ...lines.slice(blockRange.end)];
702
+ writeFileSync4(codexConfigPath, nextLines.join(`
703
+ `), "utf8");
704
+ return true;
705
+ }
706
+
707
+ // src/shared/claude-settings.ts
708
+ import { existsSync as existsSync7, readFileSync as readFileSync5, writeFileSync as writeFileSync5, renameSync as renameSync2, mkdirSync as mkdirSync4 } from "fs";
709
+ import { dirname as dirname4, join as join6 } from "path";
710
+ import { homedir as homedir3 } from "os";
654
711
 
655
712
  // node_modules/jsonc-parser/lib/esm/impl/scanner.js
656
713
  function createScanner(text, ignoreTrivia = false) {
@@ -1978,12 +2035,12 @@ function applyEdits(text, edits) {
1978
2035
  // src/shared/claude-settings.ts
1979
2036
  var CONTEXT_MCP_SERVER_NAME = "context-mcp";
1980
2037
  var LEGACY_CONTEXT_MCP_SERVER_NAME = "context_mcp";
1981
- var settingsPath = join5(homedir2(), ".claude", "settings.json");
2038
+ var settingsPath = join6(homedir3(), ".claude", "settings.json");
1982
2039
  function readClaudeSettings() {
1983
- if (!existsSync6(settingsPath)) {
2040
+ if (!existsSync7(settingsPath)) {
1984
2041
  return {};
1985
2042
  }
1986
- const content = readFileSync4(settingsPath, "utf8");
2043
+ const content = readFileSync5(settingsPath, "utf8");
1987
2044
  return parse2(content) ?? {};
1988
2045
  }
1989
2046
  function hasContextMcpServer(settings) {
@@ -1994,12 +2051,12 @@ function hasContextMcpServer(settings) {
1994
2051
  }
1995
2052
  function writeClaudeSettings(settings) {
1996
2053
  const dir = dirname4(settingsPath);
1997
- if (!existsSync6(dir)) {
2054
+ if (!existsSync7(dir)) {
1998
2055
  mkdirSync4(dir, { recursive: true });
1999
2056
  }
2000
2057
  let content;
2001
- if (existsSync6(settingsPath)) {
2002
- content = readFileSync4(settingsPath, "utf8");
2058
+ if (existsSync7(settingsPath)) {
2059
+ content = readFileSync5(settingsPath, "utf8");
2003
2060
  for (const [key, value] of Object.entries(settings)) {
2004
2061
  const edits = modify(content, [key], value, {});
2005
2062
  content = applyEdits(content, edits);
@@ -2015,7 +2072,7 @@ function writeClaudeSettings(settings) {
2015
2072
  content = JSON.stringify(settings, null, 2);
2016
2073
  }
2017
2074
  const tmp = settingsPath + ".tmp";
2018
- writeFileSync4(tmp, content, "utf8");
2075
+ writeFileSync5(tmp, content, "utf8");
2019
2076
  renameSync2(tmp, settingsPath);
2020
2077
  }
2021
2078
  function removeMcpServer(name) {
@@ -2082,8 +2139,8 @@ function resolveOmxSource() {
2082
2139
  try {
2083
2140
  const cliDir = dirname5(fileURLToPath2(import.meta.url));
2084
2141
  const pkgRoot = resolve2(cliDir, "..", "..");
2085
- const source = join6(pkgRoot, "dist", "omx", "index.mjs");
2086
- if (existsSync7(source))
2142
+ const source = join7(pkgRoot, "dist", "omx", "index.mjs");
2143
+ if (existsSync8(source))
2087
2144
  return source;
2088
2145
  } catch {}
2089
2146
  try {
@@ -2094,31 +2151,35 @@ function resolveOmxSource() {
2094
2151
  }
2095
2152
  }
2096
2153
  function installOmx(projectDir, sourcePath) {
2097
- if (!existsSync7(sourcePath)) {
2154
+ if (!existsSync8(sourcePath)) {
2098
2155
  process.stderr.write(`Could not find OMX plugin source file: ${sourcePath}
2099
2156
  `);
2100
2157
  process.exit(1);
2101
2158
  return;
2102
2159
  }
2103
- const targetDir = join6(projectDir, ".omx", "hooks");
2160
+ const targetDir = join7(projectDir, ".omx", "hooks");
2104
2161
  mkdirSync5(targetDir, { recursive: true });
2105
- copyFileSync(sourcePath, join6(targetDir, "context.mjs"));
2162
+ copyFileSync(sourcePath, join7(targetDir, "context.mjs"));
2106
2163
  process.stdout.write(`Installed context plugin to .omx/hooks/context.mjs
2107
2164
  `);
2108
2165
  if (ensureMcpRegistered()) {
2109
2166
  process.stdout.write(`Successfully registered context-mcp in ~/.omx/mcp-registry.json
2167
+ `);
2168
+ }
2169
+ if (pruneStaleMockMcpServer()) {
2170
+ process.stdout.write(`Removed stale mock-mcp from ~/.codex/config.toml because its target file is missing
2110
2171
  `);
2111
2172
  }
2112
2173
  }
2113
2174
  function installOmc(projectDir) {
2114
2175
  scaffoldIfNeeded(projectDir);
2115
- injectIntoAgentsMd(join6(projectDir, "AGENTS.md"), STATIC_KNOWLEDGE_CONTEXT);
2176
+ injectIntoAgentsMd(join7(projectDir, "AGENTS.md"), STATIC_KNOWLEDGE_CONTEXT);
2116
2177
  let bunPath = "bun";
2117
2178
  try {
2118
2179
  bunPath = execSync2("which bun", { encoding: "utf-8" }).trim();
2119
2180
  } catch {}
2120
2181
  const mcpPath = resolveMcpPath();
2121
- const hookBasePath = join6(dirname5(mcpPath), "omc") + "/";
2182
+ const hookBasePath = join7(dirname5(mcpPath), "omc") + "/";
2122
2183
  removeMcpServer("context_mcp");
2123
2184
  removeMcpServer("context-mcp");
2124
2185
  try {
@@ -2220,7 +2281,7 @@ function runUpdate(args) {
2220
2281
  }
2221
2282
  }
2222
2283
  function isOmxInstalled(projectDir) {
2223
- return existsSync8(join7(projectDir, ".omx", "hooks", "context.mjs"));
2284
+ return existsSync9(join8(projectDir, ".omx", "hooks", "context.mjs"));
2224
2285
  }
2225
2286
  function isOmcInstalled() {
2226
2287
  try {
@@ -2281,20 +2342,20 @@ OMX plugin is not installed for this project; skipping omx reinstall.
2281
2342
  `);
2282
2343
  }
2283
2344
  function detectPackageManager() {
2284
- if (existsSync8("bun.lock") || existsSync8("bun.lockb"))
2345
+ if (existsSync9("bun.lock") || existsSync9("bun.lockb"))
2285
2346
  return "bun";
2286
- if (existsSync8("pnpm-lock.yaml"))
2347
+ if (existsSync9("pnpm-lock.yaml"))
2287
2348
  return "pnpm";
2288
- if (existsSync8("yarn.lock"))
2349
+ if (existsSync9("yarn.lock"))
2289
2350
  return "yarn";
2290
- if (existsSync8("package-lock.json"))
2351
+ if (existsSync9("package-lock.json"))
2291
2352
  return "npm";
2292
2353
  return "bun";
2293
2354
  }
2294
2355
  function detectGlobalInstalls() {
2295
2356
  const installs = [];
2296
- const bunGlobalBin = join7(homedir3(), ".bun", "bin", "context");
2297
- if (existsSync8(bunGlobalBin)) {
2357
+ const bunGlobalBin = join8(homedir4(), ".bun", "bin", "context");
2358
+ if (existsSync9(bunGlobalBin)) {
2298
2359
  installs.push({ pm: "bun", label: "bun global", installCmd: ["bun", "install", "-g"] });
2299
2360
  }
2300
2361
  const spawnSync = globalThis.Bun?.spawnSync;
@@ -2347,22 +2408,22 @@ function runUpdatePlugin(version) {
2347
2408
  }
2348
2409
 
2349
2410
  // src/cli/commands/migrate.ts
2350
- import { resolve as resolve4, join as join8 } from "path";
2351
- import { existsSync as existsSync9, cpSync, rmSync, readFileSync as readFileSync5, writeFileSync as writeFileSync5 } from "fs";
2411
+ import { resolve as resolve4, join as join9 } from "path";
2412
+ import { existsSync as existsSync10, cpSync, rmSync, readFileSync as readFileSync6, writeFileSync as writeFileSync6 } from "fs";
2352
2413
  var LEGACY_CONTEXT_DIR = ".opencode/context";
2353
2414
  var NEW_CONTEXT_DIR = ".context";
2354
2415
  function runMigrate(args) {
2355
2416
  const keepFlag = args.includes("--keep");
2356
2417
  const pathArg = args.find((a) => !a.startsWith("--"));
2357
2418
  const projectDir = resolve4(pathArg ?? process.cwd());
2358
- const legacyDir = join8(projectDir, LEGACY_CONTEXT_DIR);
2359
- const newDir = join8(projectDir, NEW_CONTEXT_DIR);
2360
- if (!existsSync9(legacyDir)) {
2419
+ const legacyDir = join9(projectDir, LEGACY_CONTEXT_DIR);
2420
+ const newDir = join9(projectDir, NEW_CONTEXT_DIR);
2421
+ if (!existsSync10(legacyDir)) {
2361
2422
  process.stdout.write(`Nothing to migrate.
2362
2423
  `);
2363
2424
  return;
2364
2425
  }
2365
- if (existsSync9(newDir)) {
2426
+ if (existsSync10(newDir)) {
2366
2427
  process.stderr.write(`Target .context/ already exists. Aborting.
2367
2428
  `);
2368
2429
  process.exit(1);
@@ -2377,14 +2438,14 @@ function runMigrate(args) {
2377
2438
  `);
2378
2439
  }
2379
2440
  function updateConfigPaths(contextDir) {
2380
- const configPath = join8(contextDir, "config.jsonc");
2381
- if (!existsSync9(configPath))
2441
+ const configPath = join9(contextDir, "config.jsonc");
2442
+ if (!existsSync10(configPath))
2382
2443
  return;
2383
2444
  try {
2384
- const content = readFileSync5(configPath, "utf-8");
2445
+ const content = readFileSync6(configPath, "utf-8");
2385
2446
  const updated = content.replaceAll(".opencode/context/", "");
2386
2447
  if (updated !== content) {
2387
- writeFileSync5(configPath, updated, "utf-8");
2448
+ writeFileSync6(configPath, updated, "utf-8");
2388
2449
  }
2389
2450
  } catch {}
2390
2451
  }
package/dist/index.js CHANGED
@@ -25,7 +25,7 @@ import { join as join2 } from "path";
25
25
  // package.json
26
26
  var package_default = {
27
27
  name: "@ksm0709/context",
28
- version: "0.0.34",
28
+ version: "0.0.36",
29
29
  author: {
30
30
  name: "TaehoKang",
31
31
  email: "ksm07091@gmail.com"
@@ -67,24 +67,23 @@ var package_default = {
67
67
  "@opencode-ai/plugin": ">=1.0.0"
68
68
  },
69
69
  dependencies: {
70
- "@ksm0709/context": "^0.0.33",
71
70
  "@modelcontextprotocol/sdk": "^1.27.1",
72
71
  "jsonc-parser": "^3.0.0"
73
72
  },
74
73
  devDependencies: {
75
- "@opencode-ai/plugin": "^1.2.10",
76
74
  "@eslint/js": "^9.39.1",
75
+ "@opencode-ai/plugin": "^1.2.10",
77
76
  "@types/node": "^20.11.5",
78
77
  "@typescript-eslint/eslint-plugin": "8.47.0",
79
78
  "@typescript-eslint/parser": "8.47.0",
79
+ "@vitest/coverage-v8": "^3.2.4",
80
80
  "bun-types": "latest",
81
81
  eslint: "^9.39.1",
82
82
  "eslint-config-prettier": "10.1.8",
83
83
  "eslint-plugin-prettier": "^5.1.3",
84
84
  prettier: "^3.2.4",
85
85
  "typescript-eslint": "^8.47.0",
86
- vitest: "^3.2.4",
87
- "@vitest/coverage-v8": "^3.2.4"
86
+ vitest: "^3.2.4"
88
87
  }
89
88
  };
90
89
 
@@ -324,6 +323,8 @@ var DEFAULT_DAILY_NOTE_GUIDE = `# \uB370\uC77C\uB9AC \uB178\uD2B8 \uAE30\uB85D \
324
323
  var DEFAULT_NOTE_GUIDE = `# \uC9C0\uC2DD \uB178\uD2B8 \uC791\uC131 \uBC0F \uAD00\uB9AC \uAC00\uC774\uB4DC
325
324
 
326
325
  - [ ] **\uB178\uD2B8 \uC0DD\uC131**: \`context_mcp_create_knowledge_note\` \uB3C4\uAD6C\uB97C \uC0AC\uC6A9\uD558\uC5EC \uC0DD\uC131\uD558\uC138\uC694.
326
+ - [ ] \uD15C\uD50C\uB9BF \uBAA8\uB4DC\uC5D0\uC11C\uB294 \uBA3C\uC800 \`.context/templates/<template>.md\`\uB97C \uC77D\uACE0, **\uC644\uC131\uB41C markdown \uC804\uCCB4**\uB97C \`content\`\uB85C \uC804\uB2EC\uD558\uC138\uC694.
327
+ - [ ] \uD15C\uD50C\uB9BF \uBAA8\uB4DC\uC5D0\uC11C\uB294 \`tags\`/\`linked_notes\`\uB97C \uB530\uB85C \uB118\uAE30\uC9C0 \uB9C8\uC138\uC694. \uAD00\uB828 \uB178\uD2B8\uC640 \uBA54\uD0C0\uB370\uC774\uD130\uB294 markdown \uBCF8\uBB38\uC5D0 \uC9C1\uC811 \uC791\uC131\uD574\uC57C \uD569\uB2C8\uB2E4.
327
328
  - [ ] \uC81C\uD154\uCE74\uC2A4\uD150(Zettelkasten) 3\uB300 \uC6D0\uCE59 \uC900\uC218:
328
329
  - [ ] \uC6D0\uC790\uC131: \uD55C \uB178\uD2B8\uB2F9 \uD55C \uC8FC\uC81C
329
330
  - [ ] \uC5F0\uACB0: \uACE0\uB9BD\uB41C \uB178\uD2B8 \uBC29\uC9C0