Skip to content

0.4.2

Choose a tag to compare

@Panther-w Panther-w released this 09 Nov 08:52
· 28 commits to main since this release
eaf557c

dsh-opencode-go-usage-badge 0.4.2

Compatibility release for OpenCode Console users. / 兼容 OpenCode Console 用户的修复版本。

English

  • OpenCode Go: if OPENCODE_GO_API_KEY is absent, the Host now reads the local credential (OAuth or key) of an installed OpenCode Console plugin (credential.json) and uses that token for the quota request. Console users no longer see 额度 —.
  • The fallback is read-only and Host-side; the token never reaches the browser and is not written anywhere else.
  • 37 automated tests, including OAuth/key fallback, precedence and missing-file cases.
  • No change for users who already configured OPENCODE_GO_API_KEY.

中文

  • OpenCode Go:没有配置 OPENCODE_GO_API_KEY 时,Host 会读取已安装的 OpenCode Console 插件本地凭据(OAuth/Key)(credential.json)并用于额度请求;Console 用户不再显示「额度 —」。
  • 兜底为只读、仅在 Host 内使用;令牌不进入浏览器,也不写到其他位置。
  • 37 项自动测试,覆盖 OAuth/Key 兜底、优先级与文件缺失场景。
  • 已配置 OPENCODE_GO_API_KEY 的用户行为不变。

安装包 / Asset: dsh-opencode-go-usage-badge-0.4.2.tgz(SHA-256 见 SHA256SUMS)