docs: Update documentation formatting #80
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 Documentation | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
workflow_dispatch: | |
permissions: | |
contents: write | |
pages: write | |
id-token: write | |
jobs: | |
deploy: | |
environment: | |
name: github-pages | |
url: ${{ steps.deployment.outputs.page_url }} | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.9' | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install mkdocs-material | |
pip install mkdocs-awesome-pages-plugin | |
pip install pyyaml | |
pip install Pillow>=10.0.0 # For image processing | |
- name: Update logs | |
run: | | |
python docs/scripts/log_management/update_logs.py | |
- name: Configure Git | |
run: | | |
git config --local user.email "github-actions[bot]@users.noreply.github.com" | |
git config --local user.name "github-actions[bot]" | |
- name: Commit log updates | |
run: | | |
git add mkdocs.yml | |
git diff --quiet && git diff --staged --quiet || git commit -m "chore: update logs navigation" | |
- name: Process and validate images | |
run: | | |
echo "Checking images..." | |
make check-images | |
echo "Processing images..." | |
make process-images | |
echo "Verifying images..." | |
make check-images | |
- name: Validate documentation | |
run: make validate-docs | |
- name: Build site | |
run: mkdocs build | |
- name: Upload artifact | |
uses: actions/upload-pages-artifact@v2 | |
with: | |
path: site | |
- name: Deploy to GitHub Pages | |
id: deployment | |
if: github.event_name == 'push' && github.ref == 'refs/heads/main' | |
uses: actions/deploy-pages@v3 |