-
Notifications
You must be signed in to change notification settings - Fork 7
66 lines (63 loc) · 1.86 KB
/
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
name: docs
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
env:
HOMEBREW_NO_INSTALL_CLEANUP: 1
jobs:
build:
runs-on: macos-latest
steps:
# -
# name: Install some tools
# run: sudo apt-get install -y libcairo2-dev libfreetype6-dev libffi-dev libjpeg-dev libpng-dev libz-dev
# -
# name: Set up Homebrew
# id: set-up-homebrew
# uses: Homebrew/actions/setup-homebrew@master
-
name: Install Python
uses: actions/setup-python@v4
with:
python-version: '3.10.8'
-
name: Set up Git repository
uses: actions/checkout@v3
with:
fetch-depth: 0
-
uses: actions/cache@v3
if: ${{ github.ref == 'refs/heads/main' }}
with:
key: ${{ github.ref }}
path: .cache
-
name: Install asdf & tools
uses: asdf-vm/actions/install@v2
-
name: Install all MkDocs dependencies
if: ${{ github.ref == 'refs/heads/main' }}
env:
PAT_MKDOCS_INSIDERS: ${{ secrets.PAT_MKDOCS_INSIDERS }}
run: |
# echo "/home/linuxbrew/.linuxbrew/bin/brew" >> $GITHUB_PATH
make --environment-overrides docs-install-github-actions
-
name: Build Site
# if: ${{ github.ref != 'refs/heads/main' }}
env:
PAT_MKDOCS_INSIDERS: ${{ secrets.PAT_MKDOCS_INSIDERS }}
# run 'docs-build' twice because 'gen_files' doesn't let MkDocs
# pick up on the generated files in the first run
run: |
make --environment-overrides docs-build
make --environment-overrides docs-build
-
name: Deploy Site
if: ${{ github.ref == 'refs/heads/main' }}
env:
PAT_MKDOCS_INSIDERS: ${{ secrets.PAT_MKDOCS_INSIDERS }}
run: make --environment-overrides docs-deploy