[PR #11076] fix(cli): align auth plugin selection #13651

Closed
opened 2026-02-16 18:18:29 -05:00 by yindo · 0 comments
Owner

Original Pull Request: https://github.com/anomalyco/opencode/pull/11076

State: closed
Merged: No


Summary

  • align CLI auth plugin selection with ProviderAuth last-wins behavior
  • cover selection logic with focused unit tests
  • guard non-string provider values to mirror prior CLI behavior

Test Plan

  • bun test --cwd packages/opencode test/cli/auth-plugin-selection.test.ts
  • bun test --cwd packages/opencode
  • bun run --cwd packages/opencode script/build.ts
  • manual: CLI auth login now correctly selects the custom plugin for openai installed from https://github.com/iam-brain/opencode, following the same logic that the TUI does.

Fixes #10898

**Original Pull Request:** https://github.com/anomalyco/opencode/pull/11076 **State:** closed **Merged:** No --- ## Summary - align CLI auth plugin selection with ProviderAuth last-wins behavior - cover selection logic with focused unit tests - guard non-string provider values to mirror prior CLI behavior ## Test Plan - bun test --cwd packages/opencode test/cli/auth-plugin-selection.test.ts - bun test --cwd packages/opencode - bun run --cwd packages/opencode script/build.ts - manual: CLI auth login now correctly selects the custom plugin for openai installed from https://github.com/iam-brain/opencode, following the same logic that the TUI does. Fixes #10898
yindo added the pull-request label 2026-02-16 18:18:29 -05:00
yindo closed this issue 2026-02-16 18:18:29 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#13651