gpt4 book ai didi

java - Maven 不查看本地存储库

转载 作者:行者123 更新时间:2023-11-30 09:09:36 26 4
gpt4 key购买 nike

我正在尝试使用 Maven 管理多个项目,这些项目具有许多相互依赖性。这就是我所做的:

  • 我用 mvn package 构建了一个项目。
  • 我尝试使用 mvn package 构建另一个依赖于另一个的项目。

产生这个输出:

[INFO] Scanning for projects...
[INFO]
[INFO] Using the builder org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder with a thread count of 1
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building classj 0.5-SNAPSHOT
[INFO] ------------------------------------------------------------------------
Downloading: http://repo.maven.apache.org/maven2/com/tbodt/jrestack/1.0/jrestack-1.0.pom
[WARNING] The POM for com.tbodt:jrestack:jar:1.0 is missing, no dependency information available
Downloading: http://repo.maven.apache.org/maven2/com/tbodt/jrestack/1.0/jrestack-1.0.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.332 s
[INFO] Finished at: 2014-04-09T17:45:17-08:00
[INFO] Final Memory: 3M/58M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project classj: Could not resolve dependencies for project com.tbodt:classj:jar:0.5-SNAPSHOT: Failure to find com.tbodt:jrestack:jar:1.0 in http://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced -> [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]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException

如您所见,Maven 尝试从中央存储库下载我的项目,但失败了。但是,它位于本地存储库中。我能做什么?

最佳答案

要在本地存储库中安装您的第一个项目,请运行:

mvn install

关于java - Maven 不查看本地存储库,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22976654/

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