11name : Build and Test
22
3- on :
4- push :
5- branches :
6- - master
7- pull_request :
8- branches :
9- - master
3+ on :
4+ push :
5+ branches :
6+ - master
7+ pull_request :
8+ branches :
9+ - master
10+ schedule :
11+ - cron : ' 0 6 * * 1' # Monday 6am UTC - weekly build to catch dependency issues
1012
1113concurrency :
12- group : ${{ github.head_ref || github.run_id }}
14+ group : ${{ github.workflow }}-${{ github. head_ref || github.run_id }}
1315 cancel-in-progress : true
1416
1517jobs :
3032 buildtype : [ release, debug ]
3133 os : [ alma9, ubuntu2204, ubuntu2404 ]
3234 compiler : [ clang, gcc ]
33- exclude :
34- - { os: alma9, compiler: nvhpc }
3535 include :
3636 - os : alma9
3737 container : almalinux:9
@@ -41,12 +41,19 @@ jobs:
4141 container : ubuntu:22.04
4242
4343 steps :
44- - uses : actions/checkout@v2
44+ - uses : actions/checkout@v4
4545 with :
4646 ref : ${{ github.event.pull_request.head.sha }}
4747 path : source
4848 - name : Setup
4949 run : source/scripts/ci/setup/linux.sh
50+ - name : Cache CMake build
51+ uses : actions/cache@v4
52+ with :
53+ path : build
54+ key : ${{ matrix.os }}-${{ matrix.compiler }}-${{ matrix.buildtype }}-${{ hashFiles('source/CMakeLists.txt', 'source/**/*.cmake') }}
55+ restore-keys : |
56+ ${{ matrix.os }}-${{ matrix.compiler }}-${{ matrix.buildtype }}-
5057 - name : Update
5158 run : source/scripts/ci/gh-actions/run.sh update
5259 - name : Configure
@@ -90,16 +97,23 @@ jobs:
9097 shell : bash
9198
9299 steps :
93- - uses : actions/checkout@v2
100+ - uses : actions/checkout@v4
94101 with :
95102 ref : ${{ github.event.pull_request.head.sha }}
96103 path : source
97- - name : Setup
104+ - name : Setup Windows
98105 if : ${{ runner.os == 'Windows' }}
99106 run : source/scripts/ci/setup/windows.sh
100- - name : Setup
107+ - name : Setup macOS
101108 if : ${{ runner.os == 'macOS' }}
102109 run : source/scripts/ci/setup/macos.sh
110+ - name : Cache CMake build
111+ uses : actions/cache@v4
112+ with :
113+ path : build
114+ key : ${{ matrix.jobname }}-${{ matrix.buildtype }}-${{ hashFiles('source/CMakeLists.txt', 'source/**/*.cmake') }}
115+ restore-keys : |
116+ ${{ matrix.jobname }}-${{ matrix.buildtype }}-
103117 - name : Update
104118 run : source/scripts/ci/gh-actions/run.sh update
105119 - name : Configure
0 commit comments