maven 部署到本地存储库 [英] maven deploy into local repository
问题描述
有人可以指出我如何将人工制品部署到本地存储库中以测试部署场景的方法吗?问题是我们使用 nexus 作为远程存储库,我想知道是否可以使用自定义名称而不是 nexus 为我们提供的名称部署我的工件.
提前致谢!
使用以下命令
mvn install:install-file -Dfile=myfile.jar -DgroupId=com.example -DartifactId=myartifact -Dversion=0.1 -Dpackaging=jar
myfile.jar
是你的神器,-DgroupId
、-DartifactId
等的含义也很明显.
查看文档此处.>
如果您还需要远程存储库,请参阅 mvn deploy:deploy-file
(这里)
Can somebody, please, point me to the way of how can I deploy artefacts into the local repository to test deploy scenario? The thing is that we use nexus as remote repository and I wonder if it is possible to deploy my artifacts with custom name and not with names which nexus provide for us.
Thanks in advance!
Use the following command
mvn install:install-file -Dfile=myfile.jar -DgroupId=com.example -DartifactId=myartifact -Dversion=0.1 -Dpackaging=jar
myfile.jar
is your artifact and the meaning of -DgroupId
, -DartifactId
etc. is obvious too.
See documentation here.
In case you needed a remote repository as well, see mvn deploy:deploy-file
(here)
这篇关于maven 部署到本地存储库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!