diff options
author | bartus | 2019-06-03 08:25:58 +0200 |
---|---|---|
committer | bartus | 2019-06-03 18:46:39 +0200 |
commit | 48223e7a8e1b742bb50194a8f934722a0077fc87 (patch) | |
tree | d2cc2c84ed9f6e8e2299bf9fa98e1588cd1d9893 /.travis.yml | |
parent | 4c674f519665936cccb4aa20e1bfe47390b7f551 (diff) | |
download | aur-48223e7a8e1b742bb50194a8f934722a0077fc87.tar.gz |
leverage Travis cache, add multithreading
1. add ccache support
2. add pacman-pkg-cache support
3. add multithreading flags to `make` and `xz`
Diffstat (limited to '.travis.yml')
-rw-r--r-- | .travis.yml | 32 |
1 files changed, 20 insertions, 12 deletions
diff --git a/.travis.yml b/.travis.yml index d9bc9a23e887..fd25dca6ca9f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,31 +6,39 @@ branches: cache: directories: - - src -# - AUR-repo + - .ccache + - .arch-cache + - AUR-repo + - LuxCore.git services: - docker arch: repos: -# - papyros=http://dash.papyros.io/repos/$repo/$arch - bartus=https://github.com/bartoszek/AUR-repo/raw/master packages: - # arch/aur packages -# - python -# - perl +# disable to prevent `package-cleanup.hook` +# - ccache +# - moreutils script: -# - "sudo pacman -Sy" - - "makepkg -s --noconfirm TRAVIS=1" + - "echo 'options+=(ccache)' >> PKGBUILD" + - "export CCACHE_DIR='/build/.ccache'" +# COMPRESSXZ=(), can't be passed to makepkg as bash dosn't support array in `export` statement. + - "echo 'COMPRESSXZ=(xz -T 0 -7 -c -z -)' >> PKGBUILD" +# override `package-cleanup.hook` to preserve cache for travis. + - "sudo mkdir /etc/pacman.d/hooks/ && sudo ln -s /dev/null /etc/pacman.d/hooks/package-cleanup.hook" + - "sudo pacman -S --noconfirm ccache moreutils" + - "makepkg -s --noconfirm TRAVIS=1 MAKEFLAGS='-j2' 2>&1 |ts -s '[%.T]'" + - "ccache -s" script: -- "curl -s https://raw.githubusercontent.com/mikkeloscar/arch-travis/master/arch-travis.sh | bash" -- "ls $(pwd)" +- "curl -s https://raw.githubusercontent.com/bartoszek/arch-travis/pacman-pkg-cache/arch-travis.sh | bash" +- "echo 'pacman pkg cache size: ' $(du -h .arch-cache|cut -f1) in $(ls .arch-cache|wc -l) files" deploy: - provider: script - script: bash .travis_deploy.sh on: branch: master skip_cleanup: true + provider: script + script: bash .travis_deploy.sh |