-
-
Notifications
You must be signed in to change notification settings - Fork 15
43 lines (38 loc) · 1.13 KB
/
gh-pages.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
name: Publish Documentation
on:
push:
branches:
- master
jobs:
deploy:
if: ${{ github.repository == 'ChristopherMayes/openPMD-beamphysics' }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
python-version: [3.9]
steps:
- uses: actions/checkout@v3
- uses: conda-incubator/setup-miniconda@v2
with:
python-version: ${{ matrix.python-version }}
mamba-version: "*"
channels: conda-forge
activate-environment: pmd_beamphysics-dev
environment-file: environment.yml
- name: Execute notebooks
shell: bash -l {0}
run: |
pip install --no-dependencies .
scripts/execute_notebooks.bash
- name: Build Docs
shell: bash -l {0}
run: |
mkdocs build
zip -r openPMD-beamphysics-examples.zip docs/examples/
mv openPMD-beamphysics-examples.zip ./site/assets/.
- name: Deploy to gh-pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./site/