Skip to content

[Feature Request] cross-book content sharing #2988

@iampi31415

Description

@iampi31415

Problem

Different books tend to repeat much of their content across mdbooks.

For example, all the great embedded-rust books. After all all need to show how to set up Rust.

They then evolve independently, and each one loses knowledge that was added to another one, without a way to opt-in to updates.

Proposed Solution

As an example, Wikipedia they has sections coming from other articles.

It would be awesome if one could do this:

  1. Directly link a remote markdown page in SUMMARY.md using, for example:
    <!--SUMMARY.md-->
    # Summary  
    - [Same Chapter](https://www.github.com/otherbook/path.to.md)
    <!--probably the raw version-->
    - [Contributing](https://raw.githubusercontent.com/rust-lang/mdBook/refs/heads/master/CONTRIBUTING.html)
  2. The Edit on Github link in the page should direct to that file/url, then users would always edit or try to edit an upstream.

Notes

Ideally, some version number of the file (maybe the commit hash) should be allowed so that content does not change unexpectedly.

Maybe there is some pre-processor that does this, I have not seen one.

I am aware this is quite a stretch, but it's just an idea.

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-enhancementCategory: Enhancement or feature request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions