feat(cli): add corps search command and intuitive aliases

- Implement hose-use corps search <keyword> with case-insensitive fuzzy matching across id, name, corpId, staffId, staffName, and accountId
- Format terminal table output with matched cell brackets, hit labels, active corp markers, and friendly no-match fallback
- Support --json structured output conforming to CliResult specification
- Add intuitive aliases for frequently guessed commands: auth list -> auth accounts, corps find -> corps search, config show -> config paths
- Enhance CorpSummary and CorpContext with corpId, staffName, and getAllCorps
- Add comprehensive unit tests in corps.test.ts, auth.test.ts, and config.test.ts
This commit is contained in:
gitea committed 2026-09-09 14:42:58 +08:00
1 parent 8efce4342a
commit 1cd8901f7a
10 files changed
+630 -11

No files matched your search

+1
View File
@@ -29,6 +29,7 @@ hose-use auth refresh # 批量刷新账号名下全部
# 2. 多企业租户管理
hose-use corps list # 列出名下所有已配置企业
hose-use corps search <关键词> # 模糊搜索已保存的企业与员工 (别名: corps find)
hose-use corps switch <corpId> # 切换工作企业
hose-use corps current # 查看当前激活企业