diff --git a/.mvn/maven.config b/.mvn/maven.config index c82f2d0..d21c4e3 100644 --- a/.mvn/maven.config +++ b/.mvn/maven.config @@ -1,2 +1,3 @@ -Dorg.slf4j.simpleLogger.showDateTime=true -Dorg.slf4j.simpleLogger.dateTimeFormat=HH:mm:ss,SSS +-ntp diff --git a/pom.xml b/pom.xml index a840fd4..3d90fa8 100644 --- a/pom.xml +++ b/pom.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8"?> -<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 http://maven.apache.org/xsd/maven-4.0.0.xsd"> +<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 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>io.github.rabobank</groupId> <artifactId>ret</artifactId> - <version>0.2.1-SNAPSHOT-SNAPSHOT</version> + <version>0.2.1-SNAPSHOT</version> <packaging>pom</packaging> <name>RET Engineering Tools</name> <url>https://github.com/rabobank/ret-engineering-tools</url> @@ -33,8 +34,8 @@ <modules> <module>ret-core</module> - <module>ret-cli</module> <module>ret-plugin</module> + <module>ret-cli</module> </modules> <properties> @@ -52,6 +53,7 @@ <ktlint-maven-plugin.version>2.0.0</ktlint-maven-plugin.version> <maven-assembly-plugin.version>3.6.0</maven-assembly-plugin.version> <maven-deploy-plugin.version>3.1.1</maven-deploy-plugin.version> + <maven-jar-plugin.version>3.3.0</maven-jar-plugin.version> <maven-release-plugin.version>3.0.1</maven-release-plugin.version> <maven-resources-plugin.version>3.3.1</maven-resources-plugin.version> <maven-source-plugin.version>3.3.0</maven-source-plugin.version> @@ -152,7 +154,8 @@ <consoleOutputReporter> <disable>true</disable> </consoleOutputReporter> - <statelessTestsetInfoReporter implementation="org.apache.maven.plugin.surefire.extensions.junit5.JUnit5StatelessTestsetInfoTreeReporter"> + <statelessTestsetInfoReporter + implementation="org.apache.maven.plugin.surefire.extensions.junit5.JUnit5StatelessTestsetInfoTreeReporter"> <theme>UNICODE</theme> </statelessTestsetInfoReporter> </configuration> @@ -290,23 +293,6 @@ </execution> </executions> </plugin> - <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-source-plugin</artifactId> - <version>${maven-source-plugin.version}</version> - <executions> - <execution> - <id>attach-sources</id> - <goals> - <goal>jar</goal> - </goals> - <configuration> - <attach>true</attach> - </configuration> - </execution> - </executions> - </plugin> - <plugin> <groupId>org.jreleaser</groupId> <artifactId>jreleaser-maven-plugin</artifactId> @@ -395,29 +381,6 @@ <artifactId>maven-deploy-plugin</artifactId> <version>${maven-deploy-plugin.version}</version> </plugin> - <plugin> - <groupId>org.jetbrains.dokka</groupId> - <artifactId>dokka-maven-plugin</artifactId> - <version>${dokka-maven-plugin.version}</version> - <executions> - <execution> - <id>javadoc-jar</id> - <phase>package</phase> - <goals> - <goal>javadocJar</goal> - </goals> - </execution> - <execution> - <phase>pre-site</phase> - <goals> - <goal>dokka</goal> - </goals> - </execution> - </executions> - <configuration> - <outputDir>${project.basedir}/target/apidocs</outputDir> - </configuration> - </plugin> <plugin> <groupId>com.github.gantsign.maven</groupId> <artifactId>ktlint-maven-plugin</artifactId> @@ -483,6 +446,21 @@ <propertiesEncoding>${project.build.sourceEncoding}</propertiesEncoding> </configuration> </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-source-plugin</artifactId> + <version>${maven-source-plugin.version}</version> + </plugin> + <plugin> + <groupId>org.jetbrains.dokka</groupId> + <artifactId>dokka-maven-plugin</artifactId> + <version>${dokka-maven-plugin.version}</version> + </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-javadoc-plugin</artifactId> + <version>${maven-javadoc-plugin.version}</version> + </plugin> </plugins> </pluginManagement> </build> @@ -495,16 +473,57 @@ </properties> <build> <defaultGoal>deploy</defaultGoal> - <plugins> - <plugin> - <groupId>org.jetbrains.dokka</groupId> - <artifactId>dokka-maven-plugin</artifactId> - </plugin> - <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-source-plugin</artifactId> - </plugin> - </plugins> + <pluginManagement> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-source-plugin</artifactId> + <executions> + <execution> + <id>attach-sources</id> + <phase>verify</phase> + <goals> + <goal>jar-no-fork</goal> + </goals> + </execution> + </executions> + </plugin> + <plugin> + <groupId>org.jetbrains.dokka</groupId> + <artifactId>dokka-maven-plugin</artifactId> + <executions> + <execution> + <phase>verify</phase> + <goals> + <goal>dokka</goal> + </goals> + </execution> + </executions> + <configuration> + <outputDir>${project.build.directory}/apidocs</outputDir> + </configuration> + </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-jar-plugin</artifactId> + <version>${maven-jar-plugin.version}</version> + <executions> + <execution> + <id>attach-javadocs</id> + <phase>verify</phase> + <goals> + <goal>jar</goal> + </goals> + <configuration> + <classifier>javadoc</classifier> + <classesDirectory>${project.build.directory}/apidocs</classesDirectory> + <skipIfEmpty>true</skipIfEmpty> + </configuration> + </execution> + </executions> + </plugin> + </plugins> + </pluginManagement> </build> </profile> </profiles> diff --git a/ret-cli/pom.xml b/ret-cli/pom.xml index be48689..66ddf38 100644 --- a/ret-cli/pom.xml +++ b/ret-cli/pom.xml @@ -4,7 +4,7 @@ <parent> <groupId>io.github.rabobank</groupId> <artifactId>ret</artifactId> - <version>0.2.1-SNAPSHOT-SNAPSHOT</version> + <version>0.2.1-SNAPSHOT</version> </parent> <artifactId>ret-cli</artifactId> diff --git a/ret-core/pom.xml b/ret-core/pom.xml index 86dc49a..3f03b62 100644 --- a/ret-core/pom.xml +++ b/ret-core/pom.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8"?> -<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 http://maven.apache.org/xsd/maven-4.0.0.xsd"> +<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 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <parent> <groupId>io.github.rabobank</groupId> <artifactId>ret</artifactId> - <version>0.2.1-SNAPSHOT-SNAPSHOT</version> + <version>0.2.1-SNAPSHOT</version> </parent> <artifactId>ret-core</artifactId> @@ -89,4 +90,26 @@ </plugin> </plugins> </build> + + <profiles> + <profile> + <id>publication</id> + <build> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-source-plugin</artifactId> + </plugin> + <plugin> + <groupId>org.jetbrains.dokka</groupId> + <artifactId>dokka-maven-plugin</artifactId> + </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-jar-plugin</artifactId> + </plugin> + </plugins> + </build> + </profile> + </profiles> </project> diff --git a/ret-plugin/pom.xml b/ret-plugin/pom.xml index 3a6c61b..8cda05a 100644 --- a/ret-plugin/pom.xml +++ b/ret-plugin/pom.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8"?> -<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 http://maven.apache.org/xsd/maven-4.0.0.xsd"> +<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 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <parent> <groupId>io.github.rabobank</groupId> <artifactId>ret</artifactId> - <version>0.2.1-SNAPSHOT-SNAPSHOT</version> + <version>0.2.1-SNAPSHOT</version> </parent> <artifactId>ret-plugin</artifactId> @@ -100,4 +101,25 @@ </plugins> </build> + <profiles> + <profile> + <id>publication</id> + <build> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-source-plugin</artifactId> + </plugin> + <plugin> + <groupId>org.jetbrains.dokka</groupId> + <artifactId>dokka-maven-plugin</artifactId> + </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-jar-plugin</artifactId> + </plugin> + </plugins> + </build> + </profile> + </profiles> </project>