# Rimfe for MkDocs and Material for MkDocs

Source: https://rimfe.com/docs-frameworks/mkdocs
Updated: October 30, 2026

MkDocs builds Markdown from one docs_dir, usually docs. Rimfe reads that setting from mkdocs.yml during setup and suggests the folder, so reviews check the pages MkDocs publishes. It does not read exclude_docs or nav, so repeat excluded pages in your ignore list.

## Where the docs live

Markdown files under `docs/`, or the folder named by `docs_dir` in `mkdocs.yml`. Output goes to `site/`, which holds HTML and is never matched by Markdown globs.

## What Rimfe watches

- Detected by `mkdocs.yml` or `mkdocs.yaml` anywhere in the repository.
- Suggested scope: the `docs_dir` folder next to that file, as `docs/**/*.{md,mdx}`, plus a root README.
- No other MkDocs setting is read: not `exclude_docs`, not `nav`.

## Sample .rimfe.json

Commit this to your default branch, then set Documentation scope to `.rimfe.json at the PR base` on the repository's Advanced settings tab. Rimfe reads it from each pull request's base commit.

```json
{
  "$schema": "https://rimfe.com/schema/rimfe.json",
  "docsGlobs": [
    "README.md",
    "docs/**/*.md"
  ],
  "docsIgnorePaths": [
    "docs/fr/**",
    "docs/includes/**"
  ],
  "ignorePaths": [
    "tests/**"
  ],
  "codeMappings": [
    {
      "source": "src/mytool/cli/**",
      "target": "docs/cli.md"
    },
    {
      "source": "src/mytool/config.py",
      "target": "docs/configuration.md"
    }
  ]
}
```

## Worked example: the code change

A pull request changes `src/mytool/cli/build.py`. Nothing in the pull request touches the docs.

```diff
- parser.add_argument("--output-dir", default="dist")
+ parser.add_argument("--out", default="dist")
```

## Worked example: the page it makes wrong

`docs/cli.md` still states the old behavior. Rimfe quotes both sides as evidence and suggests this patch.

```diff
- Run `mytool build --output-dir dist` to write the bundle.
+ Run `mytool build --out dist` to write the bundle.
```

## Limits

- Pages listed in `exclude_docs` are not skipped unless you repeat them in `docsIgnorePaths`.
- Translated copies, such as `docs/fr/index.md` or `index.fr.md`, are matched to their source page and not reviewed.
- Pages generated by plugins at build time are not in git, so they are not seen.
- Snippets pulled in with an include plugin are read as their own files.

## Related

- [MkDocs guide in the docs](https://docs.rimfe.com/guides/mkdocs)
- [Python: what Rimfe reads](https://rimfe.com/stacks/python)
- [Templates](https://rimfe.com/templates)
- [What is docs-as-code?](https://rimfe.com/learn/docs-as-code)
