Skip to content

#2 Add TOP and philosophy #222

#2 Add TOP and philosophy

#2 Add TOP and philosophy #222

Workflow file for this run

name: publish site
on: # 在什么时候触发工作流
push: # 在从本地main分支被push到GitHub仓库时
branches:
- main
pull_request: # 在main分支合并别人提的pr时
branches:
- main
env:
TZ: Asia/Shanghai
jobs: # 工作流的具体内容
deploy:
runs-on: ubuntu-latest # 创建一个新的云端虚拟机 使用最新Ubuntu系统
steps:
- name: Checkout master
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Set up Python3.x
uses: actions/setup-python@v2
with:
python-version: "3.10"
# 待完成:放在requirement.txt 文件夹里!
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install mkdocs-material mkdocs-git-revision-date-localized-plugin mkdocs-git-authors-plugin jieba mkdocs-statistics-plugin mkdocs-mermaid2-plugin mkdocs-blogging-plugin
# run: |
# python -m pip install --upgrade pip
# pip install setuptools==71.1.0
# pip install --no-build-isolation
# - run: pip install mkdocs-material mkdocs-git-revision-date-localized-plugin mkdocs-git-authors-plugin jieba mkdocs-statistics-plugin mkdocs-mermaid2-plugin mkdocs-blogging-plugin --no-build-isolation # 使用pip包管理工具安装mkdocs-materials
- run: mkdocs gh-deploy --force # 使用mkdocs-material部署gh-pages分支