创建非web项目模板
maven-archetype-quicktype
打jar包的时候需要注意的,pom.xml添加下面内容,否则提示找不到清单文件错误
<build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-shade-plugin</artifactId> <version>2.4.3</version> <executions> <execution> <phase>package</phase> <goals> <goal>shade</goal> </goals> <configuration> <transformers> <transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer"> <mainClass>aa.bb.App</mainClass> </transformer> </transformers> </configuration> </execution> </executions> </plugin> </plugins> </build>
原文:http://www.cnblogs.com/ziyouchutuwenwu/p/6372162.html