feat(coding-agent): replaced smol-toml with native Bun.TOML.parse

- Replaced `smol-toml` dependency with native `Bun.TOML.parse()` for TOML parsing, reducing external dependencies.
- Removed `smol-toml` from package.json dependencies.
This commit is contained in:
can1357
2026-02-28 06:11:02 +01:00
parent 6746ddffd8
commit c9bf2d4d5b
3 changed files with 3 additions and 4 deletions
+1 -2
View File
@@ -8,7 +8,6 @@
*/
import * as path from "node:path";
import { logger } from "@oh-my-pi/pi-utils";
import { parse as parseToml } from "smol-toml";
import { registerProvider } from "../capability";
import type { ContextFile } from "../capability/context-file";
import { contextFileCapability } from "../capability/context-file";
@@ -116,7 +115,7 @@ async function loadTomlConfig(_ctx: LoadContext, path: string): Promise<Record<s
if (!content) return null;
try {
return parseToml(content) as Record<string, unknown>;
return Bun.TOML.parse(content) as Record<string, unknown>;
} catch (error) {
logger.warn("Failed to parse TOML config", { path, error: String(error) });
return null;