我希望有人能帮助我部署maven (通常通过发布插件运行)。
我希望在发布时将文件部署到存储库,而不仅仅是打包的jar,例如特定的说明文档和生成的SQL文件。
如果我不必每次都使用deploy:deploy-file,那就太好了。如果我可以将每个文件添加到我的POM文件中的列表中,它将在发布时自动为我拾取,这将是最好的。
发布于 2010-07-19 07:54:37
或者使用Maven Assembly插件将它们打包到一个将被安装/部署的程序集中。
或者使用build-helper plugin的attach-artifact目标
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>1.5</version>
<executions>
<execution>
<id>attach-artifacts</id>
<phase>package</phase>
<goals>
<goal>attach-artifact</goal>
</goals>
<configuration>
<artifacts>
<artifact>
<file>some file</file>
<type>extension of your file</type>
<classifier>optional</classifier>
</artifact>
...
</artifacts>
</configuration>
</execution>
</executions>
</plugin>https://stackoverflow.com/questions/3277697
复制相似问题