From 8066e8635c9b9ca1320750d947c8dc496217a5e3 Mon Sep 17 00:00:00 2001 From: Sylvain Huguet Date: Mon, 26 Feb 2024 18:17:15 +0100 Subject: [PATCH] Add VitePress instructions to BUILD.md (#2675) * Update BUILD.md Update BUILD.md to add information on how to edit/build/preview the docs using the new Markdown version + VitePress * Updated styling for commands in the BUILD.md new docs sections * Update BUILD.md Co-authored-by: Pavan Navarathna <6504783+pavannd1@users.noreply.github.com> * Update BUILD.md Co-authored-by: Pavan Navarathna <6504783+pavannd1@users.noreply.github.com> * Reformat to stay under 80 chars per line. --------- Co-authored-by: Pavan Navarathna <6504783+pavannd1@users.noreply.github.com> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> --- BUILD.md | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/BUILD.md b/BUILD.md index 7e2cf11436..74b26cd220 100644 --- a/BUILD.md +++ b/BUILD.md @@ -147,6 +147,37 @@ The `docs` target uses the `ghcr.io/kanisterio/docker-sphinx` public image to generate the HTML documents and store them in your local `/docs/_build/html` folder. +## New Documentation + +We have started experimenting, and will soon fully transition, to using + [VitePress](https://vitepress.dev/) to generate Kanister documentation. +This requires the documentation files to be written in +[Markdown](https://www.markdownguide.org/), along with some +[extensions](https://vitepress.dev/guide/markdown). + +This new documentation system offers a live-dev server that will dynamically +render Markdown documentation files as you are making changes to them on your +local machine/branch. +To start this development server, place yourself in the `new_docs` folder, then +run the following commands: + +```sh +pnpm install +pnpm run docs:dev +``` + +To render/build the docs locally (it will generate static assets, like HTML +pages, Javascript/CSS files, etc.), use this command: +```sh +pnpm run docs:build +``` + +To start a local webserver that you can use to preview the documentation that +has been rendered by the command above, use this command: +```sh +pnpm run docs:preview +``` + ## New Blueprints If you have new blueprints that you think will benefit the community, feel free