diff --git a/src/shared/config-path.ts b/src/shared/config-path.ts deleted file mode 100644 index b2eba27dc..000000000 --- a/src/shared/config-path.ts +++ /dev/null @@ -1,43 +0,0 @@ -import * as path from "path" -import * as os from "os" -import * as fs from "fs" - -/** - * Returns the user-level config directory based on the OS. - * @deprecated Use getOpenCodeConfigDir() from opencode-config-dir.ts instead. - */ -export function getUserConfigDir(): string { - if (process.platform === "win32") { - const crossPlatformDir = path.join(os.homedir(), ".config") - const crossPlatformConfigPath = path.join(crossPlatformDir, "opencode", "oh-my-opencode.json") - - const appdataDir = process.env.APPDATA || path.join(os.homedir(), "AppData", "Roaming") - const appdataConfigPath = path.join(appdataDir, "opencode", "oh-my-opencode.json") - - if (fs.existsSync(crossPlatformConfigPath)) { - return crossPlatformDir - } - - if (fs.existsSync(appdataConfigPath)) { - return appdataDir - } - - return crossPlatformDir - } - - return process.env.XDG_CONFIG_HOME || path.join(os.homedir(), ".config") -} - -/** - * Returns the full path to the user-level oh-my-opencode config file. - */ -export function getUserConfigPath(): string { - return path.join(getUserConfigDir(), "opencode", "oh-my-opencode.json") -} - -/** - * Returns the full path to the project-level oh-my-opencode config file. - */ -export function getProjectConfigPath(directory: string): string { - return path.join(directory, ".opencode", "oh-my-opencode.json") -} diff --git a/src/shared/index.ts b/src/shared/index.ts index 8efa978fa..759fcd406 100644 --- a/src/shared/index.ts +++ b/src/shared/index.ts @@ -10,7 +10,6 @@ export * from "./hook-disabled" export * from "./deep-merge" export * from "./file-utils" export * from "./dynamic-truncator" -export * from "./config-path" export * from "./data-path" export * from "./config-errors" export * from "./claude-config-dir"