From: Luca Heltai Date: Sun, 26 Jul 2015 18:59:05 +0000 (+0200) Subject: Updated travis config. X-Git-Tag: v8.4.0-rc2~717^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F1199%2Fhead;p=dealii.git Updated travis config. --- diff --git a/.travis.yml b/.travis.yml index aa013ce482..d711326c09 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,11 +1,23 @@ +sudo : false + +notifications: + email: false + language: C++ compiler: -- gcc + - gcc + +cache: + directories: + - programs -before_install: ./contrib/utilities/setup_astyle.sh +install: + - export PATH=$PWD/programs/astyle/build/gcc/bin:$PATH + - ./contrib/utilities/setup_astyle.sh -script: ./contrib/utilities/check_indentation.sh +script: + - ./contrib/utilities/check_indentation.sh branches: only: diff --git a/contrib/utilities/check_indentation.sh b/contrib/utilities/check_indentation.sh index abca027318..7a859c98e3 100755 --- a/contrib/utilities/check_indentation.sh +++ b/contrib/utilities/check_indentation.sh @@ -6,8 +6,6 @@ else echo "Running indentation test on Pull Request #${TRAVIS_PULL_REQUEST}" fi -export PATH=`pwd`/astyle/build/gcc/bin:$PATH - ./contrib/utilities/indent git diff git diff-files --quiet diff --git a/contrib/utilities/setup_astyle.sh b/contrib/utilities/setup_astyle.sh index cb1488595e..4f0f53dc70 100755 --- a/contrib/utilities/setup_astyle.sh +++ b/contrib/utilities/setup_astyle.sh @@ -1,8 +1,20 @@ #!/bin/sh -echo "Downloading and installing astyle." -wget http://downloads.sourceforge.net/project/astyle/astyle/astyle%202.04/astyle_2.04_linux.tar.gz > /dev/null -tar xvfz astyle_2.04_linux.tar.gz > /dev/null -cd astyle/build/gcc -make -j4 > /dev/null -cd ../../../ -export PATH=`pwd`/astyle/build/gcc/bin:$PATH + +PRG=$PWD/programs + +if [ ! -d $PRG ] +then + echo "create folder `$PRG`" + mkdir $PRG +fi + +# astyle +if [ ! -d $PRG/astyle ] +then + echo "Downloading and installing astyle." + mkdir $PRG/astyle + wget http://downloads.sourceforge.net/project/astyle/astyle/astyle%202.04/astyle_2.04_linux.tar.gz > /dev/null + tar xfz astyle_2.04_linux.tar.gz -C $PRG > /dev/null + cd $PRG/astyle/build/gcc + make -j4 > /dev/null +fi