修复jar包无法运行问题

master
huise 6 years ago
parent 17f5ad42a1
commit 2d19a084ca
  1. 531
      pom.xml

@ -1,291 +1,258 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" <project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 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"> xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent> <parent>
<groupId>net.mingsoft</groupId> <groupId>net.mingsoft</groupId>
<artifactId>ms-pom</artifactId> <artifactId>ms-pom</artifactId>
<version>1.0.0</version> <version>1.0.0</version>
<relativePath/> <relativePath/>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<groupId>net.mingsoft</groupId> <groupId>net.mingsoft</groupId>
<artifactId>ms-mcms</artifactId> <artifactId>ms-mcms</artifactId>
<version>5.0.0</version> <version>5.0.0</version>
<name>${project.groupId}:${project.artifactId}</name> <name>${project.groupId}:${project.artifactId}</name>
<description>ms-mcms tools Library</description> <description>ms-mcms tools Library</description>
<url>https://github.com/ming-soft/ms-mcms</url> <url>https://github.com/ming-soft/ms-mcms</url>
<licenses> <licenses>
<license> <license>
<name>The MIT License (MIT)</name> <name>The MIT License (MIT)</name>
<url>http://mit-license.org</url> <url>http://mit-license.org</url>
</license> </license>
</licenses> </licenses>
<developers> <developers>
<developer> <developer>
<name>mingsoft develop group</name> <name>mingsoft develop group</name>
<email>service@mingsoft.net</email> <email>service@mingsoft.net</email>
<organization>mingsoft</organization> <organization>mingsoft</organization>
<organizationUrl>http://www.mingsoft.net</organizationUrl> <organizationUrl>http://www.mingsoft.net</organizationUrl>
</developer> </developer>
</developers> </developers>
<scm> <scm>
<connection>scm:git://github.com/ming-soft/ms-mcms.git</connection> <connection>scm:git://github.com/ming-soft/ms-mcms.git</connection>
<developerConnection>scm:git@github.com:ming-soft/ms-mcms.git</developerConnection> <developerConnection>scm:git@github.com:ming-soft/ms-mcms.git</developerConnection>
<url>https://github.com/ming-soft/ms-mcms</url> <url>https://github.com/ming-soft/ms-mcms</url>
</scm> </scm>
<distributionManagement> <distributionManagement>
<snapshotRepository> <snapshotRepository>
<id>sonatype-nexus-snapshots</id> <id>sonatype-nexus-snapshots</id>
<name>Sonatype Nexus snapshot repository</name> <name>Sonatype Nexus snapshot repository</name>
<url>https://oss.sonatype.org/content/repositories/snapshots</url> <url>https://oss.sonatype.org/content/repositories/snapshots</url>
</snapshotRepository> </snapshotRepository>
<repository> <repository>
<id>sonatype-nexus-staging</id> <id>sonatype-nexus-staging</id>
<name>Sonatype Nexus release repository</name> <name>Sonatype Nexus release repository</name>
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url> <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
</repository> </repository>
</distributionManagement> </distributionManagement>
<properties> <properties>
<java.version>1.8</java.version> <java.version>1.8</java.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties> </properties>
<dependencies> <dependencies>
<!-- 如果使用的是mysql8.0需要使用8.0的驱动 --> <!-- 如果使用的是mysql8.0需要使用8.0的驱动 -->
<!-- <dependency>--> <!-- <dependency>-->
<!-- <groupId>mysql</groupId>--> <!-- <groupId>mysql</groupId>-->
<!-- <artifactId>mysql-connector-java</artifactId>--> <!-- <artifactId>mysql-connector-java</artifactId>-->
<!-- <version>8.0.11</version>--> <!-- <version>8.0.11</version>-->
<!-- </dependency>--> <!-- </dependency>-->
<dependency> <dependency>
<groupId>net.mingsoft</groupId> <groupId>net.mingsoft</groupId>
<artifactId>ms-mpeople</artifactId> <artifactId>ms-mpeople</artifactId>
</dependency> </dependency>
<dependency> <dependency>
<groupId>net.mingsoft</groupId> <groupId>net.mingsoft</groupId>
<artifactId>ms-upgrader</artifactId> <artifactId>ms-upgrader</artifactId>
</dependency> </dependency>
</dependencies> </dependencies>
<build> <build>
<resources> <resources>
<resource> <resource>
<directory>src/main/java</directory> <directory>src/main/java</directory>
</resource> </resource>
<resource> <resource>
<directory>src/main/webapp</directory> <directory>src/main/webapp</directory>
<excludes> <excludes>
<exclude>html/</exclude> <exclude>html/</exclude>
<exclude>static/</exclude> <exclude>static/</exclude>
<exclude>upload/</exclude> <exclude>upload/</exclude>
<exclude>templets/</exclude> <exclude>templets/</exclude>
</excludes> </excludes>
</resource> </resource>
<resource> <resource>
<directory>src/main/resources</directory> <directory>src/main/resources</directory>
</resource> </resource>
</resources> </resources>
<plugins> <plugins>
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId> <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId> <artifactId>maven-jar-plugin</artifactId>
<version>2.6</version> <version>2.6</version>
<executions> <executions>
<execution> <execution>
<phase>package</phase> <phase>package</phase>
<goals> <goals>
<goal>jar</goal> <goal>jar</goal>
</goals> </goals>
</execution> </execution>
</executions> </executions>
<configuration> <configuration>
<excludes> <excludes>
<!--注意这玩意从编译结果目录开始算目录结构 --> <!--注意这玩意从编译结果目录开始算目录结构 -->
<exclude>**/static/plugins/</exclude> <exclude>**/static/plugins/</exclude>
<exclude>**/static/skin/</exclude> <exclude>**/static/skin/</exclude>
<exclude>**/application*.yml</exclude> <exclude>**/Dockerfile</exclude>
<exclude>**/Dockerfile</exclude> <exclude>**/ehcache.xml</exclude>
<exclude>**/ehcache.xml</exclude> <exclude>**/upgrade/</exclude>
<exclude>**/upgrade/</exclude> <exclude>**/*.java</exclude>
<exclude>**/*.java</exclude> </excludes>
</excludes> </configuration>
</configuration> </plugin>
</plugin> <plugin>
<plugin> <groupId>org.apache.maven.plugins</groupId>
<groupId>org.apache.maven.plugins</groupId> <artifactId>maven-source-plugin</artifactId>
<artifactId>maven-source-plugin</artifactId> <version>2.2.1</version>
<version>2.2.1</version> <configuration>
<configuration> <excludes>
<excludes> <exclude>**/static/plugins/</exclude>
<exclude>**/static/plugins/</exclude> <exclude>**/static/skin/</exclude>
<exclude>**/static/skin/</exclude> <exclude>**/application*.yml</exclude>
<exclude>**/application*.yml</exclude> <exclude>**/Dockerfile</exclude>
<exclude>**/Dockerfile</exclude> <exclude>**/ehcache.xml</exclude>
<exclude>**/ehcache.xml</exclude> <exclude>**/upgrade/</exclude>
<exclude>**/upgrade/</exclude> <exclude>**/config/</exclude>
<exclude>**/config/</exclude> <exclude>**/MSApplication.java</exclude>
<exclude>**/MSApplication.java</exclude> <exclude>**/MSServletInitializer.java</exclude>
<exclude>**/MSServletInitializer.java</exclude> </excludes>
</excludes> </configuration>
</configuration> <executions>
<executions> <execution>
<execution> <id>attach-sources</id>
<id>attach-sources</id> <goals>
<goals> <goal>jar-no-fork</goal>
<goal>jar-no-fork</goal> </goals>
</goals> </execution>
</execution> </executions>
</executions> </plugin>
</plugin> <plugin>
<plugin> <groupId>org.springframework.boot</groupId>
<groupId>org.apache.maven.plugins</groupId> <artifactId>spring-boot-maven-plugin</artifactId>
<artifactId>maven-compiler-plugin</artifactId> </plugin>
<version>3.1</version> <plugin>
<configuration> <groupId>org.apache.maven.plugins</groupId>
<source>${java.version}</source> <artifactId>maven-compiler-plugin</artifactId>
<target>${java.version}</target> <version>3.1</version>
<encoding>${project.build.sourceEncoding}</encoding> <configuration>
<showDeprecation>true</showDeprecation> <source>${java.version}</source>
<showWarnings>true</showWarnings> <target>${java.version}</target>
<compilerArguments> <encoding>${project.build.sourceEncoding}</encoding>
<verbose /> </configuration>
<bootclasspath>${java.home}/lib/rt.jar:${java.home}/lib/jce.jar</bootclasspath> </plugin>
</compilerArguments> <plugin>
<compilerArgument>-Xlint:unchecked</compilerArgument> <groupId>org.apache.maven.plugins</groupId>
</configuration> <artifactId>maven-eclipse-plugin</artifactId>
<dependencies> <version>2.8</version>
<dependency> <configuration>
<groupId>org.codehaus.plexus</groupId> <additionalConfig>
<artifactId>plexus-compiler-eclipse</artifactId> <file>
<version>2.1</version> <name>.settings/org.eclipse.core.resources.prefs</name>
</dependency> <content>
</dependencies> <![CDATA[
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-eclipse-plugin</artifactId>
<version>2.8</version>
<configuration>
<additionalConfig>
<file>
<name>.settings/org.eclipse.core.resources.prefs</name>
<content>
<![CDATA[
eclipse.preferences.version=1 eclipse.preferences.version=1
encoding/<project>=${project.build.sourceEncoding} encoding/<project>=${project.build.sourceEncoding}
]]> ]]>
</content> </content>
</file> </file>
</additionalConfig> </additionalConfig>
</configuration> </configuration>
</plugin> </plugin>
<plugin> <plugin>
<artifactId>maven-surefire-plugin</artifactId> <artifactId>maven-surefire-plugin</artifactId>
<configuration> <configuration>
<argLine>-Xmx256m</argLine> <argLine>-Xmx256m</argLine>
</configuration> </configuration>
</plugin> </plugin>
<plugin> <plugin>
<groupId>com.atlassian.maven.plugins</groupId> <groupId>com.atlassian.maven.plugins</groupId>
<artifactId>maven-clover2-plugin</artifactId> <artifactId>maven-clover2-plugin</artifactId>
<version>2.6.3</version> <version>2.6.3</version>
<configuration> <configuration>
<licenseLocation>${clover.license.file}</licenseLocation> <licenseLocation>${clover.license.file}</licenseLocation>
<encoding>${project.build.sourceEncoding}</encoding> <encoding>${project.build.sourceEncoding}</encoding>
<generateXml>true</generateXml> <generateXml>true</generateXml>
</configuration> </configuration>
</plugin> </plugin>
<plugin> <plugin>
<groupId>org.codehaus.mojo</groupId> <groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId> <artifactId>findbugs-maven-plugin</artifactId>
<version>1.2</version> <version>1.2</version>
<configuration> <configuration>
<findbugsXmlOutput>true</findbugsXmlOutput> <findbugsXmlOutput>true</findbugsXmlOutput>
<findbugsXmlWithMessages>true</findbugsXmlWithMessages> <findbugsXmlWithMessages>true</findbugsXmlWithMessages>
<xmlOutput>true</xmlOutput> <xmlOutput>true</xmlOutput>
</configuration> </configuration>
</plugin> </plugin>
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId> <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId> <artifactId>maven-javadoc-plugin</artifactId>
<version>2.9.1</version> <version>2.9.1</version>
<configuration> <configuration>
<charset>UTF-8</charset> <charset>UTF-8</charset>
<encoding>UTF-8</encoding> <encoding>UTF-8</encoding>
<docencoding>UTF-8</docencoding> <docencoding>UTF-8</docencoding>
<javadocExecutable>${java.home}/../bin/javadoc</javadocExecutable> <javadocExecutable>${java.home}/../bin/javadoc</javadocExecutable>
<additionalparam>-Xdoclint:none</additionalparam> <additionalparam>-Xdoclint:none</additionalparam>
</configuration> </configuration>
<executions> <executions>
<execution> <execution>
<id>attach-javadocs</id> <id>attach-javadocs</id>
<goals> <goals>
<goal>jar</goal> <goal>jar</goal>
</goals> </goals>
</execution> </execution>
</executions> </executions>
</plugin> </plugin>
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId> <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId> <artifactId>maven-war-plugin</artifactId>
<version>2.6</version> <version>2.6</version>
<configuration> <configuration>
<webResources> <webResources>
<resource> <resource>
<directory>src/main/webapp/WEB-INF</directory> <directory>src/main/webapp/WEB-INF</directory>
<targetPath>WEB-INF</targetPath> <targetPath>WEB-INF</targetPath>
<filtering>true</filtering> <filtering>true</filtering>
<includes> <includes>
<include>**/*.xml</include> <include>**/*.xml</include>
</includes> </includes>
<excludes> <excludes>
<exclude>web.xml</exclude> <exclude>web.xml</exclude>
</excludes> </excludes>
</resource> </resource>
</webResources> </webResources>
<attachClasses>true</attachClasses> <attachClasses>true</attachClasses>
<warSourceExcludes> */web.xml,static</warSourceExcludes> <warSourceExcludes>*/web.xml,static</warSourceExcludes>
<failOnMissingWebXml>false</failOnMissingWebXml> <failOnMissingWebXml>false</failOnMissingWebXml>
<packagingExcludes>ms.install,html/,static/,temp,upgrader,WEB-INF/web.xml,WEB-INF/lib/,templets/,upload/,WEB-INF/classes/*.xml,WEB-INF/classes/*.properties,*.sh,WEB-INF/classes/net/mingsoft/config/,WEB-INF/classes/net/mingsoft/*.class</packagingExcludes> <packagingExcludes>
</configuration> ms.install,html/,static/,temp,upgrader,WEB-INF/web.xml,WEB-INF/lib/,templets/,upload/,WEB-INF/classes/*.xml,WEB-INF/classes/*.properties,*.sh,WEB-INF/classes/net/mingsoft/config/,WEB-INF/classes/net/mingsoft/*.class
</plugin> </packagingExcludes>
<plugin> </configuration>
<groupId>org.apache.maven.plugins</groupId> </plugin>
<artifactId>maven-release-plugin</artifactId> <plugin>
<configuration> <groupId>org.apache.maven.plugins</groupId>
<arguments>-Dgpg.passphrase=${gpg.passphrase}</arguments> <artifactId>maven-release-plugin</artifactId>
</configuration> <configuration>
</plugin> <arguments>-Dgpg.passphrase=${gpg.passphrase}</arguments>
<plugin> </configuration>
<groupId>org.sonatype.plugins</groupId> </plugin>
<artifactId>nexus-staging-maven-plugin</artifactId>
<version>1.6.7</version>
<extensions>true</extensions>
<configuration>
<serverId>sonatype-nexus-staging</serverId>
<nexusUrl>https://oss.sonatype.org/</nexusUrl>
<autoReleaseAfterClose>true</autoReleaseAfterClose>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>1.5</version>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
<defaultGoal>compile</defaultGoal>
<finalName>ms-mcms</finalName> </plugins>
</build> <defaultGoal>compile</defaultGoal>
</project>
<finalName>ms-mcms</finalName>
</build>
</project>

Loading…
Cancel
Save