Skip to content

Commit bffea0a

Browse files
author
R. Tyler Croy
authored
Merge pull request #57 from eddumelendez/sonarqube_example
Add SonarQube example
2 parents d029c85 + d65ef01 commit bffea0a

File tree

2 files changed

+22
-0
lines changed

2 files changed

+22
-0
lines changed
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
node {
2+
stage 'Checkout'
3+
4+
checkout scm
5+
6+
stage 'Gradle Static Analysis'
7+
withSonarQubeEnv {
8+
sh "./gradlew clean sonarqube"
9+
}
10+
}
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# Synopsis
2+
3+
Demonstrate an example of a Jenkinsfile to analyze and send results to SonarQube.
4+
5+
# Pre-requisites
6+
7+
- [SonarQube Plugin 2.5](https://wiki.jenkins-ci.org/display/JENKINS/SonarQube+plugin)
8+
9+
# Instructions
10+
11+
- `Manage Jenkins` > `Configure System` and set up `SonarQube Servers`
12+
- Create a new `Pipeline` job and set the url for your `SCM`, which contains the Jenkinsfile.

0 commit comments

Comments
 (0)