简体   繁体   English

Android studio 4.0 在哪里下载 lint-checks-27.0.0.jar?

[英]Where to download lint-checks-27.0.0.jar for Android studio 4.0?

When building the release APK, it always fails with the following error:在构建发布 APK 时,它总是失败并出现以下错误:

Could not find lint-checks-27.0.0.jar (com.android.tools.lint:lint-checks:27.0.0).

I'm in offline environment and use local repository in the build.gradle, and I want to download the lint-checks-27.0.0.jar by manually.我处于离线环境并使用 build.gradle 中的本地存储库,我想手动下载 lint-checks-27.0.0.jar。

repositories {
    maven { url '/path/to/repository' }
}

I have checked the following maven central repository, but only found the 25.3.0 as shown below.我检查了以下 maven 中央存储库,但只找到了 25.3.0 如下图所示。

https://repo.maven.apache.org/maven2/com/android/tools/lint/lint-checks/

...
25.1.0/                                           2016-04-26 22:20         -      
25.1.2/                                           2016-06-06 16:43         -      
25.1.3/                                           2016-08-24 04:20         -      
25.2.0/                                           2016-09-26 16:42         -      
25.3.0/                                           2017-03-06 17:42         -      
maven-metadata.xml                                2017-03-06 17:43      2383      
maven-metadata.xml.md5                            2017-03-06 17:43        32      
maven-metadata.xml.sha1                           2017-03-06 17:43        40  

I have also tried the following google and jcenter repositories, but can't find any artifect inside by using Firefox browser.我还尝试了以下 google 和 jcenter 存储库,但使用 Firefox 浏览器在内部找不到任何工件。

https://dl.google.com/dl/android/maven2/
https://jcenter.bintray.com/

I have also tried the following URL but Firefox browser responses with 404 Not Found:我还尝试了以下 URL 但 Firefox 浏览器响应 404 Not Found:

https://dl.google.com/dl/android/maven2/com/android/tools/lint/lint-checks/lint-checks-27.0.0.jar

Thanks.谢谢。

The google() repository should have it: google()存储库应该有它:

https://mvnrepository.com/artifact/com.android.tools.lint/lint-checks/27.0.0 https://mvnrepository.com/artifact/com.android.tools.lint/lint-checks/27.0.0

And I think your repository URL is wrong...for comparision:而且我认为您的存储库 URL 是错误的......比较:

https://maven.google.com/com/android/tools/lint/lint-checks/27.0.0/lint-checks-27.0.0.jar https://maven.google.com/com/android/tools/lint/lint-checks/27.0.0/lint-checks-27.0.0.jar

I don't understand why you haven't added the actual repository configuration, but it should be:我不明白您为什么没有添加实际的存储库配置,但应该是:

repositories {
    // maven { url 'https://maven.google.com' }
    google()
}

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM