Skip to content

A library for commenting Bitbucket Server with violations from static code analyzer reports.

License

Notifications You must be signed in to change notification settings

tomasbjerre/violation-comments-to-bitbucket-server-lib

Repository files navigation

Violation Comments to Bitbucket Server Lib

Maven Central

This is a library that adds violation comments from static code analysis to Bitbucket Server.

It uses Violation Comments Lib and supports the same formats as Violations Lib.

Very easy to use with a nice builder pattern

  violationCommentsToBitbucketServerApi() //
    .withViolations(".*/findbugs/.*\\.xml$", FINDBUGS, rootFolder) //
    .withViolations(".*/checkstyle/.*\\.xml$", CHECKSTYLE, rootFolder) //
    .withUsername("username")
    .withPassword("password")
    .withProjectKey("projectKey")
    .withRepoSlug("repoSlug")
    .withPullRequestId("pullRequestId")
    .toPullRequest();

Usage

This software can be used:

Properties

It can be configured with some Java properties:

  • VIOLATIONS_KEYSTORE_PATH - A path to a keystore.
  • VIOLATIONS_KEYSTORE_PASS - Password for the keystore.
  • VIOLATIONS_PAT - Personal access token used to authenticate.
  • VIOLATIONS_USERNAME - Username to authenticate with.
  • VIOLATIONS_PASSWORD - Password to authenticate with.

Developer instructions

To build the code, have a look at .travis.yml.

To do a release you need to do ./gradlew release and release the artifact from staging. More information here.

About

A library for commenting Bitbucket Server with violations from static code analyzer reports.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages