Project

Profile

Help

Support #5059 » pom.xml

Youssouf MHOMA, 2021-08-10 10:29

 
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

    
7
    <groupId>org.test</groupId>
8
    <artifactId>saxonpoc</artifactId>
9
    <version>1.0-SNAPSHOT</version>
10

    
11
    <properties>
12
        <maven.compiler.source>11</maven.compiler.source>
13
        <maven.compiler.target>11</maven.compiler.target>
14
    </properties>
15

    
16
    <dependencies>
17
        <!-- https://mvnrepository.com/artifact/net.sf.saxon/Saxon-HE -->
18
        <dependency>
19
            <groupId>net.sf.saxon</groupId>
20
            <artifactId>Saxon-HE</artifactId>
21
            <version>10.5</version>
22
        </dependency>
23
    </dependencies>
24

    
25
    <build>
26
        <plugins>
27
            <plugin>
28
                <groupId>org.apache.maven.plugins</groupId>
29
                <artifactId>maven-compiler-plugin</artifactId>
30
                <version>3.8.0</version>
31
                <configuration>
32
                    <source>1.8</source>
33
                    <target>1.8</target>
34
                </configuration>
35
            </plugin>
36
            <plugin>
37
                <artifactId>maven-assembly-plugin</artifactId>
38
                <executions>
39
                    <execution>
40
                        <phase>package</phase>
41
                        <goals>
42
                            <goal>single</goal>
43
                        </goals>
44
                    </execution>
45
                </executions>
46
                <configuration>
47
                    <archive>
48
                        <manifest>
49
                            <mainClass>SaxonTransformerExample</mainClass>
50
                        </manifest>
51
                    </archive>
52
                    <descriptorRefs>
53
                        <descriptorRef>jar-with-dependencies</descriptorRef>
54
                    </descriptorRefs>
55
                    <appendAssemblyId>false</appendAssemblyId>
56
                </configuration>
57
            </plugin>
58
            <!-- Generation classes java depuis XSD -->
59
            <plugin>
60
                <groupId>org.jvnet.jaxb2.maven2</groupId>
61
                <artifactId>maven-jaxb2-plugin</artifactId>
62
                <version>0.14.0</version>
63
                <executions>
64
                    <execution>
65
                        <id>xjc</id>
66
                        <goals>
67
                            <goal>generate</goal>
68
                        </goals>
69
                    </execution>
70
                </executions>
71
                <configuration>
72
                    <schemaDirectory>${basedir}/src/main/resources/schema</schemaDirectory>
73
                </configuration>
74
            </plugin>
75
            <!-- Ajout de Generated Sources dans le classpath -->
76
            <plugin>
77
                <groupId>org.codehaus.mojo</groupId>
78
                <artifactId>build-helper-maven-plugin</artifactId>
79
                <version>3.0.0</version>
80
                <executions>
81
                    <execution>
82
                        <id>add-source</id>
83
                        <phase>generate-sources</phase>
84
                        <goals>
85
                            <goal>add-source</goal>
86
                        </goals>
87
                        <configuration>
88
                            <sources>
89
                                <source>${project.build.directory}/generated-sources/java/</source>
90
                            </sources>
91
                        </configuration>
92
                    </execution>
93
                </executions>
94
            </plugin>
95
        </plugins>
96
    </build>
97
</project>
(2-2/2)