Maven命令列出生命周期阶段以及受限制的目标? [英] Maven command to list lifecycle phases along with bound goals?

查看:71
本文介绍了Maven命令列出生命周期阶段以及受限制的目标?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我只是在学习Maven,所以这也许很明显,但是我找不到一种简单的方法来列出给定项目的每个Maven生命周期阶段相关的目标.

I'm just learning Maven, and so this might be obvious, but I can't find an easy way to list the goals associated for each maven lifecycle phase for a given project.

我看到Maven默认生命周期阶段和相应的默认目标已记录在此处.到目前为止,我的理解是每个pom.xml可以将其他目标绑定到每个生命周期阶段.

I saw that the Maven default life cycle phases and corresponding default goals are documented here. My understanding so far is that each pom.xml can bind additional goals to each lifecycle phase.

那么,是否有mvn命令来确定将为给定项目在每个生命周期阶段运行的目标?如果没有,我想我只需要仔细检查每个新的maven项目的pom.xml即可解决这个问题?

So, is there a mvn command to determine the goals that will be run for each lifecycle phase for a given project? If not, I guess I just have to look through the pom.xml for each new maven project to figure this out?

推荐答案

mvn help:describe -Dcmd=compile(或任何其他有效阶段)

mvn help:describe -Dcmd=compile (or any other valid phase)

这篇关于Maven命令列出生命周期阶段以及受限制的目标?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆