OpenKF's docs are built with hugo, and can be browsed live at https://kind.sigs.k8s.io/
To browse them locally, install hugo and run make serve
from this directory.
Read tutorial, learning to use OpenKF document construction
npm install
npm run start
Directory | Description |
---|---|
archetypes | Directory for creating new content files with Hugo command. |
assets | Directory for storing files that need to be processed by Hugo Pipes. |
config | Directory for storing configuration directives in JSON, YAML, or TOML format. |
content | Directory for storing all the content of your website. Each top-level folder is considered a content section. |
data | Directory for storing configuration files that can be used by Hugo during website generation. |
layouts | Directory for storing template files specifying how to render content views in the static website. |
static | Directory for storing all static content such as images, CSS, JavaScript, etc. |
resources | Directory for caching files to speed up the generation process. |
Note💡: You can change the commands in the scripts section of
./package.json
.
Create new content for your site:
npm run create [path] [flags]
See also the Hugo docs: hugo new.
Create a docs based tree — with a single command:
npm run create -- --kind docs [section]
For example, create a docs based tree named guides:
npm run create -- --kind docs guides
Check scripts, styles, and markdown for errors:
npm run lint
Check scripts for errors:
npm run lint:scripts [-- --fix]
Check styles for errors:
npm run lint:styles [-- --fix]
Check markdown for errors:
npm run lint:markdown [-- --fix]
Delete temporary directories:
npm run clean
Start local development server:
npm run start
Build production website:
npm run build
Build Lambda functions:
npm run build:functions
Build production website including draft and future content:
npm run build:preview
hugo server