The KES docs use Hugo to generate static HTML pages.
- Any operating system that Hugo supports
- nodejs 16.9.x or later
- Node Package Manager installed (8.5.0 or later)
- Hugo installed (0.110.0 or later)
-
Clone this repository
-
cd to the directory (
cd kes-docs
) -
Initialize the theme directory submodule
git submodule update --init --recursive
-
cd themes/kes-docs-theme
-
npm install
-
npm run build
-
cd ../../
The theme we use in the docs is hosted and maintained in a separate, private repository. We use a the git submodule functionality to include it here. After updating the theme, re-install node packages and then re-build the theme assets.
To pull new updates to the theme from the upstream repository, run the following:
git submodule update --recursive --remote
cd themes/kes-docs-theme
npm install
npm run build
Note: You must have access to the remote theme repository, which is a private MinIO repository.
You can launch a live preview of the site as you work.
-
From your terminal in the repository folder, run
hugo server
-
In your browser, go to
localhost:1313
To build the site for production or to upload to the staging server:
-
Run
hugo
-
Contents go to the
/public
directory in the repo folder.
We write in Goldmark Markdown as extended by Hugo shortcodes and our own shortcodes.
Goldmark is fully Commonmark compliant.
MinIO uses an internal style guide. Allow maintainers to modify your branch when you submit your PR so that we can adjust for internal style consistencies.
Otherwise, follow these resources in order of preference:
We write in American English, using Merriam Webster's online dictionary as the standard spelling reference.
To add a copy button to a code block, add {.copy}
after the language format.
For example
```yaml {.copy}
tls:
key: ./server.key # Path to the TLS private key
cert: ./server.cert # Path to the TLS certificate
password: "" # An optional password to decrypt the TLS private key
The code block must have a valid language type for the copy function to work.
Hugo uses shortcodes to extend what is normally available with Markdown.
To link to another page within the docs, use the following format.
[link text]({{< relref "path/to/page/#heading" >}})
Refer to themes/kes-docs-theme/README.md
.
We use YAML-formatted front matter.
Pages should have at least the following front matter tokens:
---
title: <Page Title>
date: YYYY-MM-DD ## date of file creation
lastmod: :git ## this is retrieved from git and should not be modified
draft: false ## set to true if the document is not yet ready for publication
tableOfContents: true ## creates a right-side page navigation TOC, set to `false` if not needed
---
Refer to themes/kes-docs-theme/README.md
.