Skip to content

fix(opencode): plain plugin spinner output outside TTY#37505

Open
mbaragiola wants to merge 1 commit into
anomalyco:devfrom
mbaragiola:plugin-nontty-spinner
Open

fix(opencode): plain plugin spinner output outside TTY#37505
mbaragiola wants to merge 1 commit into
anomalyco:devfrom
mbaragiola:plugin-nontty-spinner

Conversation

@mbaragiola

Copy link
Copy Markdown

Issue for this PR

Closes #27908

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

opencode plugin install used Clack's animated spinner even when stdout was not a TTY, so non-interactive shells printed spinner frames and ANSI junk.

This change keeps the animated spinner on TTY, and writes plain one-line start/stop messages otherwise.

How did you verify your code works?

From packages/opencode:

  • bun test test/plugin/install.test.ts — 22 pass
  • bun typecheck — pass
  • pre-push/turbo typecheck across packages — pass

Independent read-only Codex review (gpt-5.6-sol) returned PASS after applying a small test NIT for isTTY: undefined and stop(..., code).

Screenshots / recordings

N/A — CLI non-TTY behavior; covered by unit test.

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

plugin install spinner outputs garbage in non-TTY environment

1 participant