This project has been archived by its maintainers, and is no longer receiving any updates.
Bootstrap 4 theme for MkDocs
A vanilla Bootstrap 4 theme.
Screenshot
Quick start
First install the package:
$ pip install mkdocs-theme-bootstrap4
Then enable it:
theme:
name: bootstrap4
Configuration
Place these additional options under the theme: section of your mkdocs.yml configuration to change the theme's behaviour.
# Show next/previous links between pages?
next_previous: true
Bootstrap features
Some Bootstrap components require the addition of additional CSS classes. To enable these, add the following plugins in mkdocs.yml:
plugins:
- bootstrap4-blockquotes
- bootstrap4-tables
Hacking
First, install the dependencies:
- Python 2, for some of our dependencies.
- Python 3, for the package build process.
- Yarn, for managing frontend dependencies.
Ensure that Python 2 is found on your path before Python 3, else you'll get errors from node-gyp later. If you're unable to do this, set the environment variable npm_config_python to a command that'll launch Python 2 (py -2 on Windows, python2 elsewhere).
On Windows:
- It's easiest to not put Python on your path and instead rely on the
pyCLI. - You'll need the build tools necessary to install native dependencies:
npm install -g --production windows-build-tools.
To get completion working in your editor, set up a virtual environment in the root of this repository and install MkDocs:
$ pip3 install --user --upgrade setuptools twine wheel
$ python3 -m venv venv
$ . venv/bin/activate
$ pip install -r requirements.txt
To install the plugin onto a local MkDocs site in editable form:
$ pip install --editable /path/to/mkdocs-theme-bootstrap4
Upgrading dependencies
To upgrade the dependencies, install pip-upgrader:
. venv/bin/activate
pip install -r requirements.dev.txt
Then proceed to update the dependencies:
pip-upgrade requirements.dev.txt
The node dependencies can be updated with Yarn:
yarn upgrade
Releasing
Build the distributable package:
$ python3 setup.py sdist bdist_wheel
Push it to the PyPI test instance:
$ python3 -m twine upload --repository-url https://test.pypi.org/legacy/ dist/*
Test it inside a virtual environment:
$ pip install --index-url https://test.pypi.org/simple/ --no-deps mkdocs-drawio-exporter
Let's go live:
$ python3 -m twine upload dist/*
Metadata
Release files for mkdocs-theme-bootstrap4 0.4.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| mkdocs-theme-bootstrap4-0.4.0.tar.gz | 771.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| mkdocs_theme_bootstrap4-0.4.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 1.5 MB
Release files / mkdocs-theme-bootstrap4-0.4.0.tar.gz
| Download URL | mkdocs-theme-bootstrap4-0.4.0.tar.gz |
|---|---|
| Size | 771.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
de7a31fe910eb95acb1b22c95326d276edaf3b159a9db545d98b1741286f8a8a
|
|
BLAKE2b-256 checksum How to use checksums |
0f2c49c28d40fb133a8ff01a72d30641fb16c8407f9518648995cbba46f38ea3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.6
|
Release files / mkdocs_theme_bootstrap4-0.4.0-py3-none-any.whl
| Download URL | mkdocs_theme_bootstrap4-0.4.0-py3-none-any.whl |
|---|---|
| Size | 774.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d72298742287bdbf234d481d428e922e5ed4cdbedd33cb73c2bb663319a4be37
|
|
BLAKE2b-256 checksum How to use checksums |
008da57ad9f64c51218005a7afdb0a91e4bc819e68bf54907e58df5a605640d7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.6
|