Repository navigation
feat(mcp): 宿主旗标解析换 ca::opt,OutputSink 收编入 shared - #29
Merged
Merged
Conversation
- main.cpp 手写 strcmp 循环换 ca::opt(九个选项声明式注册,--help 自动 生成);--script 透传契约保持:按首个 --script 预切分 argv,头部解析、 尾部整段留脚本;数值上限保留 strtoull 全数字校验(u64 域不用 Int 的 32 位口径),错误文案不变 - mjbase cli 模块随退役整体移交在用两小块:OutputSink(FILE* 输出封装) 落 src/shared/output_sink.hpp(ns mjt::,去 cli 专有 Format 段), class_render/shadow_display/json_util 三消费面转指 - i18n init 摘 kCliI18nTableSet 合并(该表只服务 ArgParser 框架文案, 轮子退役后零查询) 套件 116+1 / 40 / 44 基线持平。
CI 冒烟实证:aliases 含 --stdio 与自动注册的 --stdio 撞名,解析器定义期 即报 duplicate option token。aliases 只留真正附加别名(-i)。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
背景
mjbase cli 模块裁决退役(平行 PR):ArgParser 与 libca
ca::opt平行造轮(子命令/互斥组/CJK 排版全面落后)。本 PR 先行把 mjt 侧消费面转走,mjbase 侧随后整删模块。内容
ca::opt九选项声明式注册,--help 自动生成。--script透传契约保持(按首个 --script 预切分 argv:头部解析、尾部整段留脚本);数值上限保留 strtoull 全数字校验(u64 域不用 Int 32 位口径),错误文案不变。src/shared/output_sink.hpp(nsmjt::,去 cli 专有 Format 段),class_render/shadow_display/json_util 三消费面转指。kCliI18nTableSet合并——该表只服务 ArgParser 框架文案,轮子退役后零查询。验证
delete-then-rebuild:mjt_mcp 116+1 / workspace 40 / pysdk 44,基线持平;mjt-mcp 产品靶构建通过。