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
jacoco
andorg.sonarqube
plugins: makessonarqube
task depend on all jacoco reports, and ensures that jacoco reports are generated in XML, for sonarqube to consume. - Integration between
org.sonarqube
andbe.vbgn.ci-detect
plugins: Configures sonarqube extension to have the right branch name or pull request information. - The
jacoco
plugin:jacoco*Report
andjacoco*CoverageVerification
tasks are created for all tasks of typeTest
- All
Test
tasks: 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-forks
property. - When the
be.vbgn.ci-detect
plugin 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.reckon
plugin: Is configured withscopeFromProp()
andsnapshotFromProp()
. Before a tag can be created withreckonTagCreate
, thecheck
task must complete succesfully. - All
Test
-type tasks are configured in fail-fast mode when a CI environment is detected - The
check
task depends on all tasks of typeTest
- The
maven-publish
andbe.vbgn.ci-detect
plugins, running on Github Actions and theGITHUB_TOKEN
environment 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.