Pārlūkot izejas kodu

opt: pom增加打包为fat jar的配置

sensordb2 1 mēnesi atpakaļ
vecāks
revīzija
8cc75ba258
1 mainītis faili ar 24 papildinājumiem un 0 dzēšanām
  1. 24 0
      pom.xml

+ 24 - 0
pom.xml

@@ -17,6 +17,30 @@
                     <target>8</target>
                 </configuration>
             </plugin>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-assembly-plugin</artifactId>
+                <version>3.1.1</version>
+                <configuration>
+                    <archive>
+                        <manifest>
+                            <mainClass>com.feng.fatjar.demo.FatJarMain</mainClass>
+                        </manifest>
+                    </archive>
+                    <descriptorRefs>
+                        <descriptorRef>jar-with-dependencies</descriptorRef>
+                    </descriptorRefs>
+                </configuration>
+                <executions>
+                    <execution>
+                        <id>make-assembly</id>
+                        <phase>package</phase>
+                        <goals>
+                            <goal>single</goal>
+                        </goals>
+                    </execution>
+                </executions>
+            </plugin>
         </plugins>
     </build>