forked from spotbugs/sonar-findbugs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
38 lines (38 loc) · 1.67 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
language: java
dist: xenial
jdk:
- openjdk8
services:
- docker
env:
# minimal support version
- SONAR_VERSION=7.6 SONAR_JAVA_VERSION=5.10.1.16922
# latest LTS version
- SONAR_VERSION=7.9 SONAR_JAVA_VERSION=5.13.1.18282
# to reproduce https://github.com/spotbugs/sonar-findbugs/issues/263
- SONAR_VERSION=7.6 SONAR_JAVA_VERSION=5.12.1.17771
addons:
sonarcloud:
organization: "spotbugs"
token:
secure: "TO179WgRUyyT2Yg92FpC1r746GaHDMZ7+rMiBqnXztoj5VWTn8U0+M9edyxQ+cKZtCznC4JoimdjBhne52vauWFuQsoczrxtnN7l4w+yemC799Mm5jEuPKoId1CQZkVc5g4hmmeV4Qg6H5K1or1gnl+MGGZ9tbUYOu2v+G2SyAA="
install:
- if [ -n "$encrypted_71c23004c23b_key" ]; then openssl aes-256-cbc -K $encrypted_71c23004c23b_key -iv $encrypted_71c23004c23b_iv -in .travis/codesigning.asc.enc -out .travis/codesigning.asc -d; fi
- if [ -f ".travis/codesigning.asc" ]; then gpg --import .travis/codesigning.asc; fi
script:
- mvn verify -B -e -V -Dsonar.version=$SONAR_VERSION -Dsonar-java.version=$SONAR_JAVA_VERSION
jobs:
include:
- name: 'smoke test'
script:
- 'mvn package -B -V && docker-compose -f src/smoke-test/docker-compose.yml --project-directory . run --rm test-latest'
- stage: analysis
if: ( type = pull_request and head_repo =~ ^spotbugs/ ) or ( type != pull_request and repo =~ ^spotbugs/ )
script:
- mvn org.jacoco:jacoco-maven-plugin:prepare-agent verify sonar:sonar -B -e -V -Dsonar.version=$SONAR_VERSION -Dsonar-java.version=$SONAR_JAVA_VERSION
- stage: deploy
if: ( type != pull_request ) AND ( ( branch = master ) OR ( tag IS present ) )
script:
- mvn deploy -B -P deploy -s .travis/settings.xml
notifications:
email: false