-
Notifications
You must be signed in to change notification settings - Fork 26
46 lines (44 loc) · 1.19 KB
/
build_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
name: Make docs
on: [push]
jobs:
build:
runs-on: ubuntu-latest
steps:
# This cancels any such job that is still runnning
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.6.0
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v2
# Install Python
- name: Set up Python 3.8
uses: actions/setup-python@v2
with:
python-version: '3.8'
- name: Install dependencies
run: |
pip install --upgrade pip
pip install pdoc -U
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Install skeletor
run: |
pip install -e .
- name: Build docs
run: |
pdoc -o ./docs skeletor
- name: Change index.html
run: |
cp ./docs/skeletor.html ./docs/index.html
# Configure Github
- name: setup git config
run: |
# setup the username and email.
git config user.name "GitHub Actions"
git config user.email "<>"
# Commit changes
- name: commit
run: |
# Stage the file, commit and push
git add ./docs
git commit -m "build docs"
git push origin master