我確定我的插件中沒有maven-source-plugin,但是在發佈時會執行[project-name] -sources.jar:perform。在構建生命週期的其他階段,似乎沒有這樣做。在Maven發佈期間製作* sources.jar的是什麼?
不幸的是,這個[project-name] -sources.jar被上傳到我們的倉庫(Nexus)。管理層希望所有的數據源都保存在SVN中,並且遠離存儲庫。
我該怎麼做?這當然不是裝配問題。我們嘗試了不同的構建配置文件,但[project-name] -sources.jar仍然存在。我們只是不希望在發佈期間將任何源代碼上傳到存儲庫。
任何想法任何一個?
在此先感謝。
下面就是我們在標籤中使用:
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.5.1</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
<compilerArgument>-Xlint:all</compilerArgument>
<showWarnings>true</showWarnings>
<showDeprecation>true</showDeprecation>
</configuration>
</plugin>
<!-- Release Reference: http://maven.apache.org/maven-release/maven-release-plugin/index.html -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<version>2.4.2</version>
<configuration>
<tagBase>http://some.url.here</tagBase>
<checkModificationExcludes>
<checkModificationExclude>.classpath</checkModificationExclude>
<checkModificationExclude>.factorypath</checkModificationExclude>
<checkModificationExclude>.project</checkModificationExclude>
<checkModificationExclude>.rest-shell.log</checkModificationExclude>
<checkModificationExclude>.springBeans</checkModificationExclude>
<checkModificationExclude>.apt-generated/**</checkModificationExclude>
<checkModificationExclude>.settings/**</checkModificationExclude>
<checkModificationExclude>src\main\resources\rebel.xml</checkModificationExclude>
</checkModificationExcludes>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.2</version>
<configuration>
<skip>true</skip>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<version>2.1.1</version>
<configuration>
<archive>
<index>true</index>
<manifest>
<addClasspath>true</addClasspath>
</manifest>
<manifestEntries>
<version>${project.version}</version>
</manifestEntries>
</archive>
</configuration>
</plugin>
</plugins>
</build>
順便說一句:你使用的是非常舊版本的插件。 – khmarbaise 2014-10-10 20:10:11