From dbd6ad2c7674e026a4dbfbb19b533834f29f2205 Mon Sep 17 00:00:00 2001 From: Josh Berdine Date: Tue, 26 Mar 2019 08:04:00 -0700 Subject: [PATCH] [infer][PR] replace travis script to enable caching Summary: Pull Request resolved: https://github.com/facebook/infer/pull/1075 Reviewed By: jvillard Differential Revision: D14587880 Pulled By: jberdine fbshipit-source-id: 3520b4392 --- .travis.yml | 25 +++++++++++++++++++++---- 1 file changed, 21 insertions(+), 4 deletions(-) diff --git a/.travis.yml b/.travis.yml index a5e524897..f6e21a952 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,9 +1,26 @@ language: c sudo: required -install: wget https://raw.githubusercontent.com/ocaml/ocaml-ci-scripts/master/.travis-opam.sh -script: bash -ex .travis-opam.sh env: - - OCAML_VERSION=4.07 TESTS=false + - OCAML_VERSION=4.07.1 +cache: + directories: + - ${HOME}/.opam + - facebook-clang-plugins +before_install: + - wget -O ${HOME}/opam https://github.com/ocaml/opam/releases/download/2.0.3/opam-2.0.3-x86_64-linux + - chmod +x ${HOME}/opam + - export PATH=${HOME}:${PATH} + - export OPAMYES=1 + - export OPAMJOBS=2 + - opam init --compiler=${OCAML_VERSION} --disable-sandboxing + - eval $(opam env) + - export OPAMVERBOSE=1 +install: + - opam update --upgrade + - opam pin add --no-action infer . + - opam depext --update infer + - opam install --deps-only infer +script: + - opam install infer os: - linux -- osx