Render --help=notice and --help=license from the help model - #390
Merged
Conversation
Port the last two verbatim topics off the imperative RenderNotice / RenderLicense onto the model: add NoticeSection() and LicenseSection() in help_build.cc, each a title-less section holding an Example. A title-less section adds no heading and does not indent, so the Example renders byte-exact at column 0 - exactly what verbatim legal text needs (no reflow, no fence), with the copyright leading --help=license (task #142). Route both (and aliases notices / licenses) through TopicReference; they stay out of the man/markdown reference (legal boilerplate). Delete RenderNotice / RenderLicense and their RenderHelp branches; move the license dep from help_cc to help_build_cc. No XFF.md change. Add model render tests; help_topic_test.sh unchanged (verbatim output preserved).
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.
Fourth slice of retiring the imperative prose-topic renderers (EPIC #154; follows #387 stats, #388 config, #389 cookbook).
What
help_build.cc: addNoticeSection()andLicenseSection(), each a title-less section holding anExample. A title-less section adds no heading and does not indent, so the Example renders byte-exact at column 0 - exactly what verbatim legal text needs (no reflow, no fence), with the copyright leading--help=license(task docs+engine: wire CLAUDE.md -> AGENTS.md -> STYLE_CPP.md; adopt the style in the walk #142).notice/noticesandlicense/licensesthroughTopicReference. They stay out of--man/--markdown(legal boilerplate is not reference material) - so no XFF.md change.RenderNotice/RenderLicenseand theirRenderHelpbranches; move the//xff/licensedep fromhelp_cctohelp_build_cc.Test
bazel test //xff/...(85) and--config=xff_full(90) green. Added model render tests; help_topic_test.sh unchanged (verbatim output preserved, incl. the^xff - eXtended File Findcopyright-leads anchor).Retirement status
RenderHelpnow handles only the help-guide (+ dead-shadowed list/all/full/expressions). The next slice ports the guide and removes the dead branches, retiringRenderHelp.