forked from EIPStackGroup/OpENer
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
60 lines (60 loc) · 2.49 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
sudo: false
os: linux
dist: trusty
language: c
branches:
except:
- gh-pages
env:
global:
- GH_REPO_NAME: OpENer
- DOXYFILE: opener.doxyfile
- GH_REPO_REF: github.com/EIPStackGroup/OpENer.git
- secure: h1vuX5cGZd5W7f5TitD+EamJIsvG2qq8aBpO9MUGIOj3bShwTaR0S0qbcpCyltXiZ9DJklLc7kP5kB0XtX1o6vZMelQsqBjiHQK5yFW0vHmFAg1sLMpVBbsAN0lMWgeGJEmyRstA1KYBixwExtc5GpcgMBvS/mnJQ10zboZNcRU=
- secure: CN1E5LJZwa7PLJOcst1MNb1c5Nx1rM9ifrc4llevRyTRyHxJ2S15mVQdnCvMcdPFK+ranBdsl1WcIxP3BQtI4zDwj0UWjj44EHz67VTp1o3zuaCa0fExYUwbe0D8uGRP4XbX+B4+HQWneGbabOLAZcS3Gc/pUpC3WEJO2pO2BHg=
addons:
apt:
packages:
- libcap-dev
- lcov
- doxygen
- doxygen-doc
- doxygen-latex
- doxygen-gui
- graphviz
sonarcloud:
organization: eipstackgroup
token: $SONAR_TOKEN
install:
- git fetch --unshallow --tags
- DEPS_DIR="${TRAVIS_BUILD_DIR}/deps"
- mkdir -p ${DEPS_DIR} && cd ${DEPS_DIR}
- |
if [[ "${TRAVIS_OS_NAME}" == "linux" ]]; then
CMAKE_URL="https://cmake.org/files/v3.7/cmake-3.7.2-Linux-x86_64.tar.gz"
mkdir cmake && travis_retry wget --no-check-certificate --quiet -O - ${CMAKE_URL} | tar --strip-components=1 -xz -C cmake
export PATH=${DEPS_DIR}/cmake/bin:${PATH}
else
brew upgrade cmake || brew install cmake
fi
cmake --version
before_script:
- cd $TRAVIS_BUILD_DIR/source
- chmod +x $TRAVIS_BUILD_DIR/travis_scripts/installCppUTestDependency.sh
- "$TRAVIS_BUILD_DIR/travis_scripts/installCppUTestDependency.sh"
script:
- cd $TRAVIS_BUILD_DIR/source
- cmake -DOpENer_PLATFORM:STRING="POSIX" -DCMAKE_BUILD_TYPE:STRING="Debug" -DOpENer_64_BIT_DATA_TYPES_ENABLED:BOOL=ON
-DOpENer_TESTS:BOOL=ON -DCPPUTEST_HOME:PATH=$TRAVIS_BUILD_DIR/source/dependencies/cpputest
-DCPPUTEST_LIBRARY:FILEPATH=$TRAVIS_BUILD_DIR/source/dependencies/cpputest/src/CppUTest/libCppUTest.a
-DCPPUTESTEXT_LIBRARY:FILEPATH=$TRAVIS_BUILD_DIR/source/dependencies/cpputest/src/CppUTestExt/libCppUTestExt.a .
- build-wrapper-linux-x86-64 --out-dir bw-output make all
- make test
- make OpENer_coverage
- chmod +x $TRAVIS_BUILD_DIR/travis_scripts/compileGcovResults.sh
- $TRAVIS_BUILD_DIR/travis_scripts/compileGcovResults.sh
- sonar-scanner -Dproject.settings=$TRAVIS_BUILD_DIR/sonar-project.properties -Dsonar.sources=. -Dsonar.exclusions=OpENer_coverage/**,dependencies/**,CMakeFiles/** -Dsonar.cfamily.gcov.reportsPath=./gcov_results
after_success:
- cd $TRAVIS_BUILD_DIR/source
- chmod +x $TRAVIS_BUILD_DIR/travis_scripts/generateDocumentationAndDeploy.sh
- "$TRAVIS_BUILD_DIR/travis_scripts/generateDocumentationAndDeploy.sh"