THE GITHTML FIELD GUIDE
Check Asciidoctor includes and safe mode before exporting
Inventory every AsciiDoc include and check how the selected Asciidoctor safe mode constrains processing before exporting. Use only approved local inputs and review extensions separately. Safe mode is a tool-specific control, not proof that arbitrary document processing is harmless, and a successful include can publish more material than the top-level source visibly contains.
Trace the complete input set
Start at the top-level AsciiDoc file and follow its include directives to identify the actual source material. Record paths, selected regions, and any attributes that influence those paths. Check whether the intended included content is public, internal, or generated. A small top-level file can assemble a large document from several directories, so reviewing only that file is insufficient. Do not enable remote access or broaden path permissions simply because an include failed. First determine whether the missing content belongs in the artifact and whether the current path reflects a mistake or an intentional processing restriction.
Test safe-mode behavior with harmless fixtures
Read the installed Asciidoctor version's safe-mode documentation and choose the mode appropriate to the project's approved build requirements. The sample explicitly selects safe mode for a local conversion; it is not a universal security recommendation for every extension or input. Create a small included file containing distinctive non-sensitive text and verify whether it is accepted from the intended location. Test an invalid path and inspect the diagnostic. Review extensions independently because their behavior and respect for processing restrictions require their own trust assessment. Keep the build environment limited to the resources the conversion actually needs.
asciidoctor -S safe -o include-review.html handbook.adocVerify expanded content and publication boundaries
Inspect the generated HTML for the expected included text and for accidental neighboring material, particularly when line ranges or tagged regions are used. Check that a later source edit cannot silently expand the exported scope beyond what reviewers expect. Record the input inventory with the build recipe and review it when includes are added or moved. If a required include is rejected, resolve the source layout or approved configuration rather than suppressing the problem with a broad permission change. After conversion, perform a content review of the assembled document. Safety controls govern processing behavior; they do not decide whether the resulting text is appropriate for its audience. Keep explicit records of any approved processing exception. A later maintainer should be able to distinguish a necessary local include arrangement from a temporary workaround that broadened access during troubleshooting.
- Trace nested includes and attribute-dependent paths before exporting.
- Confirm each input's intended audience and inclusion scope.
- Test the chosen safe mode using harmless valid and invalid paths.
- Inspect expanded output and review extensions separately from core safe-mode settings.
Sources and further reading
AI-assisted writing with source-linked guidance and illustrative examples. Read our editorial approach or report a correction.