Hi,
I have written a plugin that looks up the last published version in our repository and modifies the version-attribute in the build accordingly. In the build.gradle.kts a version = “0.1.+” get replaced with the correct buildnumber 0.1.4
Currently I execute it at project.afterEvaluate {}. But when I let Gradle generate the PluginMarkerMaven.pom for this project, the new version number appears correctly in the Tag of the plugin itself, but not in the -tag of the dependency to the plugin-jar.
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>t31.plugins.versionnumber</groupId>
<artifactId>t31.plugins.versionnumber.gradle.plugin</artifactId>
<version>0.1.4</version>
<packaging>pom</packaging>
<dependencies>
<dependency>
<groupId>de.t31</groupId>
<artifactId>t31plugins</artifactId>
<version>0.1.+</version>
</dependency>
</dependencies>
</project>
Is there a way to execute this right after the project-properties are set and before any other plugin uses them?