devflow_core/agents/
opencode.rs1use super::AgentAdapter;
6use crate::phase_id::PhaseId;
7
8pub struct OpenCodeAgent;
9
10impl AgentAdapter for OpenCodeAgent {
11 fn name(&self) -> &'static str {
12 "OpenCode"
13 }
14
15 fn exec_command(
16 &self,
17 _phase: PhaseId,
18 prompt: &str,
19 _extra_writable_roots: &[std::path::PathBuf],
20 ) -> (&'static str, Vec<String>) {
21 ("opencode", vec!["run".into(), prompt.to_string()])
22 }
23
24 fn completion_signal_detected(&self, _output: &str) -> bool {
25 false
26 }
27}