-
Notifications
You must be signed in to change notification settings - Fork 11
56 lines (47 loc) · 1.55 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
name: docs
on:
push:
branches: [master]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10"]
steps:
- uses: actions/checkout@v3
with:
persist-credentials: false # otherwise, the token used is the GITHUB_TOKEN, instead of your personal access token.
fetch-depth: 0 # otherwise, there would be errors pushing refs to the destination repository.
- name: Install poetry
run: pipx install poetry
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: "poetry"
- name: Install fftw3
run: |
sudo apt-get install libfftw3-dev
- name: Install poetry dependencies
run: |
poetry install
- name: Create local changes
run: |
pushd ./docs/docsrc
poetry run make clean
poetry run make github
popd
git add --force ./docs
git restore --staged ./docs/docsrc/bin
- name: Commit files
run: |
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git commit -m "Generate docs" -a
- name: Push changes
uses: ad-m/github-push-action@887c31bd838a40c4da09953b6df364b5439bd7c3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: refs/heads/master-sphinx
force: true