oh-my-opencode 3.5.2 → 3.5.4

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 (81) hide show
  1. package/README.md +3 -3
  2. package/dist/agents/builtin-agents/agent-overrides.d.ts +2 -2
  3. package/dist/agents/builtin-agents/atlas-agent.d.ts +1 -0
  4. package/dist/agents/builtin-agents/resolve-file-uri.d.ts +1 -0
  5. package/dist/cli/doctor/checks/config.d.ts +2 -8
  6. package/dist/cli/doctor/checks/dependencies.d.ts +1 -5
  7. package/dist/cli/doctor/checks/index.d.ts +4 -16
  8. package/dist/cli/doctor/checks/model-resolution.d.ts +4 -4
  9. package/dist/cli/doctor/checks/{opencode.d.ts → system-binary.d.ts} +6 -12
  10. package/dist/cli/doctor/checks/system-loaded-version.d.ts +9 -0
  11. package/dist/cli/doctor/checks/system-plugin.d.ts +15 -0
  12. package/dist/cli/doctor/checks/system.d.ts +3 -0
  13. package/dist/cli/doctor/checks/{gh.d.ts → tools-gh.d.ts} +0 -3
  14. package/dist/cli/doctor/checks/tools-lsp.d.ts +6 -0
  15. package/dist/cli/doctor/checks/tools-mcp.d.ts +3 -0
  16. package/dist/cli/doctor/checks/tools.d.ts +3 -0
  17. package/dist/cli/doctor/constants.d.ts +4 -17
  18. package/dist/cli/doctor/format-default.d.ts +2 -0
  19. package/dist/cli/doctor/format-shared.d.ts +6 -0
  20. package/dist/cli/doctor/format-status.d.ts +2 -0
  21. package/dist/cli/doctor/format-verbose.d.ts +2 -0
  22. package/dist/cli/doctor/formatter.d.ts +2 -11
  23. package/dist/cli/doctor/index.d.ts +1 -1
  24. package/dist/cli/doctor/runner.d.ts +1 -3
  25. package/dist/cli/doctor/types.d.ts +39 -6
  26. package/dist/cli/index.js +959 -1138
  27. package/dist/cli/run/poll-for-completion.d.ts +1 -0
  28. package/dist/cli/run/runner.d.ts +1 -0
  29. package/dist/config/schema/background-task.d.ts +1 -0
  30. package/dist/config/schema/hooks.d.ts +0 -1
  31. package/dist/config/schema/oh-my-opencode-config.d.ts +11 -11
  32. package/dist/config/schema/skills.d.ts +10 -10
  33. package/dist/create-hooks.d.ts +0 -1
  34. package/dist/features/background-agent/background-event-handler.d.ts +1 -0
  35. package/dist/features/background-agent/constants.d.ts +1 -0
  36. package/dist/features/background-agent/index.d.ts +1 -0
  37. package/dist/features/background-agent/manager.d.ts +4 -0
  38. package/dist/features/background-agent/poll-running-tasks.d.ts +3 -1
  39. package/dist/features/background-agent/session-idle-event-handler.d.ts +10 -0
  40. package/dist/features/background-agent/session-task-cleanup.d.ts +10 -0
  41. package/dist/features/background-agent/stale-task-pruner.d.ts +7 -1
  42. package/dist/features/background-agent/task-history.d.ts +18 -0
  43. package/dist/features/background-agent/task-poller.d.ts +4 -0
  44. package/dist/features/background-agent/types.d.ts +4 -0
  45. package/dist/features/claude-code-agent-loader/loader.d.ts +1 -1
  46. package/dist/features/claude-code-command-loader/loader.d.ts +3 -3
  47. package/dist/features/opencode-skill-loader/config-source-discovery.d.ts +7 -0
  48. package/dist/features/opencode-skill-loader/index.d.ts +1 -0
  49. package/dist/features/opencode-skill-loader/loader.d.ts +8 -5
  50. package/dist/features/opencode-skill-loader/merger.d.ts +1 -1
  51. package/dist/features/opencode-skill-loader/skill-resolution-options.d.ts +2 -0
  52. package/dist/features/tmux-subagent/grid-planning.d.ts +1 -1
  53. package/dist/features/tmux-subagent/pane-split-availability.d.ts +3 -3
  54. package/dist/features/tmux-subagent/spawn-action-decider.d.ts +1 -1
  55. package/dist/hooks/claude-code-hooks/transcript.d.ts +8 -13
  56. package/dist/hooks/compaction-context-injector/hook.d.ts +2 -1
  57. package/dist/hooks/index.d.ts +0 -1
  58. package/dist/hooks/keyword-detector/ultrawork/source-detector.d.ts +2 -5
  59. package/dist/hooks/prometheus-md-only/agent-matcher.d.ts +1 -0
  60. package/dist/hooks/think-mode/switcher.d.ts +1 -2
  61. package/dist/hooks/todo-continuation-enforcer/constants.d.ts +1 -0
  62. package/dist/hooks/todo-continuation-enforcer/session-state.d.ts +1 -0
  63. package/dist/hooks/todo-continuation-enforcer/types.d.ts +2 -0
  64. package/dist/index.js +2043 -1425
  65. package/dist/plugin/hooks/create-core-hooks.d.ts +0 -1
  66. package/dist/plugin/hooks/create-session-hooks.d.ts +1 -2
  67. package/dist/plugin/session-agent-resolver.d.ts +19 -0
  68. package/dist/plugin-config.d.ts +1 -0
  69. package/dist/plugin-handlers/command-config-handler.d.ts +3 -0
  70. package/dist/shared/session-tools-store.d.ts +3 -0
  71. package/dist/tools/call-omo-agent/sync-executor.d.ts +10 -1
  72. package/dist/tools/slashcommand/command-discovery.d.ts +1 -1
  73. package/package.json +8 -8
  74. package/dist/cli/doctor/checks/auth.d.ts +0 -7
  75. package/dist/cli/doctor/checks/lsp.d.ts +0 -8
  76. package/dist/cli/doctor/checks/mcp-oauth.d.ts +0 -15
  77. package/dist/cli/doctor/checks/mcp.d.ts +0 -6
  78. package/dist/cli/doctor/checks/plugin.d.ts +0 -4
  79. package/dist/cli/doctor/checks/version.d.ts +0 -4
  80. package/dist/hooks/subagent-question-blocker/hook.d.ts +0 -2
  81. package/dist/hooks/subagent-question-blocker/index.d.ts +0 -1
package/README.md CHANGED
@@ -280,10 +280,10 @@ To remove oh-my-opencode:
280
280
 
281
281
  ```bash
282
282
  # Remove user config
283
- rm -f ~/.config/opencode/oh-my-opencode.json
283
+ rm -f ~/.config/opencode/oh-my-opencode.json ~/.config/opencode/oh-my-opencode.jsonc
284
284
 
285
285
  # Remove project config (if exists)
286
- rm -f .opencode/oh-my-opencode.json
286
+ rm -f .opencode/oh-my-opencode.json .opencode/oh-my-opencode.jsonc
287
287
  ```
288
288
 
289
289
  3. **Verify removal**
@@ -314,7 +314,7 @@ Highly opinionated, but adjustable to taste.
314
314
  See the full [Configuration Documentation](docs/configurations.md) for detailed information.
315
315
 
316
316
  **Quick Overview:**
317
- - **Config Locations**: `.opencode/oh-my-opencode.json` (project) or `~/.config/opencode/oh-my-opencode.json` (user)
317
+ - **Config Locations**: `.opencode/oh-my-opencode.jsonc` or `.opencode/oh-my-opencode.json` (project), `~/.config/opencode/oh-my-opencode.jsonc` or `~/.config/opencode/oh-my-opencode.json` (user)
318
318
  - **JSONC Support**: Comments and trailing commas supported
319
319
  - **Agents**: Override models, temperatures, prompts, and permissions for any agent
320
320
  - **Built-in Skills**: `playwright` (browser automation), `git-master` (atomic commits)
@@ -8,5 +8,5 @@ import type { CategoryConfig } from "../../config/schema";
8
8
  * Direct override properties applied later via mergeAgentConfig() will supersede these.
9
9
  */
10
10
  export declare function applyCategoryOverride(config: AgentConfig, categoryName: string, mergedCategories: Record<string, CategoryConfig>): AgentConfig;
11
- export declare function mergeAgentConfig(base: AgentConfig, override: AgentOverrideConfig): AgentConfig;
12
- export declare function applyOverrides(config: AgentConfig, override: AgentOverrideConfig | undefined, mergedCategories: Record<string, CategoryConfig>): AgentConfig;
11
+ export declare function mergeAgentConfig(base: AgentConfig, override: AgentOverrideConfig, directory?: string): AgentConfig;
12
+ export declare function applyOverrides(config: AgentConfig, override: AgentOverrideConfig | undefined, mergedCategories: Record<string, CategoryConfig>, directory?: string): AgentConfig;
@@ -11,6 +11,7 @@ export declare function maybeCreateAtlasConfig(input: {
11
11
  availableAgents: AvailableAgent[];
12
12
  availableSkills: AvailableSkill[];
13
13
  mergedCategories: Record<string, CategoryConfig>;
14
+ directory?: string;
14
15
  userCategories?: CategoriesConfig;
15
16
  useTaskSystem?: boolean;
16
17
  }): AgentConfig | undefined;
@@ -0,0 +1 @@
1
+ export declare function resolvePromptAppend(promptAppend: string, configDir?: string): string;
@@ -1,8 +1,2 @@
1
- import type { CheckResult, CheckDefinition, ConfigInfo } from "../types";
2
- export declare function validateConfig(configPath: string): {
3
- valid: boolean;
4
- errors: string[];
5
- };
6
- export declare function getConfigInfo(): ConfigInfo;
7
- export declare function checkConfigValidity(): Promise<CheckResult>;
8
- export declare function getConfigCheckDefinition(): CheckDefinition;
1
+ import type { CheckResult } from "../types";
2
+ export declare function checkConfig(): Promise<CheckResult>;
@@ -1,8 +1,4 @@
1
- import type { CheckResult, CheckDefinition, DependencyInfo } from "../types";
1
+ import type { DependencyInfo } from "../types";
2
2
  export declare function checkAstGrepCli(): Promise<DependencyInfo>;
3
3
  export declare function checkAstGrepNapi(): Promise<DependencyInfo>;
4
4
  export declare function checkCommentChecker(): Promise<DependencyInfo>;
5
- export declare function checkDependencyAstGrepCli(): Promise<CheckResult>;
6
- export declare function checkDependencyAstGrepNapi(): Promise<CheckResult>;
7
- export declare function checkDependencyCommentChecker(): Promise<CheckResult>;
8
- export declare function getDependencyCheckDefinitions(): CheckDefinition[];
@@ -1,19 +1,7 @@
1
1
  import type { CheckDefinition } from "../types";
2
- export * from "./opencode";
3
- export * from "./plugin";
4
- export * from "./config";
5
- export * from "./model-resolution";
2
+ import { gatherSystemInfo } from "./system";
3
+ import { gatherToolsSummary } from "./tools";
4
+ export type { CheckDefinition };
6
5
  export * from "./model-resolution-types";
7
- export * from "./model-resolution-cache";
8
- export * from "./model-resolution-config";
9
- export * from "./model-resolution-effective-model";
10
- export * from "./model-resolution-variant";
11
- export * from "./model-resolution-details";
12
- export * from "./auth";
13
- export * from "./dependencies";
14
- export * from "./gh";
15
- export * from "./lsp";
16
- export * from "./mcp";
17
- export * from "./mcp-oauth";
18
- export * from "./version";
6
+ export { gatherSystemInfo, gatherToolsSummary };
19
7
  export declare function getAllCheckDefinitions(): CheckDefinition[];
@@ -1,6 +1,6 @@
1
- import type { CheckResult, CheckDefinition } from "../types";
2
- import type { OmoConfig, ModelResolutionInfo } from "./model-resolution-types";
1
+ import type { CheckResult } from "../types";
2
+ import type { ModelResolutionInfo, OmoConfig } from "./model-resolution-types";
3
3
  export declare function getModelResolutionInfo(): ModelResolutionInfo;
4
4
  export declare function getModelResolutionInfoWithOverrides(config: OmoConfig): ModelResolutionInfo;
5
- export declare function checkModelResolution(): Promise<CheckResult>;
6
- export declare function getModelResolutionCheckDefinition(): CheckDefinition;
5
+ export declare function checkModels(): Promise<CheckResult>;
6
+ export declare const checkModelResolution: typeof checkModels;
@@ -1,19 +1,13 @@
1
- import type { CheckResult, CheckDefinition, OpenCodeInfo } from "../types";
1
+ export interface OpenCodeBinaryInfo {
2
+ binary: string;
3
+ path: string;
4
+ }
2
5
  export declare function getDesktopAppPaths(platform: NodeJS.Platform): string[];
3
6
  export declare function getBinaryLookupCommand(platform: NodeJS.Platform): "which" | "where";
4
7
  export declare function parseBinaryPaths(output: string): string[];
5
8
  export declare function selectBinaryPath(paths: string[], platform: NodeJS.Platform): string | null;
6
9
  export declare function buildVersionCommand(binaryPath: string, platform: NodeJS.Platform): string[];
7
- export declare function findDesktopBinary(platform?: NodeJS.Platform, checkExists?: (path: string) => boolean): {
8
- binary: string;
9
- path: string;
10
- } | null;
11
- export declare function findOpenCodeBinary(): Promise<{
12
- binary: string;
13
- path: string;
14
- } | null>;
10
+ export declare function findDesktopBinary(platform?: NodeJS.Platform, checkExists?: (path: string) => boolean): OpenCodeBinaryInfo | null;
11
+ export declare function findOpenCodeBinary(): Promise<OpenCodeBinaryInfo | null>;
15
12
  export declare function getOpenCodeVersion(binaryPath: string, platform?: NodeJS.Platform): Promise<string | null>;
16
13
  export declare function compareVersions(current: string, minimum: string): boolean;
17
- export declare function getOpenCodeInfo(): Promise<OpenCodeInfo>;
18
- export declare function checkOpenCodeInstallation(): Promise<CheckResult>;
19
- export declare function getOpenCodeCheckDefinition(): CheckDefinition;
@@ -0,0 +1,9 @@
1
+ export interface LoadedVersionInfo {
2
+ cacheDir: string;
3
+ cachePackagePath: string;
4
+ installedPackagePath: string;
5
+ expectedVersion: string | null;
6
+ loadedVersion: string | null;
7
+ }
8
+ export declare function getLoadedPluginVersion(): LoadedVersionInfo;
9
+ export declare function getLatestPluginVersion(currentVersion: string | null): Promise<string | null>;
@@ -0,0 +1,15 @@
1
+ export interface PluginInfo {
2
+ registered: boolean;
3
+ configPath: string | null;
4
+ entry: string | null;
5
+ isPinned: boolean;
6
+ pinnedVersion: string | null;
7
+ isLocalDev: boolean;
8
+ }
9
+ declare function detectConfigPath(): string | null;
10
+ declare function findPluginEntry(entries: string[]): {
11
+ entry: string;
12
+ isLocalDev: boolean;
13
+ } | null;
14
+ export declare function getPluginInfo(): PluginInfo;
15
+ export { detectConfigPath, findPluginEntry };
@@ -0,0 +1,3 @@
1
+ import type { CheckResult, SystemInfo } from "../types";
2
+ export declare function gatherSystemInfo(): Promise<SystemInfo>;
3
+ export declare function checkSystem(): Promise<CheckResult>;
@@ -1,4 +1,3 @@
1
- import type { CheckResult, CheckDefinition } from "../types";
2
1
  export interface GhCliInfo {
3
2
  installed: boolean;
4
3
  version: string | null;
@@ -9,5 +8,3 @@ export interface GhCliInfo {
9
8
  error: string | null;
10
9
  }
11
10
  export declare function getGhCliInfo(): Promise<GhCliInfo>;
12
- export declare function checkGhCli(): Promise<CheckResult>;
13
- export declare function getGhCliCheckDefinition(): CheckDefinition;
@@ -0,0 +1,6 @@
1
+ import type { LspServerInfo } from "../types";
2
+ export declare function getLspServersInfo(): LspServerInfo[];
3
+ export declare function getLspServerStats(servers: LspServerInfo[]): {
4
+ installed: number;
5
+ total: number;
6
+ };
@@ -0,0 +1,3 @@
1
+ import type { McpServerInfo } from "../types";
2
+ export declare function getBuiltinMcpInfo(): McpServerInfo[];
3
+ export declare function getUserMcpInfo(): McpServerInfo[];
@@ -0,0 +1,3 @@
1
+ import type { CheckResult, ToolsSummary } from "../types";
2
+ export declare function gatherToolsSummary(): Promise<ToolsSummary>;
3
+ export declare function checkTools(): Promise<CheckResult>;
@@ -14,25 +14,12 @@ export declare const STATUS_COLORS: {
14
14
  readonly skip: import("picocolors/types").Formatter;
15
15
  };
16
16
  export declare const CHECK_IDS: {
17
- readonly OPENCODE_INSTALLATION: "opencode-installation";
18
- readonly PLUGIN_REGISTRATION: "plugin-registration";
19
- readonly CONFIG_VALIDATION: "config-validation";
20
- readonly MODEL_RESOLUTION: "model-resolution";
21
- readonly AUTH_ANTHROPIC: "auth-anthropic";
22
- readonly AUTH_OPENAI: "auth-openai";
23
- readonly AUTH_GOOGLE: "auth-google";
24
- readonly DEP_AST_GREP_CLI: "dep-ast-grep-cli";
25
- readonly DEP_AST_GREP_NAPI: "dep-ast-grep-napi";
26
- readonly DEP_COMMENT_CHECKER: "dep-comment-checker";
27
- readonly GH_CLI: "gh-cli";
28
- readonly LSP_SERVERS: "lsp-servers";
29
- readonly MCP_BUILTIN: "mcp-builtin";
30
- readonly MCP_USER: "mcp-user";
31
- readonly MCP_OAUTH_TOKENS: "mcp-oauth-tokens";
32
- readonly VERSION_STATUS: "version-status";
17
+ readonly SYSTEM: "system";
18
+ readonly CONFIG: "config";
19
+ readonly TOOLS: "tools";
20
+ readonly MODELS: "models";
33
21
  };
34
22
  export declare const CHECK_NAMES: Record<string, string>;
35
- export declare const CATEGORY_NAMES: Record<string, string>;
36
23
  export declare const EXIT_CODES: {
37
24
  readonly SUCCESS: 0;
38
25
  readonly FAILURE: 1;
@@ -0,0 +1,2 @@
1
+ import type { DoctorResult } from "./types";
2
+ export declare function formatDefault(result: DoctorResult): string;
@@ -0,0 +1,6 @@
1
+ import type { CheckStatus, DoctorIssue } from "./types";
2
+ export declare function formatStatusSymbol(status: CheckStatus): string;
3
+ export declare function formatStatusMark(available: boolean): string;
4
+ export declare function stripAnsi(str: string): string;
5
+ export declare function formatHeader(): string;
6
+ export declare function formatIssue(issue: DoctorIssue, index: number): string;
@@ -0,0 +1,2 @@
1
+ import type { DoctorResult } from "./types";
2
+ export declare function formatStatus(result: DoctorResult): string;
@@ -0,0 +1,2 @@
1
+ import type { DoctorResult } from "./types";
2
+ export declare function formatVerbose(result: DoctorResult): string;
@@ -1,12 +1,3 @@
1
- import type { CheckResult, DoctorSummary, CheckCategory, DoctorResult } from "./types";
2
- export declare function formatStatusSymbol(status: CheckResult["status"]): string;
3
- export declare function formatCheckResult(result: CheckResult, verbose: boolean): string;
4
- export declare function formatCategoryHeader(category: CheckCategory): string;
5
- export declare function formatSummary(summary: DoctorSummary): string;
6
- export declare function formatHeader(): string;
7
- export declare function formatFooter(summary: DoctorSummary): string;
8
- export declare function formatProgress(current: number, total: number, name: string): string;
1
+ import type { DoctorResult, DoctorMode } from "./types";
2
+ export declare function formatDoctorOutput(result: DoctorResult, mode: DoctorMode): string;
9
3
  export declare function formatJsonOutput(result: DoctorResult): string;
10
- export declare function formatDetails(details: string[]): string;
11
- export declare function formatBox(content: string, title?: string): string;
12
- export declare function formatHelpSuggestions(results: CheckResult[]): string[];
@@ -2,4 +2,4 @@ import type { DoctorOptions } from "./types";
2
2
  export declare function doctor(options?: DoctorOptions): Promise<number>;
3
3
  export * from "./types";
4
4
  export { runDoctor } from "./runner";
5
- export { formatJsonOutput } from "./formatter";
5
+ export { formatDoctorOutput, formatJsonOutput } from "./formatter";
@@ -1,7 +1,5 @@
1
- import type { DoctorOptions, DoctorResult, CheckDefinition, CheckResult, DoctorSummary, CheckCategory } from "./types";
1
+ import type { DoctorOptions, DoctorResult, CheckDefinition, CheckResult, DoctorSummary } from "./types";
2
2
  export declare function runCheck(check: CheckDefinition): Promise<CheckResult>;
3
3
  export declare function calculateSummary(results: CheckResult[], duration: number): DoctorSummary;
4
4
  export declare function determineExitCode(results: CheckResult[]): number;
5
- export declare function filterChecksByCategory(checks: CheckDefinition[], category?: CheckCategory): CheckDefinition[];
6
- export declare function groupChecksByCategory(checks: CheckDefinition[]): Map<CheckCategory, CheckDefinition[]>;
7
5
  export declare function runDoctor(options: DoctorOptions): Promise<DoctorResult>;
@@ -1,24 +1,54 @@
1
+ export type DoctorMode = "default" | "status" | "verbose";
2
+ export interface DoctorOptions {
3
+ mode: DoctorMode;
4
+ json?: boolean;
5
+ }
6
+ export interface DoctorIssue {
7
+ title: string;
8
+ description: string;
9
+ fix?: string;
10
+ affects?: string[];
11
+ severity: "error" | "warning";
12
+ }
1
13
  export type CheckStatus = "pass" | "fail" | "warn" | "skip";
2
14
  export interface CheckResult {
3
15
  name: string;
4
16
  status: CheckStatus;
5
17
  message: string;
6
18
  details?: string[];
19
+ issues: DoctorIssue[];
7
20
  duration?: number;
8
21
  }
9
22
  export type CheckFunction = () => Promise<CheckResult>;
10
- export type CheckCategory = "installation" | "configuration" | "authentication" | "dependencies" | "tools" | "updates";
11
23
  export interface CheckDefinition {
12
24
  id: string;
13
25
  name: string;
14
- category: CheckCategory;
15
26
  check: CheckFunction;
16
27
  critical?: boolean;
17
28
  }
18
- export interface DoctorOptions {
19
- verbose?: boolean;
20
- json?: boolean;
21
- category?: CheckCategory;
29
+ export interface SystemInfo {
30
+ opencodeVersion: string | null;
31
+ opencodePath: string | null;
32
+ pluginVersion: string | null;
33
+ loadedVersion: string | null;
34
+ bunVersion: string | null;
35
+ configPath: string | null;
36
+ configValid: boolean;
37
+ isLocalDev: boolean;
38
+ }
39
+ export interface ToolsSummary {
40
+ lspInstalled: number;
41
+ lspTotal: number;
42
+ astGrepCli: boolean;
43
+ astGrepNapi: boolean;
44
+ commentChecker: boolean;
45
+ ghCli: {
46
+ installed: boolean;
47
+ authenticated: boolean;
48
+ username: string | null;
49
+ };
50
+ mcpBuiltin: string[];
51
+ mcpUser: string[];
22
52
  }
23
53
  export interface DoctorSummary {
24
54
  total: number;
@@ -30,9 +60,12 @@ export interface DoctorSummary {
30
60
  }
31
61
  export interface DoctorResult {
32
62
  results: CheckResult[];
63
+ systemInfo: SystemInfo;
64
+ tools: ToolsSummary;
33
65
  summary: DoctorSummary;
34
66
  exitCode: number;
35
67
  }
68
+ export type CheckCategory = "installation" | "configuration" | "authentication" | "dependencies" | "tools" | "updates";
36
69
  export interface OpenCodeInfo {
37
70
  installed: boolean;
38
71
  version: string | null;