Skip to content

serve

serve

Serve a MkNodes-based website, locally or remotely.

This is mknodes generate --watch running next to the engine's server (zensical serve -f <generated config>, http://localhost:8000/; mdbook serve <book dir>, http://localhost:3000/; Docsify: a static file server, http://localhost:3000/; Sphinx: sphinx-autobuild).

Further info here: https://phil65.github.io/mknodes/CLI/

mknodes serve [OPTIONS]

--repo-url, -r

Repository URL of the target package. Can be remote or local.

--build-fn, -b

Path to the build script. (form: path.to.module:function )

--clone-depth, -c

Git clone depth in case repository is remote. Important for changelog generation.

--config-path, -p

Default: mkdocs.yml Path to the config file.

--engine, -e

Default: zensical Site engine: zensical (HTML site, default), mkdocs (HTML site, needs the mkdocs extra), mdbook (HTML book, needs the mdbook binary to build / serve), sphinx (HTML site from MyST Markdown, needs the sphinx extra), docsify (Markdown rendered in the browser, no build step) or markdown (plain Markdown files).

--flavor

Markdown flavour (material, github, mdbook, myst). Default: the engine's flavour (zensical / mkdocs: material, mdbook: mdbook, sphinx: myst, docsify / markdown: github).

--verbose, -v

:mdi-flag: Flag Enable verbose output. (DEBUG level)

--quiet, -q

:mdi-flag: Flag Suppress output.

--help

:mdi-flag: Flag Show this message and exit.

Page info
Code for this page
mknodes.manual.site.cli_section._
@nav.route.page("serve", icon="web")
def _(page: mk.MkPage):
    page += mk.MkCliDoc(CLI_PATH, prog_name="serve")
Resources
Resources(css=[],
          markdown_extensions={'pymdownx.highlight': {'anchor_linenums': True,
                                                      'line_spans': '__span',
                                                      'pygments_lang_class': True},
                               'pymdownx.superfences': {}},
          plugins=[],
          js=[],
          assets=[Asset('materialbadge_31c4bf6.css')],
          packages=[])
Metadata
created:
  source_filename: /home/runner/work/mknodes/mknodes/src/mknodes/manual/site/cli_section.py
  source_function: _
  source_line_no: 21
icon: material/web
title: serve