---
name: "dh_mkdocs"
section: "1"
platform: "linux"
package: "mkdocs"
version: "1.6.1+dfsg1-2"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/dh_mkdocs"
---

# dh\_mkdocs(1)

helps with packaging MkDocs-generated documentation

## NAME

dh\_mkdocs - helps with packaging MkDocs-generated documentation

## SYNOPSIS

dh\_mkdocs \[*debhelper options*\] \[**-X***item*\] \[**-T***package* \| **--theme-package** *package*\]

## DESCRIPTION

**dh\_mkdocs** is a helper program for packaging documentation generated by MkDocs. More specifically:

- •

  It replaces static files with symlinks to their packaged versions if possible. For packages using non-standard themes, use the **--theme-package** option, for example:

  ```
      dh_mkdocs --theme-package mkdocs-bootstrap
  ```

  **dh\_mkdocs** only symlinks non-empty files with identical content.

- •

  For the standard **mkdocs** and **readthedocs** themes, it replaces references to the highlight.js library from CDN with references to the packaged version of that library.

- •

  It adds the needed dependencies to **${mkdocs:Depends}** substitution variable. Please add this variable to the **Depends:** field of your documentation package.

You can pass **--with mkdocs** to [**dh**(1)](/dh/1.md) to make it automatically call **dh\_mkdocs** after **dh\_installdocs**.

## OPTIONS

- **-X***item*, **--exclude** *item*

  Exclude files that contain *item* anywhere in their filename from being symlinked or edited.

  This option can be specified multiple times.

- **-T***package*, **--theme-package** *package*

  Scan the specified additional *package* for files that can be used as symlink targets.

  This option can be specified multiple times.

## SEE ALSO

[**debhelper**(7)](/debhelper/7.md), [**dh**(1)](/dh/1.md).

This program is meant to be used together with debhelper.

## AUTHOR

Dmitry Shachnev \<mitya57@debian.org\>
