Skip to content

home

mkdocs 知识库

已实现根据docs下的文件夹以及文件自动刷新mkdocs.yml配置文件:

  • 只支持到二级目录
  • 只识别markdown文件
  • 设置站点名称、主题、监控文件目录,请编辑index.sh手动修改

运行条件

安装mkdocs

运行

执行服务启动:

mkdocs serve

更新配置文件:

chmod +x ./index.sh && ./index.sh

部署

方案1: 直接启动mkdocs serve,默认端口3000

方案2: 执行mkdocs build,构建为html资源进行普通部署

其他

Usage: mkdocs [OPTIONS] COMMAND [ARGS]...

  MkDocs - Project documentation with Markdown.

Options:
  -V, --version         Show the version and exit.
  -q, --quiet           Silence warnings
  -v, --verbose         Enable verbose output
  --color / --no-color  Force enable or disable color and wrapping for the output. Default is auto-detect.
  -h, --help            Show this message and exit.

Commands:
  build      Build the MkDocs documentation.
  get-deps   Show required PyPI packages inferred from plugins in mkdocs.yml.
  gh-deploy  Deploy your documentation to GitHub Pages.
  new        Create a new MkDocs project.
  serve      Run the builtin development server.

创作者

gaopuguang(2694484453@qq.com)