v0.7.7
0.7.7 更新内容
新功能
/statusline斜杠命令 + git 状态 API — 切换底部状态栏(窗口 + 会话 + git)。新增GET /api/statusline?cwd=...路由,返回分支、与上游的 ahead/behind 数量、修改/暂存/未跟踪/已删除文件数,以及最近一次提交。
API 错误处理重构(P1-1)
- 新增
lib/api-error辅助函数:errorMessage()、getRequestId()、logApiError()。 - 14 个 API 路由迁移到新 helpers;所有响应现在都带
x-request-id响应头,便于跨栈关联日志。
Bug 修复
useAgentSession挂载副作用(P0-6) — 切换 session 时正确重置状态,避免残留的 streaming / compacting 状态。lib/normalize.ts— 去除冗余类型断言。
测试
- 新增 31 个单元测试,覆盖
lib/api-error、lib/normalize、lib/slash-commands(含新增的/statusline项)。
文档
- 新增 P0 架构评审、设计文档与实施计划,位于
docs/superpowers/。
完整变更:v0.7.6...v0.7.7
What's in 0.7.7
New Features
/statuslineslash command + git status API — toggle the bottom status bar (window + session + git). NewGET /api/statusline?cwd=...route returns branch, ahead/behind counts, modified/staged/untracked/deleted file counts, and last commit.
API error handling refactor (P1-1)
- New
lib/api-errorhelpers:errorMessage(),getRequestId(),logApiError(). - 14 API routes migrated to use the helpers; every response now carries an
x-request-idheader for cross-stack correlation.
Bug fixes
useAgentSessionmount effect (P0-6) — properly resets state on session change to avoid stale streaming/compacting state.lib/normalize.ts— removed redundant type casts.
Tests
- 31 new unit tests covering
lib/api-error,lib/normalize, andlib/slash-commands(including the new/statuslineentry).
Documentation
- P0 architecture review, design specs, and implementation plans under
docs/superpowers/.
Full Changelog: v0.7.6...v0.7.7