document #2978
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: document | |
on: | |
schedule: | |
- cron: 0 0 * * * | |
push: | |
branches: | |
- master | |
workflow_dispatch: | |
pull_request: | |
jobs: | |
document: | |
name: build document | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v2-beta | |
- name: Set up Python | |
uses: actions/setup-python@v1 | |
with: | |
python-version: "3.10.13" | |
- name: Install | |
run: pip3 install mkdocs mkdocs-material fontawesome_markdown mkdocs-mermaid2-plugin pymdown-extensions plantuml-markdown python-markdown-math python-github-api mkdocs-github-dashboard pandas markdown==3.3.0 | |
- name: Set env | |
run: echo "GITHUB_TOKEN=${{ secrets.WAMV_TAN_BOT_SECRET }}" >> $GITHUB_ENV | |
- name: Generate documentation | |
run: mkdocs build | |
working-directory: docs | |
- uses: actions/upload-artifact@v2 | |
if: ${{ github.event_name == 'pull_request'}} | |
with: | |
name: site | |
path: docs/site | |
- uses: peaceiris/actions-gh-pages@v3 | |
if: ${{ github.event_name != 'pull_request'}} | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: docs/site |