gabrie-allaigre / sonar-gitlab-plugin

Add to each commit GitLab in a global commentary on the new anomalies added by this commit and add comment lines of modified files
GNU Lesser General Public License v3.0
713 stars 207 forks source link

Adding support for NONE in QualityGateFailMode #206

Closed lfojacintho closed 5 years ago

lfojacintho commented 5 years ago

This PR adds the support for the NONE option on the plugin property sonar.gitlab.quality_gate_fail_mode.

Using this new mode, the plugin will ignore the Quality Gate from Sonar to break the build. This is very handy when you're using Sonarqube with Branches plugin, as the short-lived branch have only a hard-coded quality gate.

This new property allows you to customize the "Quality Gate" of your short-lived branch, by ignoring the one from Sonar and setting up your own via plugin properties sonar.gitlab.max_*_issues_gate.

This PR is related to Issue #204

famlima commented 5 years ago

Hi, I'd like to have this feature too. I want to be able to pass my branche's build if sonar scan detect issues.

lfojacintho commented 5 years ago

@famlima Cool. We're using on our company and it helped us a lot to customize our own Quality Gate, instead of relying on Sonar limitations (hardcoded Quality Gate for short-lived branches).

We had to build and deploy the customised version, tho. It's not great, but works as a temp solution until it's merged to the main lib