From 9e3bbdcf38c8cf4f3b38634e7ff977a9339a8f8f Mon Sep 17 00:00:00 2001 From: Alexey Sokolov Date: Mon, 23 Dec 2019 22:58:46 +0000 Subject: [PATCH] Travis: try to fix osx brew error by reinstalling brew --- .travis.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 15c48683..01ed0d12 100644 --- a/.travis.yml +++ b/.travis.yml @@ -114,10 +114,14 @@ install: - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sw_vers; fi - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sysctl -a | grep cpu; fi - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then sysctl -a | grep mem; fi + # Something broke in Travis brew making it impossible to update python versions (complaining about nil:NilClass), so remove preinstalled brew and install from scratch + - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then rm -rf /usr/local/Cellar/* /usr/local/opt/* /usr/local/share/aclocal; fi + - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"; hash -r; fi - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew config; fi - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew list --versions; fi - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew update; fi - - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install swig icu4c jq qt5 gettext; fi + - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install swig icu4c jq qt5 gettext python cmake openssl pkg-config; fi + - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install autoconf automake; fi - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew outdated python || brew upgrade python; fi - if [[ "$TRAVIS_OS_NAME" == "osx" && "$BUILD_WITH" == "cmake" ]]; then brew outdated cmake || brew upgrade cmake; fi - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew info --json=v1 --installed | jq .; fi