Skip to content

Commit 9a167f9

Browse files
authored
[CI] Some improvements to GitHub Actions (#145)
* Use `julia-actions/cache` in more places * make building the docs more colourful * run CI jobs only when necessary
1 parent 5302204 commit 9a167f9

File tree

4 files changed

+44
-2
lines changed

4 files changed

+44
-2
lines changed

.github/workflows/CI.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,24 @@
11
name: CI
2+
23
on:
34
pull_request:
5+
paths:
6+
- '.github/workflows/CI.yml'
7+
- 'ext/**'
8+
- 'src/**'
9+
- 'test/**'
10+
- 'Project.toml'
411
push:
512
branches:
613
- master
714
tags: '*'
15+
paths:
16+
- '.github/workflows/CI.yml'
17+
- 'ext/**'
18+
- 'src/**'
19+
- 'test/**'
20+
- 'Project.toml'
21+
822
jobs:
923
test:
1024
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }}

.github/workflows/Documenter.yml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,20 @@
11
name: Documenter
2+
23
on:
34
push:
45
branches: [master]
56
tags: [v*]
7+
paths:
8+
- '.github/workflows/Documenter.yml'
9+
- 'docs/**'
10+
- 'src/**'
11+
- 'Project.toml'
612
pull_request:
13+
paths:
14+
- '.github/workflows/Documenter.yml'
15+
- 'docs/**'
16+
- 'src/**'
17+
- 'Project.toml'
718

819
concurrency:
920
# Skip intermediate builds: always.
@@ -34,6 +45,6 @@ jobs:
3445
Pkg.develop(PackageSpec(path=pwd()))
3546
Pkg.instantiate()
3647
- uses: julia-actions/julia-buildpkg@v1
37-
- run: julia --project=docs docs/make.jl
48+
- run: julia --project=docs --color=yes docs/make.jl
3849
env:
3950
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/IntegrationTest.yml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,20 @@ name: IntegrationTest
22

33
on:
44
pull_request:
5+
paths:
6+
- '.github/workflows/IntegrationTest.yml'
7+
- 'ext/**'
8+
- 'src/**'
9+
- 'Project.toml'
510
push:
611
branches:
712
- master
813
tags: '*'
14+
paths:
15+
- '.github/workflows/IntegrationTest.yml'
16+
- 'ext/**'
17+
- 'src/**'
18+
- 'Project.toml'
919

1020
jobs:
1121
test:
@@ -25,14 +35,15 @@ jobs:
2535
with:
2636
version: ${{ matrix.julia-version }}
2737
arch: x64
38+
- uses: julia-actions/cache@v2
2839
- uses: julia-actions/julia-buildpkg@v1
2940
- name: Clone Downstream
3041
uses: actions/checkout@v5
3142
with:
3243
repository: ${{ matrix.package.user }}/${{ matrix.package.repo }}
3344
path: downstream
3445
- name: Load this and run the downstream tests
35-
shell: julia --project=downstream {0}
46+
shell: julia --color=yes --project=downstream {0}
3647
run: |
3748
using Pkg
3849
try

.github/workflows/Invalidations.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@ name: Invalidations
22

33
on:
44
pull_request:
5+
paths:
6+
- '.github/workflows/Invalidations.yml'
7+
- 'ext/**'
8+
- 'src/**'
9+
- 'Project.toml'
510

611
concurrency:
712
# Skip intermediate builds: always.
@@ -19,6 +24,7 @@ jobs:
1924
- uses: julia-actions/setup-julia@v2
2025
with:
2126
version: '1'
27+
- uses: julia-actions/cache@v2
2228
- uses: actions/checkout@v5
2329
- uses: julia-actions/julia-buildpkg@v1
2430
- uses: julia-actions/julia-invalidations@v1

0 commit comments

Comments
 (0)