-
Notifications
You must be signed in to change notification settings - Fork 0
42 lines (34 loc) · 995 Bytes
/
docs.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
name: Docs CI
on:
# Triggers the workflow on push or pull request events but only for the default branch
push:
branches: [ main ]
permissions:
contents: write
jobs:
deploy:
name: Deploy
# This job will run on ubuntu virtual machine
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]
- name: Setup python environment
uses: actions/[email protected]
with:
python-version: 3.x
- name: Store cache id
run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
- name: Cache build
uses: actions/[email protected]
with:
key: mkdocs-material-${{ env.cache_id }}
path: .cache
restore-keys: |
mkdocs-material-
- name: Get dependencies
run: pip install mkdocs-material mkdocs-swagger-ui-tag
- name: Build and deploy to gh-pages branch
run: |
cd ./docs
mkdocs gh-deploy --force