forked from bpfman/bpfman
-
Notifications
You must be signed in to change notification settings - Fork 0
47 lines (41 loc) · 1.42 KB
/
docs-build.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
name: bpfman-docs
on: # yamllint disable-line rule:truthy
push:
branches: [main]
tags:
- v*
jobs:
build-docs:
runs-on: ubuntu-24.04
timeout-minutes: 3
steps:
- uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # @v4
with:
ref: gh-pages
- uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # @v4
- uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # @v5
with:
python-version: 3.8
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # @v5
with:
# prettier-ignore
go-version: '1.21' # yamllint disable-line rule:quoted-strings
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Build API docs
run: |
./scripts/api-docs/generate.sh apidocs.html
- name: Configure Git user
run: |
git config --local user.email "github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
- name: Deploy Docs (Release Version)
if: startsWith(github.ref_name, 'v')
run: |
mike deploy --push --update-aliases ${{ github.ref_name }} latest
- name: Deploy Docs (Development Version)
if: github.ref_name == 'main'
run: |
mike deploy --push main