Debian Codegraph @

.github/workflows/main-doc.yml

raw symbols SCIP
1 ---
2 # This is deploying the latest commits on main to main documentation
3 name: Zensical
4 on:
5 push:
6 branches:
7 - main
8 paths:
9 # Run only if any of the following paths are changed when pushing to main
10 - "tools/zensical_extensions/**"
11 - "docs/**"
12 - "mkdocs.yml"
13 - "pyproject.toml"
14 - "anta/**"
15 workflow_dispatch:
16
17 permissions:
18 contents: write
19
20 jobs:
21 'build_latest_doc':
22 name: 'Update Public main documentation'
23 runs-on: ubuntu-latest
24 steps:
25 - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
26 with:
27 fetch-depth: 0
28 persist-credentials: false
29
30 - name: 'Setup Python 3 on runner'
31 uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6.3.0
32 with:
33 python-version: '3.x'
34
35 - name: Setup Git config
36 run: |
37 git config --global user.name 'github-actions[bot]'
38 git config --global user.email 'github-actions[bot]@users.noreply.github.com'
39
40 - name: 'Build Zensical content and deploy to gh-pages to main'
41 env:
42 GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
43 run: |
44 git remote set-url origin "https://x-access-token:${GH_TOKEN}@github.com/${GITHUB_REPOSITORY}.git"
45 pip install --group doc -e tools/zensical_extensions
46 mike deploy --push main