On this page
Upgrade#
Sumi follows semantic versioning. While the version starts with 0., a minor release (0.2 → 0.3) can change options or templates; a patch release (0.2.0 → 0.2.1) only fixes bugs. Every change is listed on the releases page.
Steps#
- Read the release notes for every version between yours and the new one. Look for Changed and Removed entries.
-
Update the package:
pippip install --upgrade mkdocs-sumiuvuv lock --upgrade-package mkdocs-sumi -
Build with warnings as errors:
mkdocs build --strict -
Look through a few pages with
mkdocs serve: the home page, a long docs page, the blog, and any page whose templates you override. - Update the version pin in
requirements.txt(or your lock file) and commit it, so your host builds with the same version.
MkDocs NG#
Sumi needs MkDocs NG 1.9 or newer, and installs it for you. Some features need a newer MkDocs NG:
| Feature | Needs |
|---|---|
Native translations (languages:) and the bilingual view |
MkDocs NG 1.11 |
llms.txt and Markdown copies of pages |
MkDocs NG 1.9 |
When you upgrade MkDocs NG on its own, read its release notes as well.
Template overrides#
An override replaces Sumi's copy of a template. When a release changes that template, your copy does not get the change. After an upgrade:
- List your overrides: the files in your
custom_dir. - For each, compare it with the new version in Sumi's
theme/folder, which you can find withpython -c "import mkdocs_sumi, os; print(os.path.dirname(mkdocs_sumi.__file__))". - Bring over the changes, keeping your own edits.
Overriding a block of main.html rather than a whole file keeps this work small.
Going back#
If a release causes trouble, pin the previous version and open an issue with the build output:
mkdocs-sumi==0.2.1