|
| 1 | +<?xml version="1.0" encoding="UTF-8"?> |
| 2 | +<project xmlns="http://maven.apache.org/POM/4.0.0" |
| 3 | + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| 4 | + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> |
| 5 | + <modelVersion>4.0.0</modelVersion> |
| 6 | + <groupId>{{cookiecutter.group_id}}</groupId> |
| 7 | + <artifactId>{{cookiecutter.artifact_id}}</artifactId> |
| 8 | + <packaging>pom</packaging> |
| 9 | + <version>1.0-SNAPSHOT</version> |
| 10 | + <properties> |
| 11 | + <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> |
| 12 | + <java.version>21</java.version> |
| 13 | + <maven.compiler.source>${java.version}</maven.compiler.source> |
| 14 | + <maven.compiler.target>${java.version}</maven.compiler.target> |
| 15 | + <junit-jupiter.version>5.11.3</junit-jupiter.version> |
| 16 | + <spring-boot.version>3.3.5</spring-boot.version> |
| 17 | + <cucumber.version>7.20.1</cucumber.version> |
| 18 | + <springdoc-openapi-starter.version>2.6.0</springdoc-openapi-starter.version> |
| 19 | + <pre-liquibase.version>1.5.1</pre-liquibase.version> |
| 20 | + <otj-pg-embedded.version>1.1.0</otj-pg-embedded.version> |
| 21 | + <snakeyaml.version>2.3</snakeyaml.version> |
| 22 | + <h2.version>2.3.232</h2.version> |
| 23 | + <!-- plugins --> |
| 24 | + <cukedoctor-maven-plugin.version>3.9.0</cukedoctor-maven-plugin.version> |
| 25 | + <maven-surefire-plugin.version>3.5.2</maven-surefire-plugin.version> |
| 26 | + <maven-enforcer-plugin>3.5.0</maven-enforcer-plugin> |
| 27 | + <arch-unit-maven-plugin.version>4.0.2</arch-unit-maven-plugin.version> |
| 28 | + <jacoco-maven-plugin.version>0.8.12</jacoco-maven-plugin.version> |
| 29 | + <maven-compiler-plugin.version>3.13.0</maven-compiler-plugin.version> |
| 30 | + <jib-maven.plugin.version>3.4.4</jib-maven.plugin.version> |
| 31 | + <git-code-format-maven-plugin.version>5.3</git-code-format-maven-plugin.version> |
| 32 | + <githook-maven-plugin.version>1.0.5</githook-maven-plugin.version> |
| 33 | + <pitest-maven-plugin.version>1.17.1</pitest-maven-plugin.version> |
| 34 | + <pitest-junit5-plugin.version>1.2.1</pitest-junit5-plugin.version> |
| 35 | + </properties> |
| 36 | + <!--<modules> |
| 37 | + <module>domain</module> |
| 38 | + <module>domain-api</module> |
| 39 | + <module>rest-adapter</module> |
| 40 | + <module>jpa-adapter</module> |
| 41 | + <module>bootstrap</module> |
| 42 | + <module>acceptance-test</module> |
| 43 | + </modules>--> |
| 44 | + <dependencyManagement> |
| 45 | + <dependencies> |
| 46 | + <!-- Frameworks & Libraries --> |
| 47 | + <dependency> |
| 48 | + <groupId>org.junit</groupId> |
| 49 | + <artifactId>junit-bom</artifactId> |
| 50 | + <version>${junit-jupiter.version}</version> |
| 51 | + <type>pom</type> |
| 52 | + <scope>import</scope> |
| 53 | + </dependency> |
| 54 | + <dependency> |
| 55 | + <groupId>org.springframework.boot</groupId> |
| 56 | + <artifactId>spring-boot-dependencies</artifactId> |
| 57 | + <version>${spring-boot.version}</version> |
| 58 | + <type>pom</type> |
| 59 | + <scope>import</scope> |
| 60 | + </dependency> |
| 61 | + </dependencies> |
| 62 | + </dependencyManagement> |
| 63 | + <dependencies> |
| 64 | + <!-- lombok --> |
| 65 | + <dependency> |
| 66 | + <groupId>org.projectlombok</groupId> |
| 67 | + <artifactId>lombok</artifactId> |
| 68 | + <scope>provided</scope> |
| 69 | + </dependency> |
| 70 | + <!-- JUnit 5 dependencies --> |
| 71 | + <dependency> |
| 72 | + <groupId>org.junit.jupiter</groupId> |
| 73 | + <artifactId>junit-jupiter</artifactId> |
| 74 | + <scope>test</scope> |
| 75 | + </dependency> |
| 76 | + <dependency> |
| 77 | + <groupId>org.junit.platform</groupId> |
| 78 | + <artifactId>junit-platform-suite</artifactId> |
| 79 | + <scope>test</scope> |
| 80 | + </dependency> |
| 81 | + <!-- mockito dependencies --> |
| 82 | + <dependency> |
| 83 | + <groupId>org.mockito</groupId> |
| 84 | + <artifactId>mockito-core</artifactId> |
| 85 | + <scope>test</scope> |
| 86 | + </dependency> |
| 87 | + <dependency> |
| 88 | + <groupId>org.mockito</groupId> |
| 89 | + <artifactId>mockito-junit-jupiter</artifactId> |
| 90 | + <scope>test</scope> |
| 91 | + </dependency> |
| 92 | + </dependencies> |
| 93 | + <build> |
| 94 | + <finalName>${project.artifactId}</finalName> |
| 95 | + <directory>target</directory> |
| 96 | + <outputDirectory>target/classes</outputDirectory> |
| 97 | + <testOutputDirectory>target/test-classes</testOutputDirectory> |
| 98 | + <sourceDirectory>src/main/java</sourceDirectory> |
| 99 | + <testSourceDirectory>src/test/java</testSourceDirectory> |
| 100 | + <resources> |
| 101 | + <resource> |
| 102 | + <directory>src/main/resources</directory> |
| 103 | + </resource> |
| 104 | + </resources> |
| 105 | + <testResources> |
| 106 | + <testResource> |
| 107 | + <directory>src/test/resources</directory> |
| 108 | + </testResource> |
| 109 | + </testResources> |
| 110 | + <plugins> |
| 111 | + <plugin> |
| 112 | + <groupId>org.apache.maven.plugins</groupId> |
| 113 | + <artifactId>maven-compiler-plugin</artifactId> |
| 114 | + <version>${maven-compiler-plugin.version}</version> |
| 115 | + <configuration> |
| 116 | + <source>${java.version}</source> <!-- 1.8,1.9,1.10,11,12,13 --> |
| 117 | + <target>${java.version}</target> |
| 118 | + </configuration> |
| 119 | + </plugin> |
| 120 | + <plugin> |
| 121 | + <groupId>org.apache.maven.plugins</groupId> |
| 122 | + <artifactId>maven-surefire-plugin</artifactId> |
| 123 | + <version>${maven-surefire-plugin.version}</version> |
| 124 | + <configuration> |
| 125 | + <testFailureIgnore>false</testFailureIgnore> |
| 126 | + </configuration> |
| 127 | + </plugin> |
| 128 | + <plugin> |
| 129 | + <groupId>org.jacoco</groupId> |
| 130 | + <artifactId>jacoco-maven-plugin</artifactId> |
| 131 | + <executions> |
| 132 | + <execution> |
| 133 | + <goals> |
| 134 | + <goal>prepare-agent</goal> |
| 135 | + </goals> |
| 136 | + </execution> |
| 137 | + <execution> |
| 138 | + <id>report</id> |
| 139 | + <phase>test</phase> |
| 140 | + <goals> |
| 141 | + <goal>report</goal> |
| 142 | + </goals> |
| 143 | + </execution> |
| 144 | + </executions> |
| 145 | + </plugin> |
| 146 | + <plugin> |
| 147 | + <groupId>org.apache.maven.plugins</groupId> |
| 148 | + <artifactId>maven-enforcer-plugin</artifactId> |
| 149 | + <version>${maven-enforcer-plugin}</version> |
| 150 | + <configuration> |
| 151 | + <rules> |
| 152 | + <dependencyConvergence/> |
| 153 | + <requireReleaseDeps> |
| 154 | + <failWhenParentIsSnapshot>false</failWhenParentIsSnapshot> |
| 155 | + <excludes> |
| 156 | + <exclude>${project.groupId}:*</exclude> |
| 157 | + </excludes> |
| 158 | + </requireReleaseDeps> |
| 159 | + </rules> |
| 160 | + <fail>true</fail> |
| 161 | + </configuration> |
| 162 | + <executions> |
| 163 | + <execution> |
| 164 | + <id>enforce-versions</id> |
| 165 | + <goals> |
| 166 | + <goal>enforce</goal> |
| 167 | + </goals> |
| 168 | + <phase>validate</phase> |
| 169 | + </execution> |
| 170 | + </executions> |
| 171 | + </plugin> |
| 172 | + <plugin> |
| 173 | + <groupId>com.cosium.code</groupId> |
| 174 | + <artifactId>git-code-format-maven-plugin</artifactId> |
| 175 | + <version>${git-code-format-maven-plugin.version}</version> |
| 176 | + <executions> |
| 177 | + <!-- On commit, format the modified java files --> |
| 178 | + <execution> |
| 179 | + <id>install-formatter-hook</id> |
| 180 | + <goals> |
| 181 | + <goal>install-hooks</goal> |
| 182 | + </goals> |
| 183 | + </execution> |
| 184 | + <!-- On Maven verify phase, fail if any file |
| 185 | + (including unmodified) is badly formatted --> |
| 186 | + <execution> |
| 187 | + <id>validate-code-format</id> |
| 188 | + <goals> |
| 189 | + <goal>validate-code-format</goal> |
| 190 | + </goals> |
| 191 | + </execution> |
| 192 | + </executions> |
| 193 | + <dependencies> |
| 194 | + <!-- Enable https://github.com/google/google-java-format --> |
| 195 | + <dependency> |
| 196 | + <groupId>com.cosium.code</groupId> |
| 197 | + <artifactId>google-java-format</artifactId> |
| 198 | + <version>${git-code-format-maven-plugin.version}</version> |
| 199 | + </dependency> |
| 200 | + </dependencies> |
| 201 | + </plugin> |
| 202 | + <plugin> |
| 203 | + <groupId>io.github.phillipuniverse</groupId> |
| 204 | + <artifactId>githook-maven-plugin</artifactId> |
| 205 | + <version>${githook-maven-plugin.version}</version> |
| 206 | + <executions> |
| 207 | + <execution> |
| 208 | + <goals> |
| 209 | + <goal>install</goal> |
| 210 | + </goals> |
| 211 | + <configuration> |
| 212 | + <hooks> |
| 213 | + <pre-commit> |
| 214 | + echo "Validating..." |
| 215 | + exec mvn test |
| 216 | + echo "Formatting code..." |
| 217 | + exec mvn git-code-format:format-code |
| 218 | + echo "Validating format..." |
| 219 | + exec mvn git-code-format:validate-code-format |
| 220 | + </pre-commit> |
| 221 | + </hooks> |
| 222 | + </configuration> |
| 223 | + </execution> |
| 224 | + </executions> |
| 225 | + </plugin> |
| 226 | + </plugins> |
| 227 | + <pluginManagement> |
| 228 | + <plugins> |
| 229 | + <plugin> |
| 230 | + <groupId>org.jacoco</groupId> |
| 231 | + <artifactId>jacoco-maven-plugin</artifactId> |
| 232 | + <version>${jacoco-maven-plugin.version}</version> |
| 233 | + </plugin> |
| 234 | + <plugin> |
| 235 | + <groupId>org.springframework.boot</groupId> |
| 236 | + <artifactId>spring-boot-maven-plugin</artifactId> |
| 237 | + <version>${spring-boot.version}</version> |
| 238 | + </plugin> |
| 239 | + <plugin> |
| 240 | + <groupId>com.societegenerale.commons</groupId> |
| 241 | + <artifactId>arch-unit-maven-plugin</artifactId> |
| 242 | + <version>${arch-unit-maven-plugin.version}</version> |
| 243 | + <executions> |
| 244 | + <execution> |
| 245 | + <phase>test</phase> |
| 246 | + <goals> |
| 247 | + <goal>arch-test</goal> |
| 248 | + </goals> |
| 249 | + </execution> |
| 250 | + </executions> |
| 251 | + </plugin> |
| 252 | + <plugin> |
| 253 | + <groupId>com.google.cloud.tools</groupId> |
| 254 | + <artifactId>jib-maven-plugin</artifactId> |
| 255 | + <version>${jib-maven.plugin.version}</version> |
| 256 | + </plugin> |
| 257 | + </plugins> |
| 258 | + </pluginManagement> |
| 259 | + </build> |
| 260 | +</project> |
0 commit comments