Merge pull request #36 from mbsantiago/fix/sound_event_notes #73
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: Make docs | |
on: | |
push: | |
branches: | |
- main | |
permissions: | |
contents: write | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
env: | |
UV_CACHE_DIR: /tmp/.uv-cache | |
steps: | |
- name: Checkout source code | |
uses: actions/checkout@v4 | |
- name: Set up uv | |
run: curl -LsSf https://astral.sh/uv/install.sh | sh | |
- name: Set up Python | |
run: uv python install 3.12 | |
- name: Create cache key | |
run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV | |
- name: Restore mkdocs cache | |
uses: actions/cache@v3 | |
with: | |
key: mkdocs-material-${{ env.cache_id }} | |
path: .cache | |
restore-keys: | | |
mkdocs-material- | |
- name: Restore uv cache | |
uses: actions/cache@v4 | |
with: | |
path: /tmp/.uv-cache | |
key: uv-${{ runner.os }}-${{ hashFiles('uv.lock') }} | |
restore-keys: | | |
uv-${{ runner.os }}-${{ hashFiles('uv.lock') }} | |
uv-${{ runner.os }} | |
- name: Install the project dependencies | |
run: | | |
cd back | |
uv sync --dev | |
- name: Build and Deploy Docs | |
run: | | |
cd back | |
uv run mkdocs gh-deploy --force | |
- name: Minimize uv cache | |
run: uv cache prune --ci |