Skip to content

Commit 0e08ffe

Browse files
committed
build docs in separate action
1 parent c726c4e commit 0e08ffe

File tree

2 files changed

+27
-22
lines changed

2 files changed

+27
-22
lines changed

.github/workflows/CI.yml

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -46,25 +46,3 @@ jobs:
4646
- uses: codecov/codecov-action@v1
4747
with:
4848
file: lcov.info
49-
docs:
50-
name: Documentation
51-
runs-on: ubuntu-latest
52-
steps:
53-
- uses: actions/checkout@v2
54-
- uses: julia-actions/setup-julia@v1
55-
with:
56-
version: '1'
57-
- run: |
58-
julia --project=docs -e '
59-
using Pkg
60-
Pkg.develop(PackageSpec(path=pwd()))
61-
Pkg.instantiate()'
62-
- run: |
63-
julia --project=docs -e '
64-
using Documenter: doctest
65-
using LogDensityProblems
66-
doctest(LogDensityProblems)'
67-
- run: julia --project=docs docs/make.jl
68-
env:
69-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
70-
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# see https://juliadocs.github.io/Documenter.jl/dev/man/hosting/#GitHub-Actions
2+
# add this file to the repository once you set up authentication as described in the Documenter manual
3+
4+
name: Documentation
5+
6+
on:
7+
push:
8+
branches:
9+
- master
10+
tags: '*'
11+
pull_request:
12+
13+
jobs:
14+
build:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- uses: actions/checkout@v4
18+
- uses: julia-actions/setup-julia@latest
19+
with:
20+
version: '1.10'
21+
- name: Install dependencies
22+
run: julia --project=docs/ -e 'using Pkg; Pkg.develop(PackageSpec(path=pwd())); Pkg.instantiate()'
23+
- name: Build and deploy
24+
env:
25+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # If authenticating with GitHub Actions token
26+
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }} # If authenticating with SSH deploy key
27+
run: julia --project=docs/ docs/make.jl

0 commit comments

Comments
 (0)