Add documentation export to single HTML and PDF files#7081
Draft
Add documentation export to single HTML and PDF files#7081
Conversation
Co-authored-by: peterkir <250545+peterkir@users.noreply.github.com>
Co-authored-by: peterkir <250545+peterkir@users.noreply.github.com>
Co-authored-by: peterkir <250545+peterkir@users.noreply.github.com>
Co-authored-by: peterkir <250545+peterkir@users.noreply.github.com>
Co-authored-by: peterkir <250545+peterkir@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add options for creating HTML or PDF from docs
Add documentation export to single HTML and PDF files
Feb 3, 2026
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.
Enables exporting Bnd documentation to offline formats (single HTML or PDF) for archival, distribution, and offline access across different versions.
Implementation
Export scripts:
export-single-html.sh- Combines all Jekyll-generated pages into single HTML with embedded TOC and print-friendly CSSexport-pdf.sh- Converts to PDF using auto-detected tools (wkhtmltopdf > weasyprint > chromium), falls back to HTML with manual conversion instructionsexport-release.sh- Exports fromreleases/directory without requiring Jekyll rebuildContent extraction:
_sitestructure (<main data-pagefind-body>) and release structure (<div class="notes-margin">)Documentation:
EXPORT_README.md- User guide with installation, usage, troubleshootingUSAGE_EXAMPLES.md- 10 practical examples covering all workflowsIMPLEMENTATION_SUMMARY.md- Technical detailsUsage
Tested with 7.0.0 release: 443 pages → 1.7MB HTML / 995KB PDF in <30s.
Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
accounts.google.com/proc/self/exe /proc/self/exe --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --use-angle=swiftshader-webgl --crashpad-handler-pid=4875 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/org.chromium.Chromium.scoped_dir.K6VpLd --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,17307914444301684977,14927625795285684904,262144 --disable-features=PaintHolding --variations-seed-version --trace-process-track-uuid=3190708989122997041 y-3.2.0 -I as(dns block)/usr/bin/chromium-browser chromium-browser --headless --disable-gpu --no-sandbox --print-to-pdf=test-output.pdf --no-pdf-header-footer file:///home/REDACTED/work/bnd/bnd/docs/bnd-docs-temp-test.html kward -I y-3.2.0/ruby/bac-I -I y-3.2.0 -I. u/13/liblto_plug-I .3-1ubuntu0.24.0/usr/include/ruby-3.2.0/ruby/backward u/13/cc1 -I. s -D_FORTIFY_SOURC/var/log u/13/cc1(dns block)/proc/self/exe /proc/self/exe --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --use-angle=swiftshader-webgl --crashpad-handler-pid=5688 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/org.chromium.Chromium.scoped_dir.OMNz3c --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,2703216554289212490,11620668788907996914,262144 --disable-features=PaintHolding --variations-seed-version --trace-process-track-uuid=3190708989122997041 y-3.2.0/ruby/bac-50 -I y-3.2.0(dns block)clients2.google.com/proc/self/exe /proc/self/exe --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --use-angle=swiftshader-webgl --crashpad-handler-pid=4875 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/org.chromium.Chromium.scoped_dir.K6VpLd --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,17307914444301684977,14927625795285684904,262144 --disable-features=PaintHolding --variations-seed-version --trace-process-track-uuid=3190708989122997041 y-3.2.0 -I as(dns block)/usr/bin/chromium-browser chromium-browser --headless --disable-gpu --no-sandbox --print-to-pdf=test-output.pdf --no-pdf-header-footer file:///home/REDACTED/work/bnd/bnd/docs/bnd-docs-temp-test.html kward -I y-3.2.0/ruby/bac-I -I y-3.2.0 -I. u/13/liblto_plug-I .3-1ubuntu0.24.0/usr/include/ruby-3.2.0/ruby/backward u/13/cc1 -I. s -D_FORTIFY_SOURC/var/log u/13/cc1(dns block)/proc/self/exe /proc/self/exe --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --use-angle=swiftshader-webgl --crashpad-handler-pid=5688 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/org.chromium.Chromium.scoped_dir.OMNz3c --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,2703216554289212490,11620668788907996914,262144 --disable-features=PaintHolding --variations-seed-version --trace-process-track-uuid=3190708989122997041 y-3.2.0/ruby/bac-50 -I y-3.2.0(dns block)https://api.github.com/repos/bndtools/bnd/usr/bin/ruby3.2 ruby3.2 /home/REDACTED/work/bnd/bnd/docs/vendor/bundle/ruby/3.2.0/bin/jekyll build --gdwarf-5 --64 -o pipe.o /tmp/cciTsmQ2.s y-3.2.0/ruby/bacas kward y-3.2.0 /usr/libexec/gcc-I -qui�� by-3.2.0(http block)redirector.gvt1.com/proc/self/exe /proc/self/exe --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --use-angle=swiftshader-webgl --crashpad-handler-pid=4875 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/org.chromium.Chromium.scoped_dir.K6VpLd --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,17307914444301684977,14927625795285684904,262144 --disable-features=PaintHolding --variations-seed-version --trace-process-track-uuid=3190708989122997041 y-3.2.0 -I as(dns block)/usr/bin/chromium-browser chromium-browser --headless --disable-gpu --no-sandbox --print-to-pdf=test-output.pdf --no-pdf-header-footer file:///home/REDACTED/work/bnd/bnd/docs/bnd-docs-temp-test.html kward -I y-3.2.0/ruby/bac-I -I y-3.2.0 -I. u/13/liblto_plug-I .3-1ubuntu0.24.0/usr/include/ruby-3.2.0/ruby/backward u/13/cc1 -I. s -D_FORTIFY_SOURC/var/log u/13/cc1(dns block)/proc/self/exe /proc/self/exe --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --use-angle=swiftshader-webgl --crashpad-handler-pid=5688 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/org.chromium.Chromium.scoped_dir.OMNz3c --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,2703216554289212490,11620668788907996914,262144 --disable-features=PaintHolding --variations-seed-version --trace-process-track-uuid=3190708989122997041 y-3.2.0/ruby/bac-50 -I y-3.2.0(dns block)www.google.com/proc/self/exe /proc/self/exe --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --use-angle=swiftshader-webgl --crashpad-handler-pid=4875 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/org.chromium.Chromium.scoped_dir.K6VpLd --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,17307914444301684977,14927625795285684904,262144 --disable-features=PaintHolding --variations-seed-version --trace-process-track-uuid=3190708989122997041 y-3.2.0 -I as(dns block)/usr/bin/chromium-browser chromium-browser --headless --disable-gpu --no-sandbox --print-to-pdf=test-output.pdf --no-pdf-header-footer file:///home/REDACTED/work/bnd/bnd/docs/bnd-docs-temp-test.html kward -I y-3.2.0/ruby/bac-I -I y-3.2.0 -I. u/13/liblto_plug-I .3-1ubuntu0.24.0/usr/include/ruby-3.2.0/ruby/backward u/13/cc1 -I. s -D_FORTIFY_SOURC/var/log u/13/cc1(dns block)/proc/self/exe /proc/self/exe --type=utility --utility-sub-type=network.mojom.NetworkService --lang=en-US --service-sandbox-type=network --no-sandbox --use-angle=swiftshader-webgl --crashpad-handler-pid=5688 --enable-crash-reporter=, --noerrdialogs --user-data-dir=/tmp/org.chromium.Chromium.scoped_dir.OMNz3c --change-stack-guard-on-fork=enable --shared-files=network_parent_dirs_pipe:100,v8_context_snapshot_data:101 --field-trial-handle=3,i,2703216554289212490,11620668788907996914,262144 --disable-features=PaintHolding --variations-seed-version --trace-process-track-uuid=3190708989122997041 y-3.2.0/ruby/bac-50 -I y-3.2.0(dns block)If you need me to access, download, or install something from one of these locations, you can either:
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.