MkDocs

常用指令

mkdocs new [dir]
mkdocs build --clean
mkdocs gh-deploy

安裝

brew install mkdocs
# python
python get-pip.py
pip install --upgrade pip
pip install mkdocs
mkdocs --version

# chocolatey
choco install mkdocs

建立知識庫

mkdocs new [dir-name]
site_name: wiki
pages:
    - Home: index.md
    - About: about.md
curl 'https://jaspervdj.be/lorem-markdownum/markdown.txt' > docs/about.md
mkdocs serve
mkdocs build
echo "site/" >> .gitignore 
mkdocs build --clean # Removing documentation

發佈知識庫

mkdocs gh-deploy

主題

Material theme 支援 emoji

pip install mkdocs-material

安裝後要啟用PyMdown Extensions

MkDocs Bootstrap Theme

pip install mkdocs-bootswatch