A gradle plugin that automatically applies conventions and/or opinions based on the plugins that are applied to your project.
You can choose to apply only the development conventions, which are simple integrations between different plugins.
plugins {
// See https://plugins.gradle.org/plugin/be.vbgn.dev-conventions for the latest version
id "be.vbgn.dev-conventions" version "0.4.0"
}You can also choose to apply the development opinions, which are my opinions about how some things should be configured.
plugins {
// See https://plugins.gradle.org/plugin/be.vbgn.dev-conventions.opinion for the latest version
id "be.vbgn.dev-conventions.opinion" version "0.4.0"
}- Integration between
jacocoandorg.sonarqubeplugins: makessonarqubetask depend on all jacoco reports, and ensures that jacoco reports are generated in XML, for sonarqube to consume. - Integration between
org.sonarqubeandbe.vbgn.ci-detectplugins: Configures sonarqube extension to have the right branch name or pull request information. - The
jacocoplugin:jacoco*Reportandjacoco*CoverageVerificationtasks are created for all tasks of typeTest - All
Testtasks: run tests in parallel, as many as there are processors in the machine.- The number of parallel forks is configurable with
the
be.vbgn.dev-conventions.ParallelTestsConvention.max-parallel-forksproperty. - When the
be.vbgn.ci-detectplugin is applied and it detects that it is not running on a CI system, tests are run in parallel with half of the available processors. This is done to avoid bogging down a developer's machine too much.
- The number of parallel forks is configurable with
the
- The
org.ajoberstar.reckonplugin: Is configured withscopeFromProp()andsnapshotFromProp(). Before a tag can be created withreckonTagCreate, thechecktask must complete succesfully. - All
Test-type tasks are configured in fail-fast mode when a CI environment is detected - The
checktask depends on all tasks of typeTest - The
maven-publishandbe.vbgn.ci-detectplugins, running on Github Actions and theGITHUB_TOKENenvironment variable is available: Automatically configure a publication repository namedGithubPackages.
Opinions can be disabled with the be.vbgn.dev-conventions.disable property by listing a comma-separated list of
Opinion names to disable.