travis: fix cachix support

fixes #21
This commit is contained in:
Jörg Thalheim 2020-06-27 19:46:28 +01:00
parent 294d372fdf
commit cbd09dc9b7
No known key found for this signature in database
GPG key ID: 003F2096411B5F92

View file

@ -29,6 +29,9 @@ matrix:
install:
- nix --version
# for cachix we need travis to be a trusted nix user
- echo "trusted-users = $USER" | sudo tee -a /etc/nix/nix.conf
- sudo systemctl restart nix-daemon
- if [ -n "${CACHIX_CACHE}" ]; then travis_retry nix-channel --update; fi
- if [ -n "${CACHIX_CACHE}" ]; then nix-env -iA cachix -f https://cachix.org/api/v1/install; fi
- if [ -n "${CACHIX_CACHE}" ]; then cachix use "${CACHIX_CACHE}"; fi