Skip to content

Commit 7855007

Browse files
authored
add shaded plugin for example (#632)
1 parent ed3a2fb commit 7855007

File tree

1 file changed

+35
-10
lines changed

1 file changed

+35
-10
lines changed

examples/pom.xml

Lines changed: 35 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -54,23 +54,48 @@
5454
</plugin>
5555
<plugin>
5656
<groupId>org.apache.maven.plugins</groupId>
57-
<artifactId>maven-assembly-plugin</artifactId>
58-
<version>2.5.3</version>
57+
<artifactId>maven-shade-plugin</artifactId>
58+
<version>3.4.1</version>
59+
<configuration>
60+
<!-- put your configurations here -->
61+
<filters>
62+
<filter>
63+
<artifact>*:*</artifact>
64+
</filter>
65+
</filters>
66+
<transformers>
67+
<transformer
68+
implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer">
69+
</transformer>
70+
<transformer
71+
implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
72+
<mainClass>com.vesoft.nebula.GraphClientExample</mainClass>
73+
</transformer>
74+
</transformers>
75+
76+
</configuration>
5977
<executions>
6078
<execution>
6179
<phase>package</phase>
6280
<goals>
63-
<goal>single</goal>
81+
<goal>shade</goal>
6482
</goals>
83+
<configuration>
84+
<filters>
85+
<filter>
86+
<artifact>*:*</artifact>
87+
<excludes>
88+
<exclude>META-INF/*.SF</exclude>
89+
<exclude>META-INF/*.DSA</exclude>
90+
<exclude>META-INF/*.RSA</exclude>
91+
<exclude>META-INF/*.EC</exclude>
92+
<exclude>META-INF/SIG-*</exclude>
93+
</excludes>
94+
</filter>
95+
</filters>
96+
</configuration>
6597
</execution>
6698
</executions>
67-
<configuration>
68-
<descriptorRefs>
69-
<descriptorRef>jar-with-dependencies</descriptorRef>
70-
</descriptorRefs>
71-
<finalName>${project.artifactId}-${project.version}-jar-with-dependencies</finalName>
72-
<appendAssemblyId>false</appendAssemblyId>
73-
</configuration>
7499
</plugin>
75100
<!-- maven-jar -->
76101
<plugin>

0 commit comments

Comments
 (0)