It is important to know that there are 2 ways to install this theme:
Install mdbook-catppuccin
using Cargo (It comes installed with Rust by default!)
Transfer files to your mdBook from this GitHub manually
Install mdbook-catppuccin
by running cargo install mdbook-catppuccin
Navigate to your mdBook's root directory (same location where the book.toml
lives) and run mdbook-catppuccin install
Build your mdBook using mdbook build
and enjoy your new catppuccin flavours!
Navigate to src/bin/assets
within this repository
Download all assets: index.hbs
, catppuccin.css
and catppuccin-highlight.css
Transfer downloaded assets to your mdBook theme directory (the default directory would be theme/
from the mdBook root if not already specified within the book.toml
)
Update additional-css
key within the book.toml
as shown below
diff
[output.html]
-additional-css = []
+additional-css = ["./theme/catppuccin.css", "./theme/catppuccin-highlight.css"]
Build your mdBook using mdbook build
and enjoy your new catppuccin flavours!
Navigate to index.hbs (L125 - L132)
and remove each theme that you do not want appearing on the mdBook
For example, to remove all the default themes:
```diff
```
Running mdbook build
again should get rid of the themes appearing in the theme picker, enjoy!
Arguably, it's actually better to transfer over the assets individually as you won't have to install this mdBook preprocessor. However, the assets will NOT be managed for you. You are in charge of upgrading/modifying the assets as you see fit. The preferred method of installation is through Rust as the pre-processor will be able to detect differences in versions of assets.
Inspiration for the install
command came from mdbook-admonish which is another great mdBook pre-processor!
Copyright © 2021-present Catppuccin Org