Exercises RFC 3662 mergeable rustdoc support
(prelude//rust:doc_merge.bxl). Three crates: crate_a (leaf),
crate_b (depends on A), and bin (depends on both).
Uses the bundled prelude ([external_cells] prelude = bundled), so
edits to ../../prelude/ show up after the next cargo build --bin buck2.
buck2 build '//crate_a:crate_a[doc]' --show-output
buck2 bxl prelude//rust:doc_merge.bxl:merge -- --targets //...
The BXL prints an absolute path to a directory containing merged HTML with a cross-crate index. Serve it with e.g.:
env -C "$(buck2 bxl prelude//rust:doc_merge.bxl:merge -- --targets //...)" python3 -m http.serverPass --include-deps=true to additionally pull in transitive rust
dependencies of the listed targets.