File tree 1 file changed +23
-0
lines changed 1 file changed +23
-0
lines changed Original file line number Diff line number Diff line change 62
62
# Setup: checkout
63
63
- uses : actions/checkout@v2
64
64
65
+ # Setup: Store matrix name
66
+ - run : echo 'MATRIX_NAME=${{ matrix.arch }}-${{ matrix.toolchain }}-${{ matrix.config }}' >> $GITHUB_ENV
67
+
68
+ # Setup: Github cache
69
+ - uses : actions/cache@v2
70
+ with :
71
+ path : ~/.ccache
72
+ key : ${{ env.MATRIX_NAME }}-ccache-${{ github.run_id }}
73
+ restore-keys : |
74
+ ${{ env.MATRIX_NAME }}-ccache-
75
+
65
76
# Setup: variables
66
77
- if : matrix.arch == 'x86_64'
67
78
run : |
@@ -194,6 +205,15 @@ jobs:
194
205
- run : |
195
206
curl -o bin/bindgen https://raw.githubusercontent.com/Rust-for-Linux/ci-bin/master/bindgen-0.56.0/bin/bindgen
196
207
chmod u+x bin/bindgen
208
+
209
+ # Setup: ccache
210
+ - run : |
211
+ sudo apt-get install ccache
212
+ echo '/usr/lib/ccache:$PATH' >> $GITHUB_PATH
213
+ echo 'CCACHE_COMPRESS=true' >> $GITHUB_ENV
214
+
215
+ # Setup: Check existing ccache
216
+ - run : ccache -s
197
217
198
218
# Setup: busybox
199
219
- run : git clone --depth 1 -b 1_30_1 https://github.com/mirror/busybox
@@ -376,3 +396,6 @@ jobs:
376
396
377
397
# Formatting
378
398
- run : make rustfmtcheck
399
+
400
+ # View changes to ccache
401
+ - run : ccache -s
You can’t perform that action at this time.
0 commit comments