diff options
| author | adamdottv <[email protected]> | 2025-05-27 12:25:43 -0500 |
|---|---|---|
| committer | adamdottv <[email protected]> | 2025-05-28 15:36:35 -0500 |
| commit | 641e9ff6642ef7b55928ef235f54d53822045baf (patch) | |
| tree | 1e55aef6908a166f556d0fea739258fe18f13043 /cmd | |
| parent | d249766777b607b521d178adc5c7c6c3951415f1 (diff) | |
| download | opencode-641e9ff6642ef7b55928ef235f54d53822045baf.tar.gz opencode-641e9ff6642ef7b55928ef235f54d53822045baf.zip | |
chore: cleanup unused imports
Diffstat (limited to 'cmd')
| -rw-r--r-- | cmd/root.go | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/cmd/root.go b/cmd/root.go index ea68cd5ad..a6b82c409 100644 --- a/cmd/root.go +++ b/cmd/root.go @@ -5,14 +5,12 @@ import ( "fmt" "io" "os" - "strings" "sync" "time" "log/slog" tea "github.com/charmbracelet/bubbletea" - "github.com/go-viper/mapstructure/v2" zone "github.com/lrstanley/bubblezone" "github.com/spf13/cobra" "github.com/sst/opencode/internal/app" @@ -25,7 +23,6 @@ import ( "github.com/sst/opencode/internal/pubsub" "github.com/sst/opencode/internal/tui" "github.com/sst/opencode/internal/version" - "github.com/sst/opencode/pkg/client" ) type SessionIDHandler struct { @@ -95,7 +92,7 @@ to assist developers in writing, debugging, and understanding code directly from // Check if we're in non-interactive mode prompt, _ := cmd.Flags().GetString("prompt") - + // Check for piped input if no prompt was provided via flag if prompt == "" { pipedInput, hasPipedInput := checkStdinPipe() @@ -103,7 +100,7 @@ to assist developers in writing, debugging, and understanding code directly from prompt = pipedInput } } - + // If we have a prompt (either from flag or piped input), run in non-interactive mode if prompt != "" { outputFormatStr, _ := cmd.Flags().GetString("output-format") @@ -347,7 +344,7 @@ func checkStdinPipe() (string, bool) { if err != nil { return "", false } - + // If we got data, return it if len(data) > 0 { return string(data), true |
