chore: refactoring status updates

This commit is contained in:
adamdottv 2025-05-08 12:03:59 -05:00
parent e35ea2d448
commit f41b7bbd0a
No known key found for this signature in database
GPG key ID: 9CB48779AF150E75
24 changed files with 367 additions and 265 deletions

View file

@ -12,7 +12,7 @@ import (
"syscall"
"time"
"github.com/opencode-ai/opencode/internal/logging"
"github.com/opencode-ai/opencode/internal/status"
)
type PersistentShell struct {
@ -101,7 +101,7 @@ func newPersistentShell(cwd string) *PersistentShell {
go func() {
err := cmd.Wait()
if err != nil {
logging.ErrorPersist(fmt.Sprintf("Shell process exited with error: %v", err))
status.Error(fmt.Sprintf("Shell process exited with error: %v", err))
}
shell.isAlive = false
close(shell.commandQueue)