Move coveralls to after_success in Travis CI
So it won't affect the build result
This commit is contained in:
parent
533716c6c0
commit
3bde4dd751
3 changed files with 24 additions and 14 deletions
18
.travis.yml
18
.travis.yml
|
@ -33,6 +33,8 @@ addons:
|
||||||
- libgtest-dev
|
- libgtest-dev
|
||||||
- gcc-10
|
- gcc-10
|
||||||
- g++-10
|
- g++-10
|
||||||
|
- python3-pip
|
||||||
|
- python3-setuptools
|
||||||
homebrew:
|
homebrew:
|
||||||
packages:
|
packages:
|
||||||
- autoconf
|
- autoconf
|
||||||
|
@ -55,7 +57,7 @@ addons:
|
||||||
|
|
||||||
env:
|
env:
|
||||||
- ''
|
- ''
|
||||||
- BUILD_SUIT=autotools
|
- BUILD_SUIT=autotools WITH_COVERALLS=y
|
||||||
- CC=gcc-10 CXX=g++-10
|
- CC=gcc-10 CXX=g++-10
|
||||||
- BUILD_SUIT=autotools CC=gcc-10 CXX=g++-10
|
- BUILD_SUIT=autotools CC=gcc-10 CXX=g++-10
|
||||||
|
|
||||||
|
@ -69,7 +71,7 @@ install:
|
||||||
- ./.travis/install.sh
|
- ./.travis/install.sh
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- if [ $TRAVIS_OS_NAME = 'osx' ]; then
|
- if [ "$TRAVIS_OS_NAME" = 'osx' ]; then
|
||||||
export PATH="/usr/local/opt/gettext/bin:/usr/local/opt/icu4c/sbin:/usr/local/opt/icu4c/bin:$PATH";
|
export PATH="/usr/local/opt/gettext/bin:/usr/local/opt/icu4c/sbin:/usr/local/opt/icu4c/bin:$PATH";
|
||||||
export CPPFLAGS="-I/usr/local/opt/gettext/include -I/usr/local/opt/icu4c/include";
|
export CPPFLAGS="-I/usr/local/opt/gettext/include -I/usr/local/opt/icu4c/include";
|
||||||
export LDFLAGS="-L/usr/local/opt/gettext/lib -L/usr/local/opt/icu4c/lib";
|
export LDFLAGS="-L/usr/local/opt/gettext/lib -L/usr/local/opt/icu4c/lib";
|
||||||
|
@ -79,14 +81,15 @@ script:
|
||||||
./configure --enable-debug || cat config.log;
|
./configure --enable-debug || cat config.log;
|
||||||
make -j2 || travis_terminate 1;
|
make -j2 || travis_terminate 1;
|
||||||
make test || travis_terminate 1;
|
make test || travis_terminate 1;
|
||||||
elif [ "$BUILD_SUIT" = "autotools" ]; then
|
elif [ "$BUILD_SUIT" = 'autotools' ]; then
|
||||||
export CPPFLAGS="-fprofile-arcs -ftest-coverage";
|
if [ ! -z "$WITH_COVERALLS" ]; then
|
||||||
|
export CPPFLAGS="--coverage";
|
||||||
export LIBS="-lgcov";
|
export LIBS="-lgcov";
|
||||||
|
fi;
|
||||||
./autogen.sh;
|
./autogen.sh;
|
||||||
./configure --enable-debug || cat config.log;
|
./configure --enable-debug || cat config.log;
|
||||||
make -j2 || travis_terminate 1;
|
make -j2 || travis_terminate 1;
|
||||||
make test || travis_terminate 1;
|
make test || travis_terminate 1;
|
||||||
coveralls --exclude vendor --exclude src --exclude build --exclude tools --exclude libaegisub/windows > /dev/null;
|
|
||||||
else
|
else
|
||||||
mkdir build-dir;
|
mkdir build-dir;
|
||||||
cd build-dir;
|
cd build-dir;
|
||||||
|
@ -94,3 +97,8 @@ script:
|
||||||
make -j2 || travis_terminate 1;
|
make -j2 || travis_terminate 1;
|
||||||
make test || travis_terminate 1;
|
make test || travis_terminate 1;
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
after_success:
|
||||||
|
- if [ ! -z "$WITH_COVERALLS" ]; then
|
||||||
|
coveralls --exclude vendor --exclude src --exclude build --exclude tools --exclude libaegisub/windows > /dev/null;
|
||||||
|
fi
|
||||||
|
|
|
@ -6,14 +6,16 @@ if [ "$TRAVIS_OS_NAME" = 'linux' ]; then
|
||||||
# Remove the CMake provided by travis
|
# Remove the CMake provided by travis
|
||||||
sudo rm -rf /usr/local/cmake*
|
sudo rm -rf /usr/local/cmake*
|
||||||
if [ "$BUILD_SUIT" = 'autotools' ]; then
|
if [ "$BUILD_SUIT" = 'autotools' ]; then
|
||||||
sudo pip install -U cpp-coveralls;
|
if [ ! -z "$WITH_COVERALLS" ]; then
|
||||||
git submodule --quiet init;
|
sudo pip3 install -U cpp-coveralls
|
||||||
git submodule --quiet update vendor/googletest;
|
fi
|
||||||
|
git submodule --quiet init
|
||||||
|
git submodule --quiet update vendor/googletest
|
||||||
else
|
else
|
||||||
pushd /usr/src/googletest;
|
pushd /usr/src/googletest
|
||||||
sudo cmake .;
|
sudo cmake .
|
||||||
sudo make install -j2;
|
sudo make install -j2
|
||||||
popd;
|
popd
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
sudo luarocks install busted > /dev/null
|
sudo luarocks install busted > /dev/null
|
||||||
|
|
|
@ -38,7 +38,7 @@ and optional dependencies:
|
||||||
You can use the package manager provided by your distro to install these dependencies. Package name varies by distro. Some useful references are:
|
You can use the package manager provided by your distro to install these dependencies. Package name varies by distro. Some useful references are:
|
||||||
|
|
||||||
* For ArchLinux, refer to [AUR](https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=aegisub-git).
|
* For ArchLinux, refer to [AUR](https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=aegisub-git).
|
||||||
* For Ubuntu, refer to [Travis](.travis.yml#L14-L35).
|
* For Ubuntu, refer to [Travis](.travis.yml#L14-L32).
|
||||||
* For macOS, see [Special notice for macOS](https://github.com/wangqr/Aegisub/wiki/Special-notice-for-macOS) on project Wiki.
|
* For macOS, see [Special notice for macOS](https://github.com/wangqr/Aegisub/wiki/Special-notice-for-macOS) on project Wiki.
|
||||||
|
|
||||||
After installing the dependencies, you can clone and build Aegisub with:
|
After installing the dependencies, you can clone and build Aegisub with:
|
||||||
|
|
Loading…
Reference in a new issue