No project description provided
Project description
toc-title: Table of contents
mkquartodocs
Make gorgeous reproducible documentation with quarto and mkdocs
It is a plugin for mkdocs that renders quarto markdown documents into github, so they are built with the rest of the documentation.
Why?
In many instances the documentation contains runnable code, and it makes sense that you verify that the code runs and keep the output of the code in sync with the current status of the document and software packages involved.
But mainly I really got tired of manually rendering documents and copying outpus.
Usage
- Install the dependencies: Installation
- Add the plugin to your configuration: Configuration
- Add
.qmd
files to your./docs/
directoy - Run
mkdocs build
This will render code chunks and save the outputs! Check out https://quarto.org/ for more examples on how to use the format.
This ....
```{python}
print(1+2)
```
Will become this ...
:::: {.cell execution_count="1"}
print(1+2)
::: {.cell-output .cell-output-stdout} 3 ::: ::::
Installation
-
Make sure you have quarto installed in your computer.
-
Install
mkquartodocs
pip install mkquartodocs
Configuration
Add mkquartodocs
to your plugins in your mkdocs.yml
# Whatever is in your mkdocs.yml configuration file....
# ...
plugins:
- mkquartodocs
Available configuration options:
- quarto_path: Specifies where to look for the quarto executable.
- keep_output: If true it will skip the cleanup step in the directory.
- ignore: a python regular expressions that if matched will mark the file to not be rendered. Note that they need to be full matches
# Whatever is in your mkdocs.yml configuration file....
# ...
plugins:
- mkquartodocs:
quarto_path: /home/my_folder/some/weird/place/to/have/executables/quarto
keep_output: true
ignore: (.*broken.*.qmd)|(.*page[0-9].qmd)
Running
NOTHING !!! you do not have to run it manually!!
When you call mkdocs build
, it should automatically find your .qmd
files, render them, generate the output and clean after itself.
TODO
The things that need to/could be added to the project:
- quarto project support
- render in temporary directory, posibly with a 'safe' argument
- addition of files not in the docs directory, 'include' argument
- add readme to testing data
- move
INFO - mkquartodocs: Running RemoveCellDataPreprocessor
to debug log
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file mkquartodocs-0.5.10.tar.gz
.
File metadata
- Download URL: mkquartodocs-0.5.10.tar.gz
- Upload date:
- Size: 10.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.7.1 CPython/3.12.5 Linux/6.5.0-1025-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4f84dd99bef092b5cc9344784f68b75bc7d1dce67f204f198920220a442320b0 |
|
MD5 | fb8a721aa58142cd62632b79aa431b54 |
|
BLAKE2b-256 | 6cb822f2c11eac896e9a45ea1c5281d1ec577ce1b20c1079b9e3e3fbe1b7f480 |
File details
Details for the file mkquartodocs-0.5.10-py3-none-any.whl
.
File metadata
- Download URL: mkquartodocs-0.5.10-py3-none-any.whl
- Upload date:
- Size: 12.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.7.1 CPython/3.12.5 Linux/6.5.0-1025-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 209c3e39572ee290f22241f978b654a43327b9b8e56b71792acaa8d4ea840904 |
|
MD5 | 0b016e09938bef3ff6361ef19792bfdd |
|
BLAKE2b-256 | 779d7ebe8b69320db04a0c13965f8e0cbc5f756972caee04b2c3e9b65373803a |