Use plugin to automatically set version
@@ -10,13 +10,29 @@ plugins {
// files in 'workspace' build directory in CI
id 'com.github.sherter.google-java-format' version '0.8' apply false
id 'com.dorongold.task-tree' version '1.5'
+ id 'pl.allegro.tech.build.axion-release' version '1.9.3'
}
def isCI = System.getenv("CI") != null
+scmVersion {
+ tag {
+ prefix = 'v'
+ versionSeparator = ''
+ }
+
+ versionIncrementer 'incrementMinor'
+
+ checks {
+ uncommittedChanges = false
+ aheadOfRemote = true
+ snapshotDependencies = false
+ }
+}
+
allprojects {
group = 'com.datadoghq'
- version = '0.46.0-SNAPSHOT'
+ version = scmVersion.version
if (isCI) {
buildDir = "${rootDir}/workspace/${projectDir.path.replace(rootDir.path, '')}/build/"
