mdBook

Write Online Books with mdBook

mdbook-github cat-development-tools

mdBook⮳ is a utility to create modern online books from Markdown files.

cargo install mdbook
mdbook serve --open

Let Readers Execute Sample Code in the Rust Playground

Rust by example - Playground cat-development-tools

Playground (Rust by example)⮳.

Augment mdbook with Plugins

mdbook has a large number of third-party plugins⮳.

Check Links with mdbook-linkcheck

mdbook-linkcheck mdbook-linkcheck-crates.io mdbook-linkcheck-github mdbook-linkcheck-lib.rs

mdbook-linkcheck is a backend for mdbook, which will check your links for you.

Hide Entire Chapters with mdbook-private

mdbook-private mdbook-private-crates.io mdbook-private-github mdbook-private-lib.rs

mdbook-private is a mdbook pre-processor that controls visibility of private chapters and sections within them.

Hide Pages with mdbook-hide

mdbook-hide mdbook-hide-crates.io mdbook-hide-github mdbook-hide-lib.rs cat-development-tools

mdbook-hide is a pre-processor for mdbook that adds support for hidden chapters.

cargo install mdbook-hide

Deploy Your Book or Documentation via a CD / CI Pipeline

GitHub Actions is a continuous integration and continuous delivery (CI/CD) platform that allows you to automate your build, test, and deployment pipeline.

GitHub Actions for mdBook allows you to build your site with mdbook. Linux (Ubuntu), macOS, and Windows are supported.

name: github pages

on:
  push:
    branches:
      - main
  pull_request:

jobs:
  deploy:
    runs-on: ubuntu-20.04
    concurrency:
      group: ${{ github.workflow }}-${{ github.ref }}
    steps:
      - uses: actions/checkout@v2

      - name: Setup mdBook
        uses: peaceiris/actions-mdbook@v2
        with:
          mdbook-version: '0.4.10'
          # mdbook-version: 'latest'

      - run: mdbook build

      - name: Deploy
        uses: peaceiris/actions-gh-pages@v3
        if: ${{ github.ref == 'refs/heads/main' }}
        with:
          github_token: ${{ secrets.GITHUB_TOKEN }}
          publish_dir: ./book

Add a Table of Contents to Each Page

mdbook-toc

mdbook-toc mdbook-toc-crates.io mdbook-toc-github mdbook-toc-lib.rs

mdbook-toc is a pre-processor for mdbook to add inline Table of Contents support.

mdbook-theme

mdbook-theme mdbook-theme-crates.io mdbook-theme-github mdbook-theme-lib.rs

mdbook-theme is a pre-processor and a backend to config theme for mdbook, especially creating a pagetoc on the right and setting full color themes from the official ace editor.

mdbook-pagetoc

mdbook-pagetoc mdbook-pagetoc-crates.io mdbook-pagetoc-github mdbook-pagetoc-lib.rs

mdbook-pagetoc is a mdbook plugin that provides a table of contents for each page.

Create Pages from a Template

Create Pages from a Template with mdbook-tera

mdbook-tera mdbook-tera-crates.io mdbook-tera-github mdbook-tera-lib.rs cat-command-line-utilities cat-template-engine

mdbook-tera is a Tera pre-processor for mdBook.

Replace Text in Chapters with yapp

mdbook-yapp mdbook-yapp-crates.io mdbook-yapp-github mdbook-yapp-lib.rscat-template-enginecat-text-processing

yapp is a mdbook pre-processor that simply replaces text in chapters. Phrases to be replaced with specified content are defined in plain-text configuration file.

Create a Journal with mdbook-journal

mdbook-journal-website mdbook-journal mdbook-journal-crates.io mdbook-journal-github mdbook-journal-lib.rs cat-command-line-utilities cat-template-engine

mdbook-journal is a journal plugin for mdBook.

Other

mdbook-cmdrun

mdbook-cmdrun mdbook-cmdrun-crates.io mdbook-cmdrun-github mdbook-cmdrun-lib.rs

mdbook-cmdrun is a mdbook pre-processor to run arbitrary commands.