fix(output): --format table 支持资源包裹列表响应(此前 list 命令表格从不生效) #343
Loading…
Reference in New Issue
No description provided.
Delete Branch "Taoyouce/gitlink-cli:feat/table-list-rendering"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
问题
平台所有分页列表端点的响应形状都是资源包裹 map:
{"total_count": N, "<资源名>": [...]}。printTable遇到含嵌套结构的 map 一律回落 JSON,导致 所有 list 命令的--format table实际上从不渲染表格,与 flag 文案承诺不符。修复
total_count: 7,键排序),再把包裹数组渲染为表格生产实测
branch +list --format table(forgeplus):输出total_count: 7摘要行 + 7 行分支表格(此前输出整段 JSON)。测试
formatter_test.go 新增 2 个单测;全量 go test/vet/gofmt 通过。