-
Notifications
You must be signed in to change notification settings - Fork 0
51 lines (44 loc) · 1.24 KB
/
jupyterbook.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
name: deploy-book
on:
pull_request:
branches:
- main
push:
branches:
- main
# This job installs dependencies, builds the book, and pushes it to `gh-pages`
jobs:
deploy-book:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./julia-intro
shell: bash -l {0}
steps:
- uses: actions/checkout@v4
# Install dependencies
- name: Set up MiniConda
uses: mamba-org/setup-micromamba@v1
with:
environment-file: ./tutorial/environment.yml
init-shell: bash powershell
cache-environment: true
- name: Set up Julia
uses: julia-actions/setup-julia@v1
- uses: julia-actions/cache@v1
- uses: julia-actions/julia-buildpkg@v1
- name: Build the book
run: |
jupyter-book build ./docs
# Push the book's HTML to github-pages
- name: GitHub Pages action
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./geant4.jl/docs/_build/html
if: github.event_name != 'pull_request'
- name: Deploy preview
uses: rossjrw/pr-preview-action@v1
with:
source-dir: ./julia-intro/docs/_build/html
if: github.event_name == 'pull_request'