简体   繁体   English

Maven 部署插件替换 Artifactory 中现有的快照 Jar

[英]Maven Deploy Plugin Replace the Existing SnapShot Jar in Artifactory

I am using the Maven deploy plugin(3.0.0-M1/2.82)我正在使用 Maven 部署插件(3.0.0-M1/2.82)

to upload Snapshot jar to Jfrog Artifactory, but Plugin builds the SnapShot jar with the timeStamp and build Number(Default Behavior Of Maven Build with Timestamp while Remote Repository ) and says it uploading with name to upload Snapshot jar to Jfrog Artifactory, but Plugin builds the SnapShot jar with the timeStamp and build Number(Default Behavior Of Maven Build with Timestamp while Remote Repository ) and says it uploading with name

example: project-extension-0.0.2-20200506.171928-1.jar but it uploads with SnapShot示例:project-extension-0.0.2-20200506.171928-1.jar 但它使用 SnapShot 上传

name: project-extension-0.0.2-SNAPSHOT.jar(0.0.2-SNAPSHOT its Parent POM Version ) and replace it with the previous build Jar.名称:project-extension-0.0.2-SNAPSHOT.jar(0.0.2-SNAPSHOT its Parent POM Version) 并将其替换为以前的构建 Jar。

This is how SNAPSHOTs work.这就是 SNAPSHOT 的工作原理。

The file is uploaded with a timestamp name (and also saved as such internally).该文件使用时间戳名称上传(并且也在内部保存)。 But usually just specify the version as 0.0.2-SNAPSHOT and Maven resolves the latest timestamp for you.但通常只需将版本指定为0.0.2-SNAPSHOT和 Maven 即可为您解析最新的时间戳。

Artifactory keeps the different versions, but can be configured to keep only the last n SNAPSHOTs. Artifactory 保留不同的版本,但可以配置为仅保留最后 n 个 SNAPSHOT。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM