Skip to content

Commit 337d95f

Browse files
committed
Remove redundant executable property from coding agents and use cmd instead
- we notices some redundancy in cmd/executable keys └── apps └── editor └── src └── features └── search-files └── search-modes └── perform-agent-search-mode ├── agents │ ├── antigravity.ts │ ├── claude.ts │ ├── codex.ts │ └── opencode.ts ├── index.ts ├── types.ts └── utils.ts
1 parent 3146f1f commit 337d95f

6 files changed

Lines changed: 3 additions & 10 deletions

File tree

‎apps/editor/src/features/search-files/search-modes/perform-agent-search-mode/agents/antigravity.ts‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ export const antigravity_agent: CodingAgent = {
66
id: 'antigravity',
77
label: 'Antigravity',
88
cmd: 'agy',
9-
executable: 'agy',
109
is_installed: () => check_command_exists('agy'),
1110
get_documentation_url: () => 'https://antigravity.google/docs/cli/headless/',
1211
get_args: (query: string) => [

‎apps/editor/src/features/search-files/search-modes/perform-agent-search-mode/agents/claude.ts‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ export const claude_agent: CodingAgent = {
66
id: 'claude',
77
label: 'Claude Code',
88
cmd: 'claude',
9-
executable: 'claude',
109
is_installed: () => check_command_exists('claude'),
1110
get_documentation_url: () => 'https://code.claude.com/docs/en/headless',
1211
get_args: (query: string) => [

‎apps/editor/src/features/search-files/search-modes/perform-agent-search-mode/agents/codex.ts‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ export const codex_agent: CodingAgent = {
66
id: 'codex',
77
label: 'Codex',
88
cmd: 'codex',
9-
executable: 'codex',
109
is_installed: () => check_command_exists('codex'),
1110
get_documentation_url: () =>
1211
'https://learn.chatgpt.com/docs/non-interactive-mode',

‎apps/editor/src/features/search-files/search-modes/perform-agent-search-mode/agents/opencode.ts‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ export const opencode_agent: CodingAgent = {
66
id: 'opencode',
77
label: 'OpenCode',
88
cmd: 'opencode',
9-
executable: 'opencode',
109
is_installed: () => check_command_exists('opencode'),
11-
get_documentation_url: () => 'https://github.com/opencode/opencode',
10+
get_documentation_url: () => 'https://opencode.ai/docs/cli/',
1211
get_args: (query: string) => [
1312
'run',
1413
`${agentic_file_search_instructions}\n\n${query}`,

‎apps/editor/src/features/search-files/search-modes/perform-agent-search-mode/index.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,7 @@ export const perform_agent_search_mode = async (params: {
292292
)
293293
if (!agent_info) break
294294

295-
const executable = agent_info.executable
295+
const executable = agent_info.cmd
296296
const args = agent_info.get_args(query)
297297

298298
let agent_output = ''

‎apps/editor/src/features/search-files/search-modes/perform-agent-search-mode/types.ts‎

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,15 @@
1-
export interface CodingAgent {
1+
export type CodingAgent = {
22
id: string
33
label: string
44
cmd: string
5-
executable: string
65
is_installed: () => boolean
76
get_documentation_url: () => string
87
get_args: (query: string) => string[]
98
parse_stream_line?: (
10-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
119
parsed: any,
1210
report_progress: (msg: string) => void
1311
) => { output?: string } | undefined
1412
parse_final_output?: (
15-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
1613
parsed: any,
1714
current_output: string
1815
) => string | undefined

0 commit comments

Comments
 (0)