From b8a502ae8724cf1e4b2d05d0e855dd33063ea77c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miloslav=20Trma=C4=8D?= Date: Thu, 19 Oct 2017 18:01:31 +0200 Subject: [PATCH] Work around broken brew in Travis MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Per https://github.com/Homebrew/brew/issues/3299 , (brew update) is needed to avoid a > ==> Downloading https://homebrew.bintray.com/bottles-portable/portable-ruby-2.3.3.leopard_64.bottle.1.tar.gz > ######################################################################## 100.0% > ==> Pouring portable-ruby-2.3.3.leopard_64.bottle.1.tar.gz ... > /usr/local/Homebrew/Library/Homebrew/brew.rb:12:in `
': Homebrew must be run under Ruby 2.3! You're running 2.0.0. (RuntimeError) Ideally Travis should bake the (brew update) into its images (https://github.com/travis-ci/travis-ci/issues/8552 ), but that’s only going to happen around November 2017 per https://blog.travis-ci.com/2017-10-16-a-new-default-os-x-image-is-coming . Until then, we have to do that ourselves. --- .travis.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 090b0c67ea..a69aa09933 100644 --- a/.travis.yml +++ b/.travis.yml @@ -11,7 +11,13 @@ notifications: email: false install: - - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install gpgme ; fi + # NOTE: The (brew update) should not be necessary, and slows things down; + # we include it as a workaround for https://github.com/Homebrew/brew/issues/3299 + # ideally Travis should bake the (brew update) into its images + # (https://github.com/travis-ci/travis-ci/issues/8552 ), but that’s only going + # to happen around November 2017 per https://blog.travis-ci.com/2017-10-16-a-new-default-os-x-image-is-coming . + # Remove the (brew update) at that time. + - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew update && brew install gpgme ; fi script: - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then hack/travis_osx.sh ; fi