为什么 Maven 无法解析或收集以下依赖项:org.eclipse.egit:org.eclipse.egit.gitflow:jar:51.202007141445-r

Why is maven unable to resolve nor collect following dependency: org.eclipse.egit:org.eclipse.egit.gitflow:jar:51.202007141445-r

为什么我将下面的依赖项添加到我的项目时会出现上面的错误:

<dependency>
    <groupId>org.eclipse.egit</groupId>
    <artifactId>org.eclipse.egit.gitflow</artifactId>
    <version>5.8.1.202007141445-r</version>
</dependency>

> [ERROR] Failed to execute goal on project myproject: Could not resolve
> dependencies for project
> com.example:myproject:maven-plugin:0.0.1-SNAPSHOT: Failure to find
> org.eclipse.egit:org.eclipse.egit.gitflow:jar:51.202007141445-r 
>[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

依赖项确实存在:https://mvnrepository.com/artifact/org.eclipse.egit/org.eclipse.egit.gitflow/5.8.1.202007141445-r

默认 Maven Central, it's part of the Eclipse Public Repository 中不存在依赖关系。具体在这里:

https://repo.eclipse.org/content/groups/releases/org/eclipse/egit/org.eclipse.egit.gitflow/5.8.1.202007141445-r/

尝试添加:

    <repositories>
        <repository>
            <id>epl</id>
            <url>https://repo.eclipse.org/content/groups/releases</url>
        </repository>
    </repositories>