Geeks, please accept the hero post of 2021 Microsoft x Intel hacking contest>>>
pom.xml
<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>
<groupId>zhou</groupId>
<artifactId>execrise</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>execrise</name>
<url>http://maven.apache.org</url>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
<dependency> <groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>19.0</version>
</dependency>
</dependencies>
<!-- https://mvnrepository.com/artifact/com.google.guava/guava -->
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>1.2.1</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<transformers>
<transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
<mainClass>zhou.execrise.App</mainClass>
</transformer>
</transformers>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
attention
plugin
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>1.2.1</version>
package route
<mainClass>zhou.execrise.App</mainClass>
Similar Posts:
- Remove dependency-reduced-pom.xml file when packaging Maven project
- Maven warnning: ‘build.plugins.plugin.version’ is missing [How to Solve]
- Configuration problem: Unable to locate Spring NamespaceHandler for XML schema namespace
- [Solved] Spring Boot Package Error: Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:3.2.0
- Unregistering JMX-exposed beans on shutdown Solution
- Intellij Pack the jar file error: “java.lang.SecurityException: Invalid signature file digest for Manifest main attrib
- Run jar file under Linux system, prompt: no main manifest attribute, in xxx.jar [How to Solve]
- Springboot always reports an error when importing JSP dependencies
- no main manifest attribute, in demo-1.0.jar
- No main manifest attribute when running Java – jar