【问题标题】:Importing from Maven or Jcenter fails (Jitpack works)从 Maven 或 Jcenter 导入失败(Jitpack 有效)
【发布时间】:2021-03-26 00:33:26
【问题描述】:

我有一个 lint lib 无法导入 throwing:

> Failed to resolve: AndroidStyling-LintRules:checks:unspecified
> Affected Modules: app

所以我测试了运行./gradlew publishToMavenLocal,结果被抛出:

* What went wrong:
Execution failed for task ':styling-lint:publishAndroidPublicationToMavenLocal'.
> Failed to publish publication 'android' to repository 'mavenLocal'
   > Invalid publication 'android': artifact file does not exist: '.../styling-lint/build/outputs/aar/styling-lint-release.aar'

我发现缺少的东西,所以在修复它后添加builtBy

artifact("$buildDir/outputs/aar/${artifactId}-release.aar") {
    builtBy(tasks.getByName("assemble"))
}

publishToMavenLocal 构建成功,我可以使用mavenLocal() 导入并且它可以工作。 不幸的是,从远程导入仍然失败,输出相同...

Jitpack 导入工作:

发生了什么事?
谢谢。

【问题讨论】:

    标签: android maven bintray jcenter jitpack


    【解决方案1】:

    不知为何它开始工作 ¯\_(ツ)_/¯

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2018-04-28
      • 2013-08-21
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多