是否有一个 Maven 插件可以验证所有依赖项是否已发布?
“maven-release-plugin”具有此功能,但它不能作为单独的目标使用。
我想我在某处见过这个功能,但我找不到了。如果有人知道在哪里可以找到这样的插件,那就太好了。
The 'maven-release-plugin' has this feature, but it is not available as separate goal.
I think I have seen this functionality somewhere, but I can't find it again. Would be great if somebody knows where to find such a plugin.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
maven enforcer 插件 有一个
requireReleaseDeps
规则允许强制不将快照包含为依赖项< /em>。这可能就是您正在寻找的。如果您像这样配置插件(请检查规则文档以获取更多选项):
然后调用 mvn enforcer:enforce 将完成这项工作。
The maven enforcer plugin has a
requireReleaseDeps
rule allowing to enforce that no snapshots are included as dependencies. It may be what you're looking for.If you configure the plugin like this (check the rule documentation for more options):
Then calling
mvn enforcer:enforce
will do the job.使用
release:prepare
与dryRun=true
一起应该做你想要的。Using
release:prepare
together withdryRun=true
should do what you want.