1
1
name : CI
2
2
on :
3
- - push
4
- - pull_request
3
+ push :
4
+ branches :
5
+ - master
6
+ pull_request :
7
+ types : [opened, synchronize, reopened]
8
+ # needed to allow julia-actions/cache to delete old caches that it has created
9
+ permissions :
10
+ actions : write
11
+ contents : read
5
12
jobs :
6
13
test :
7
14
name : Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }}
@@ -17,21 +24,12 @@ jobs:
17
24
os : windows-latest
18
25
arch : x64
19
26
steps :
20
- - uses : actions/checkout@v3
21
- - uses : julia-actions/setup-julia@v1
27
+ - uses : actions/checkout@v4
28
+ - uses : julia-actions/setup-julia@v2
22
29
with :
23
30
version : ${{ matrix.version }}
24
31
arch : ${{ matrix.arch }}
25
- - uses : actions/cache@v3
26
- env :
27
- cache-name : cache-artifacts
28
- with :
29
- path : ~/.julia/artifacts
30
- key : ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
31
- restore-keys : |
32
- ${{ runner.os }}-test-${{ env.cache-name }}-
33
- ${{ runner.os }}-test-
34
- ${{ runner.os }}-
32
+ - uses : julia-actions/cache@v2
35
33
- uses : julia-actions/julia-buildpkg@v1
36
34
- uses : julia-actions/julia-runtest@v1
37
35
env :
@@ -48,23 +46,17 @@ jobs:
48
46
# Fix for Plots with GR backend, see https://github.com/jheinen/GR.jl/issues/422
49
47
GKSwstype : nul
50
48
steps :
51
- - uses : actions/checkout@v3
52
- - uses : julia-actions/setup-julia@v1
49
+ - uses : actions/checkout@v4
50
+ - uses : julia-actions/setup-julia@v2
53
51
with :
54
52
version : ' 1'
55
- - shell : bash
56
- run : julia --project=docs -e "using Pkg; Pkg.develop(PackageSpec(path=pwd()))"
57
- - shell : bash
58
- run : julia --project=docs -e "using Pkg; Pkg.instantiate()"
59
- - shell : bash
60
- env :
61
- DATADEPS_ALWAYS_ACCEPT : true # For MLDatasets.MNIST
53
+ - name : Install dependencies
54
+ shell : julia --color=yes --project=docs/ {0}
62
55
run : |
63
- julia --project=docs -e '
64
- using Documenter: doctest
65
- using DiffOpt
66
- doctest(DiffOpt)'
67
- - run : julia --project=docs docs/make.jl
56
+ using Pkg
57
+ Pkg.develop(PackageSpec(path=pwd()))
58
+ Pkg.instantiate()
59
+ - run : julia --project=docs --color=yes docs/make.jl
68
60
env :
69
61
DATADEPS_ALWAYS_ACCEPT : true # For MLDatasets.MNIST
70
62
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
0 commit comments