From b17dabcec4838e8aa901d9a6cd4b07dc20bb44c5 Mon Sep 17 00:00:00 2001 From: Isaac Andrade <isaac.andra84@gmail.com> Date: Sat, 12 Apr 2025 04:34:47 -0300 Subject: [PATCH] fix: #187 applying MapStruct compiler options only during main compilation (#218) --- pom.xml | 45 +++++++++++++++++++++++++-------------------- 1 file changed, 25 insertions(+), 20 deletions(-) diff --git a/pom.xml b/pom.xml index 5f861dcc..3ff8287b 100644 --- a/pom.xml +++ b/pom.xml @@ -409,26 +409,31 @@ <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> - <configuration> - <annotationProcessorPaths> - <path> - <groupId>org.mapstruct</groupId> - <artifactId>mapstruct-processor</artifactId> - <version>${mapstruct.version}</version> - </path> - </annotationProcessorPaths> - <compilerArgs> - <compilerArg> - -Amapstruct.suppressGeneratorTimestamp=true - </compilerArg> - <compilerArg> - -Amapstruct.suppressGeneratorVersionInfoComment=true - </compilerArg> - <compilerArg> - -Amapstruct.defaultComponentModel=spring - </compilerArg> - </compilerArgs> - </configuration> + <executions> + <execution> + <id>default-compile</id> + <configuration> + <annotationProcessorPaths> + <path> + <groupId>org.mapstruct</groupId> + <artifactId>mapstruct-processor</artifactId> + <version>${mapstruct.version}</version> + </path> + </annotationProcessorPaths> + <compilerArgs> + <compilerArg> + -Amapstruct.suppressGeneratorTimestamp=true + </compilerArg> + <compilerArg> + -Amapstruct.suppressGeneratorVersionInfoComment=true + </compilerArg> + <compilerArg> + -Amapstruct.defaultComponentModel=spring + </compilerArg> + </compilerArgs> + </configuration> + </execution> + </executions> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> -- GitLab