diff --git a/pom.xml b/pom.xml index 2f019e7f..19485797 100644 --- a/pom.xml +++ b/pom.xml @@ -72,6 +72,37 @@ + + pl.project13.maven + git-commit-id-plugin + 4.0.0 + + + get-the-git-infos + + revision + + initialize + + + + true + ${project.build.outputDirectory}/git.properties + + ^git.commit.time$ + ^git.commit.id.(abbrev|full)$ + + yyyyMMddHHmmss + UTC + + -devel + + full + true + true + false + + com.google.code.maven-replacer-plugin @@ -79,34 +110,55 @@ 1.5.3 + replace-swagger-ui generate-resources replace + false + + ${project.build.directory}/swagger-ui.unpacked/META-INF/resources/webjars/swagger-ui/${swagger-ui.version}/index.html + + + https://petstore.swagger.io/v2/swagger.json + /openapi.json + + + Swagger UI + API Documentation + + + deepLinking: true, + + deepLinking: true, + tagsSorter: "alpha", + operationsSorter: + "alpha", + + + + + + + replace-git-resources + generate-resources + + replace + + false + + ${project.build.outputDirectory}/git.properties + true + MULTILINE + + + ^(#.*$[\n\r]*) + + + + - - ${project.build.directory}/swagger-ui.unpacked/META-INF/resources/webjars/swagger-ui/${swagger-ui.version}/index.html - - - https://petstore.swagger.io/v2/swagger.json - /openapi.json - - - Swagger UI - API Documentation - - - deepLinking: true, - - deepLinking: true, - tagsSorter: "alpha", - operationsSorter: - "alpha", - - - - @@ -179,12 +231,18 @@ org.apache.maven.plugins maven-jar-plugin - 3.0.2 + 3.2.0 + false true + + ${git.commit.id.full} + ${git.commit.time} + true + @@ -208,6 +266,7 @@ META-INF/*.SF META-INF/*.DSA META-INF/*.RSA + **/*.js.map @@ -234,6 +293,23 @@ + + io.github.zlika + reproducible-build-maven-plugin + 0.11 + + + package + strip-jar + + strip-jar + + + ${git.commit.time} + + + + @@ -360,6 +436,16 @@ com.fasterxml.jackson.core jackson-annotations + + + io.netty + netty + + + + org.asynchttpclient + async-http-client + diff --git a/src/main/resources/build.properties b/src/main/resources/build.properties index 7d9b532d..4aee9ab8 100644 --- a/src/main/resources/build.properties +++ b/src/main/resources/build.properties @@ -1,2 +1,2 @@ -build.timestamp=${build.timestamp} -build.version=${project.version} +build.timestamp=${git.commit.time} +build.version=${project.version}-${git.commit.id.abbrev}