forked from entur/mapstruct-spi-protobuf
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpom.xml
executable file
·79 lines (79 loc) · 3.58 KB
/
pom.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
<?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">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>no.entur.mapstruct.spi</groupId>
<artifactId>spi-protobuf-parent</artifactId>
<version>1.46-SNAPSHOT</version>
</parent>
<artifactId>protobuf-usage</artifactId>
<dependencies>
<dependency>
<groupId>org.mapstruct</groupId>
<artifactId>mapstruct</artifactId>
</dependency>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-engine</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>dev.cookiecode</groupId>
<artifactId>protobuf-maven-plugin</artifactId>
<version>${protobuf.plugin.version}</version>
<executions>
<execution>
<goals>
<goal>compile</goal>
</goals>
<phase>generate-sources</phase>
<configuration>
<protocArtifact>com.google.protobuf:protoc:${proto.version}:exe:${os.detected.classifier}</protocArtifact>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<annotationProcessorPaths>
<path>
<!-- Add your SPI implementation. -->
<groupId>no.entur.mapstruct.spi</groupId>
<artifactId>protobuf-spi-impl</artifactId>
<version>${project.version}</version>
<!-- In real life, this should be a fixed version from a different
reactor project and not be part of the same multi-module project. Maven wouldn't
be able to consider that in the build-order calculation and might pull in
the spi-impl from a previous build (especially tricky in multi-threaded builds).
For Eclipse, there would be similar problems, as it can't reference build
artifacts of workspace projects in the processor classpath but only jar-files
(in this case from the local M2-repo cache). -->
</path>
</annotationProcessorPaths>
<compilerArgs>
<arg>-AmapstructSpi.enumPostfixOverrides=no.entur.mapstruct.example.EnumPostfixOverrideProtos=INVALID</arg>
</compilerArgs>
</configuration>
</plugin>
<plugin>
<groupId>com.diffplug.spotless</groupId>
<artifactId>spotless-maven-plugin</artifactId>
</plugin>
</plugins>
<extensions>
<extension>
<groupId>kr.motd.maven</groupId>
<artifactId>os-maven-plugin</artifactId>
<version>${os.mavenplugin.version}</version>
</extension>
</extensions>
</build>
</project>