Github 在 ORG 中找不到 Maven 包
Github Maven Packages can't be found in ORG
我正在尝试使用 Github 包作为 maven 存储库。
当我像这样直接指向一个 repo 时:
repositories {
maven {
url = uri("https://maven.pkg.github.com/ORG/REPO")
credentials {
username = 'some-user'
password = 'github-token-with-repo-scope'
}
}
}
然后像这样拉依赖:
dependencies{
implementation 'groupId:artifcatId:1.0.0-snapshot'
}
有效。
但是如果我不想限制maven url到特定的repo,直接使用ORG url
url = uri("https://maven.pkg.github.com/ORG')
它不会找到相同的 artifcat 说:
Could not find groupId:artifcatId:1.0.0-snapshot.
我已经尝试将 REPO 名称添加到依赖项声明中
dependencies{
implementation 'REPO:groupId:artifcatId:1.0.0-snapshot'
}
还是不行。
任何人都知道如何使用 ORG url 作为 MAVEN REPOSITORY,而不是向每个 repo 添加多个 url(并增加登录调用等...)
谢谢!
我从 github 支持人员那里得到了答复,他们已经解决了这个问题 :)
Hi Mark,
Sorry about the delay in getting back to you! I've been working through some tickets that were left on-hold.
This issue has now been fixed!
You can't use https://maven.pkg.github.com/ORG, but you can use the following URL for normal and SNAPSHOT versions.
url = uri("https://maven.pkg.github.com/ORG/*")
We'd like to have allowed https://maven.pkg.github.com/ORG, but there would have been no way to distinguish between the groupId and repo name
Regards,
Jamie.
P.S。感谢杰米的更新:)
我正在尝试使用 Github 包作为 maven 存储库。
当我像这样直接指向一个 repo 时:
repositories {
maven {
url = uri("https://maven.pkg.github.com/ORG/REPO")
credentials {
username = 'some-user'
password = 'github-token-with-repo-scope'
}
}
}
然后像这样拉依赖:
dependencies{
implementation 'groupId:artifcatId:1.0.0-snapshot'
}
有效。
但是如果我不想限制maven url到特定的repo,直接使用ORG url
url = uri("https://maven.pkg.github.com/ORG')
它不会找到相同的 artifcat 说:
Could not find groupId:artifcatId:1.0.0-snapshot.
我已经尝试将 REPO 名称添加到依赖项声明中
dependencies{
implementation 'REPO:groupId:artifcatId:1.0.0-snapshot'
}
还是不行。
任何人都知道如何使用 ORG url 作为 MAVEN REPOSITORY,而不是向每个 repo 添加多个 url(并增加登录调用等...)
谢谢!
我从 github 支持人员那里得到了答复,他们已经解决了这个问题 :)
Hi Mark, Sorry about the delay in getting back to you! I've been working through some tickets that were left on-hold.
This issue has now been fixed!
You can't use https://maven.pkg.github.com/ORG, but you can use the following URL for normal and SNAPSHOT versions.
url = uri("https://maven.pkg.github.com/ORG/*")
We'd like to have allowed https://maven.pkg.github.com/ORG, but there would have been no way to distinguish between the groupId and repo name
Regards, Jamie.
P.S。感谢杰米的更新:)