optionally try covertiy_scan with every build on master
idea from https://github.com/umlaeute/Gem/blob/master/.travis.yml
This commit is contained in:
parent
491e5a47fc
commit
e1bc515363
36
.travis.yml
36
.travis.yml
@ -15,19 +15,17 @@ addons:
|
||||
- xsltproc
|
||||
- gengetopt
|
||||
- help2man
|
||||
coverity_scan:
|
||||
project:
|
||||
name: "OpenSC/OpenSC"
|
||||
description: "Build submitted via Travis CI"
|
||||
notification_email: viktor.tarasov@gmail.com
|
||||
build_command: "make -j 4"
|
||||
branch_pattern: coverity_scan
|
||||
|
||||
env:
|
||||
global:
|
||||
# The next declaration is the encrypted COVERITY_SCAN_TOKEN, created
|
||||
# via the "travis encrypt" command using the project repo's public key
|
||||
- secure: "UkHn7wy4im8V1nebCWbAetnDSOLRUbOlF6++ovk/7Bnso1/lnhXHelyzgRxfD/oI68wm9nnRV+RQEZ9+72Ug1CyvHxyyxxkwal/tPeHH4B/L+aGdPi0id+5OZSKIm77VP3m5s102sJMJgH7DFd03+nUd0K26p0tk8ad4j1geV4c="
|
||||
- COVERITY_SCAN_BRANCH_PATTERN="(master|coverity.*)"
|
||||
- COVERITY_SCAN_NOTIFICATION_EMAIL="viktor.tarasov@gmail.com"
|
||||
- COVERITY_SCAN_BUILD_COMMAND="make -j 4"
|
||||
- COVERITY_SCAN_PROJECT_NAME="$TRAVIS_REPO_SLUG"
|
||||
- SOURCE_DATE_EPOCH=$(git log -1 --pretty=%ct)
|
||||
|
||||
matrix:
|
||||
fast_finish: true
|
||||
@ -46,6 +44,8 @@ matrix:
|
||||
env: HOST=x86_64-w64-mingw32
|
||||
- os: linux
|
||||
env: HOST=i686-w64-mingw32
|
||||
- os: linux
|
||||
env: DO_COVERITY_SCAN=yes
|
||||
|
||||
before_install:
|
||||
- if [ "$TRAVIS_OS_NAME" == "osx" ]; then
|
||||
@ -56,10 +56,12 @@ before_install:
|
||||
fi
|
||||
|
||||
before_script:
|
||||
# we run a weekly cron job in travis on the coverity branch
|
||||
# just synchronize it with master to get a new report
|
||||
- if [ "${COVERITY_SCAN_BRANCH}" == 1 ]; then
|
||||
git reset --hard origin/master;
|
||||
- if [ "${DO_COVERITY_SCAN}" == "yes" ]; then
|
||||
if ! curl -s 'https://scan.coverity.com/scripts/travisci_build_coverity_scan.sh' | bash;
|
||||
# coverity could not be initialized; propably quota is exhausted
|
||||
# just continue with the normal CI build
|
||||
true;
|
||||
fi;
|
||||
fi
|
||||
- ./bootstrap
|
||||
- if [ -z "$HOST" ]; then
|
||||
@ -77,17 +79,21 @@ before_script:
|
||||
fi
|
||||
|
||||
script:
|
||||
- if [ "${COVERITY_SCAN_BRANCH}" != 1 ]; then
|
||||
- if [ "${DO_COVERITY_SCAN}" != "yes" ]; then
|
||||
if [ $TRAVIS_OS_NAME == osx ]; then
|
||||
./MacOSX/build;
|
||||
else
|
||||
make;
|
||||
if curl -s 'https://scan.coverity.com/scripts/travisci_build_coverity_scan.sh' | bash;
|
||||
make;
|
||||
else
|
||||
true;
|
||||
fi;
|
||||
fi;
|
||||
fi
|
||||
- if [ -z "$HOST" -a "${COVERITY_SCAN_BRANCH}" != 1 ]; then
|
||||
- if [ -z "$HOST" -a "${DO_COVERITY_SCAN}" != "yes" ]; then
|
||||
make check && make dist;
|
||||
fi
|
||||
- if [ ! -z "$HOST" -a "${COVERITY_SCAN_BRANCH}" != 1 ]; then
|
||||
- if [ ! -z "$HOST" -a "${DO_COVERITY_SCAN}" != "yes" ]; then
|
||||
make install;
|
||||
wine "C:/Program Files (x86)/Inno Setup 5/ISCC.exe" win32/OpenSC.iss;
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user