Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jonasdoesthings/mkdocs-exclude-tagged-files
A mkdocs plugin for excluding files based on frontmatter tags
https://github.com/jonasdoesthings/mkdocs-exclude-tagged-files
mkdocs mkdocs-material mkdocs-plugin mkdocs-site
Last synced: about 2 months ago
JSON representation
A mkdocs plugin for excluding files based on frontmatter tags
- Host: GitHub
- URL: https://github.com/jonasdoesthings/mkdocs-exclude-tagged-files
- Owner: JonasDoesThings
- License: mit
- Created: 2022-12-15T20:36:59.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2023-09-10T15:14:45.000Z (over 1 year ago)
- Last Synced: 2024-10-29T08:28:51.234Z (about 2 months ago)
- Topics: mkdocs, mkdocs-material, mkdocs-plugin, mkdocs-site
- Language: Python
- Homepage:
- Size: 10.7 KB
- Stars: 3
- Watchers: 1
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# MKDocs Exclude Tagged Files
A simple plugin for excluding files from being included in the mkdocs output based on tags in their frontmatter.## Installation
Run `pip install --upgrade mkdocs-exclude-tagged-files`## Configuration
Basic Configuration in the `mkdocs.yml` file:
```yaml
plugins:
- mkdocs_exclude_tagged_files:
tags_to_exclude: ["confidential", "excluded"]
```
This configuration will exclude all files that have one of the tags "confidential" or "excluded" in their frontmatter.
For example this file will be excluded:
```markdown
---
tags: ["confidential", "someothertag"]
---
# Content
```By default, the plugin strips leading `#`-symbols from tags, so the tag `#excluded` will be treated the same as `excluded`.
If you want to disable this behavior set the config value `strip_leading_hashtags` to `false`.