Update syntax.yml #233
Workflow file for this run
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: Deploy site | |
on: [push] | |
jobs: | |
deploy: | |
name: Linux Ubuntu 22.04 | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 # needed for accurate dates and blog plugin | |
- name: Install Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.11' | |
- name: Install Poetry | |
run: python3 -m pip install --upgrade poetry | |
- name: Cache build data | |
uses: actions/cache@v4 | |
with: | |
key: mkdocs-cache-${{ runner.os }}-${{ hashFiles('**/poetry.lock', '**/mkdocs.yml') }} | |
path: .cache | |
- name: Install dependencies | |
run: poetry install | |
- name: Download assets | |
run: poetry run python3 scripts/assets/download.py | |
- name: Build assets | |
run: poetry run python3 scripts/assets/uglify.py | |
- name: Create page symlinks | |
run: poetry run python3 scripts/recreate_symlinks.py | |
- name: Build site | |
run: poetry run mkdocs build | |
- name: Upload to GitHub pages | |
if: github.ref_name == 'source' && github.event_name != 'pull_request' | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_branch: www | |
publish_dir: ./_site | |
force_orphan: true |