Skip to content

Commit c5e9767

Browse files
committed
wip: can we cache mix?
1 parent 99b4966 commit c5e9767

File tree

1 file changed

+17
-8
lines changed

1 file changed

+17
-8
lines changed

build-aux/Jenkinsfile

Lines changed: 17 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -498,7 +498,6 @@ pipeline {
498498
}
499499

500500
stages {
501-
502501
stage('Setup Env') {
503502
agent {
504503
docker {
@@ -612,13 +611,23 @@ pipeline {
612611
}
613612
}
614613
steps {
615-
sh '''
616-
rm -rf apache-couchdb-*
617-
./configure --skip-deps --spidermonkey-version 78
618-
make erlfmt-check
619-
make elixir-source-checks
620-
make python-black
621-
'''
614+
cache(
615+
maxCacheSize: 250,
616+
defaultBranch: 'main',
617+
caches: [
618+
arbitraryFileCache(
619+
path: '_build',
620+
compressionMethod: 'TAR', // for binaries
621+
cacheValidityDecidingFile: 'mix.exs')
622+
]) {
623+
sh '''
624+
rm -rf apache-couchdb-*
625+
./configure --skip-deps --spidermonkey-version 78
626+
make erlfmt-check
627+
make elixir-source-checks
628+
make python-black
629+
'''
630+
}
622631
}
623632
post {
624633
cleanup {

0 commit comments

Comments
 (0)