-
Notifications
You must be signed in to change notification settings - Fork 5
40 lines (37 loc) · 1.29 KB
/
main.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
name: Build Docs
on:
# Trigger on pushes to the main branch only.
# See #5 ref restricting to tags.
push:
branches: [ main ]
# Or run manually.
workflow_dispatch:
jobs:
build-and-upload:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.x'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install Django Sphinx myst-parser furo
pip install -e .
- name: Build docs
run: make json
working-directory: ./docs
# Refs #22: Upload an artifact containing the built docs.
- name: Upload docs
id: artifact-upload-step
uses: actions/upload-artifact@v2
with:
# Use a name from the commit hash to avoid collisions.
name: docs-${{ github.sha }}
path: docs/build/json
- name: Get artifact details
run:
echo 'Artifact ID is ${{ steps.artifact-upload-step.outputs.artifact-id }}' >> $GITHUB_STEP_SUMMARY
echo 'Artifact Name is ${{ steps.artifact-upload-step.outputs.artifact-name }}' >> $GITHUB_STEP_SUMMARY
echo 'Artifact URL is ${{ steps.artifact-upload-step.outputs.artifact-url }}' >> $GITHUB_STEP_SUMMARY