gpt4 book ai didi

maven - 没有为此构建指定目标。

转载 作者:行者123 更新时间:2023-12-02 18:07:45 28 4
gpt4 key购买 nike

我正在尝试在Docker中运行Maven。

因此,我从她的https://hub.docker.com/_/maven/中提取了图像。

docker pull maven

但是,当我运行它时:
docker run maven

我得到:
[ERROR] No goals have been specified for this build. You must specify a valid lifecycle phase or a goal in the format <plugin-prefix>:<goal> or <plugin-group-id>:<plugin-artifact-id>[:<plugin-version>]:<goal>. Available lifecycle phases are: validate, initialize, generate-sources, process-sources, generate-resources, process-resources, compile, process-classes, generate-test-sources, process-test-sources, generate-test-resources, process-test-resources, test-compile, process-test-classes, test, prepare-package, package, pre-integration-test, integration-test, post-integration-test, verify, install, deploy, pre-clean, clean, post-clean, pre-site, site, post-site, site-deploy. -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]

我没有Maven的经验,所以我不明白是什么导致了此问题。

Docker容器仅安装了Maven,但未运行它,因此我不了解Maven如何引发错误。

最佳答案

点击clean install之后,您需要在目标标签中定义build as maven

关于maven - 没有为此构建指定目标。,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41261750/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com