- Registered new "opencode" and "opencode/cli" runners in the sandbox initialization. - Updated the `runExecStep` function to use the computer's working directory and set the HOME environment variable. - Refactored attachment processing in the Claude package to delegate to shared functionality, improving code maintainability.
16 lines
592 B
Go
16 lines
592 B
Go
package sandboxv2
|
|
|
|
import (
|
|
"github.com/yaoapp/yao/agent/sandbox/v2/claude"
|
|
"github.com/yaoapp/yao/agent/sandbox/v2/opencode"
|
|
"github.com/yaoapp/yao/agent/sandbox/v2/types"
|
|
yaorunner "github.com/yaoapp/yao/agent/sandbox/v2/yao"
|
|
)
|
|
|
|
func init() {
|
|
Register("claude", func() types.Runner { return claude.New() })
|
|
Register("claude/cli", func() types.Runner { return claude.New() })
|
|
Register("opencode", func() types.Runner { return opencode.New() })
|
|
Register("opencode/cli", func() types.Runner { return opencode.New() })
|
|
Register("yao", func() types.Runner { return yaorunner.New() })
|
|
}
|