Skip to content

Commit 3566670

Browse files
committed
deploy to github pages
1 parent 1851b90 commit 3566670

File tree

1 file changed

+41
-10
lines changed

1 file changed

+41
-10
lines changed

.github/workflows/docs.yml

Lines changed: 41 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5,23 +5,54 @@ on:
55
branches: [main, master]
66
pull_request:
77
branches: [main, master]
8+
workflow_dispatch:
9+
10+
11+
permissions:
12+
contents: read
13+
pages: write
14+
id-token: write
15+
16+
concurrency:
17+
group: "pages"
18+
cancel-in-progress: false
819

920
jobs:
1021
build:
1122
runs-on: ubuntu-latest
12-
container:
13-
image: julia:1.11
14-
23+
1524
steps:
16-
- uses: actions/checkout@v6
25+
- uses: actions/checkout@v4
1726
with:
1827
fetch-depth: 0
19-
20-
- name: Install dependencies
28+
29+
- uses: julia-actions/setup-julia@v2
30+
with:
31+
version: '1.11'
32+
33+
- uses: julia-actions/cache@v2
34+
35+
- name: Instantiate docs environment
2136
run: julia --project=docs -e 'ENV["JULIA_SSL_NO_VERIFY_HOSTS"] = "pkg.julialang.org,github.com"; using Pkg; Pkg.instantiate()'
22-
37+
2338
- name: Build documentation
2439
run: julia --project=docs docs/make.jl
25-
env:
26-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
27-
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
40+
41+
- name: Upload Pages artifact
42+
if: github.event_name != 'pull_request'
43+
uses: actions/upload-pages-artifact@v3
44+
with:
45+
path: docs/build
46+
47+
deploy:
48+
if: github.event_name != 'pull_request'
49+
needs: build
50+
runs-on: ubuntu-latest
51+
environment:
52+
name: github-pages
53+
url: ${{ steps.deployment.outputs.page_url }}
54+
55+
steps:
56+
- name: Deploy to GitHub Pages
57+
id: deployment
58+
uses: actions/deploy-pages@v4

0 commit comments

Comments
 (0)