test(skill): stabilize command discovery spy
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
@@ -7,7 +7,7 @@ import type { SkillArgs, SkillLoadOptions } from "./types"
|
|||||||
import type { LoadedSkill } from "../../features/opencode-skill-loader"
|
import type { LoadedSkill } from "../../features/opencode-skill-loader"
|
||||||
import { clearSkillCache, getAllSkills } from "../../features/opencode-skill-loader/skill-content"
|
import { clearSkillCache, getAllSkills } from "../../features/opencode-skill-loader/skill-content"
|
||||||
import { injectGitMasterConfig } from "../../features/opencode-skill-loader/skill-content"
|
import { injectGitMasterConfig } from "../../features/opencode-skill-loader/skill-content"
|
||||||
import { discoverCommandsSync } from "../slashcommand/command-discovery"
|
import * as commandDiscovery from "../slashcommand/command-discovery"
|
||||||
import type { CommandInfo } from "../slashcommand/types"
|
import type { CommandInfo } from "../slashcommand/types"
|
||||||
import { formatLoadedCommand } from "../slashcommand/command-output-formatter"
|
import { formatLoadedCommand } from "../slashcommand/command-output-formatter"
|
||||||
import { formatCombinedDescription } from "./description-formatter"
|
import { formatCombinedDescription } from "./description-formatter"
|
||||||
@@ -51,7 +51,7 @@ export function createSkillTool(options: SkillLoadOptions = {}): ToolDefinition
|
|||||||
}
|
}
|
||||||
|
|
||||||
const getCommands = (): CommandInfo[] => {
|
const getCommands = (): CommandInfo[] => {
|
||||||
return discoverCommandsSync(undefined, {
|
return commandDiscovery.discoverCommandsSync(undefined, {
|
||||||
pluginsEnabled: options.pluginsEnabled,
|
pluginsEnabled: options.pluginsEnabled,
|
||||||
enabledPluginsOverride: options.enabledPluginsOverride,
|
enabledPluginsOverride: options.enabledPluginsOverride,
|
||||||
}) ?? []
|
}) ?? []
|
||||||
|
|||||||
Reference in New Issue
Block a user