-
Notifications
You must be signed in to change notification settings - Fork 11
49 lines (40 loc) · 1.17 KB
/
duHast_create_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
name: Step 1 - Check version, publish docs
on:
push:
branches:
- DuHast
jobs:
check:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
with:
token: ${{ secrets.GITHUB_TOKEN}}
ref: ${{ github.head_ref }}
fetch-depth: 0
- name: Setup Python environment
uses: actions/setup-python@v2
with:
python-version: '3.8'
- name: Check setup.cfg file
run: |
python $env:GITHUB_WORKSPACE\.github\workflows\check_setup_file.py
id: check_version_changed
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install Sphinx==7.0.1
pip install sphinx-adc-theme==0.1.7
- name: Create .rst files
run: |
sphinx-apidoc -f -o docsource/duHast src/duHast/
- name: Convert to html
run: |
sphinx-build -b html docsource/ docs/
- name: Commit update files back to main branch
run: |
git config --global user.name 'Github Action'
git config --global user.email '[email protected]'
git add .
git commit -m "Committed changes made by GitHub Action"
git push -f