- iOS/Objective-C 元类和类别
- objective-c - -1001 错误,当 NSURLSession 通过 httpproxy 和/etc/hosts
- java - 使用网络类获取 url 地址
- ios - 推送通知中不播放声音
大约 34 小时前,我生成了一个签名的 apk,但现在,我无法生成一个签名的 apk,我不知道如何解决这个问题。请帮忙
这是我的输出信息
Error:Note: there were 11 duplicate class definitions. (http://proguard.sourceforge.net/manual/troubleshooting.html#duplicateclass) FAILURE: Build failed with an exception.
What went wrong: Execution failed for task ':app:lintVitalRelease'.
Could not resolve all files for configuration ':app:lintClassPath'. Could not resolve com.android.tools.lint:lint-gradle:26.1.0. Required by: project :app Could not resolve com.android.tools.lint:lint-gradle:26.1.0. Could not get resource 'https://jcenter.bintray.com/com/android/tools/lint/lint-gradle/26.1.0/lint-gradle-26.1.0.pom'. Could not GET 'https://jcenter.bintray.com/com/android/tools/lint/lint-gradle/26.1.0/lint-gradle-26.1.0.pom'. jcenter.bintray.com: nodename nor servname provided, or not known Could not resolve com.android.tools.lint:lint-gradle:26.1.0. Could not get resource 'https://dl.google.com/dl/android/maven2/com/android/tools/lint/lint-gradle/26.1.0/lint-gradle-26.1.0.pom'. Could not GET 'https://dl.google.com/dl/android/maven2/com/android/tools/lint/lint-gradle/26.1.0/lint-gradle-26.1.0.pom'. dl.google.com: nodename nor servname provided, or not known
尝试:使用 --stacktrace 选项运行以获取堆栈跟踪。使用 --info 或 --debug 选项运行以获得更多日志输出。使用 --scan 运行以获得完整的见解。
在 https://help.gradle.org 获得更多帮助
10 秒内构建失败
这是我的 build.gradle(app)
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'io.fabric'
android {
compileSdkVersion 26
buildToolsVersion '27.0.3'
defaultConfig {
applicationId "com.myapp……"
minSdkVersion 17
targetSdkVersion 26
versionCode 5
versionName "5.0"
}
buildTypes {
release {
minifyEnabled true
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
packagingOptions {
exclude 'META-INF/NOTICE'
exclude 'META-INF/LICENSE'
}
}
dependencies {
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation "com.android.support:appcompat-v7:$support_version"
implementation "com.android.support:design:$support_version"
implementation "com.android.support:support-v4:$support_version"
implementation "com.android.support:cardview-v7:$support_version"
implementation "com.android.support:recyclerview-v7:$support_version"
implementation "com.google.firebase:firebase-core:$firebase_version"
implementation "com.google.firebase:firebase-messaging:$firebase_version"
implementation "com.google.firebase:firebase-ads:$firebase_version"
implementation 'com.crashlytics.sdk.android:crashlytics:2.9.1'
implementation "com.google.firebase:firebase-perf:$firebase_version"
implementation 'io.github.yavski:fab-speed-dial:1.0.6'
implementation 'com.google.code.gson:gson:2.8.0'
implementation 'com.codemybrainsout.rating:ratingdialog:1.0.8'
implementation 'com.android.billingclient:billing:1.0'
implementation 'com.android.support.constraint:constraint-layout:1.0.2'
implementation 'org.jsoup:jsoup:1.10.3'
testImplementation 'junit:junit:4.12'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jre7:$kotlin_version"
}
apply plugin: 'com.google.gms.google-services'
apply plugin: 'kotlin-android-extensions'
这是我的 build.gradle(project)
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
ext.kotlin_version = '1.2.10'
ext.support_version = '26.1.0'
ext.firebase_version = '12.0.1'
repositories {
jcenter()
google()
maven {
url 'https://maven.fabric.io/public'
}
}
dependencies {
classpath 'com.android.tools.build:gradle:3.1.0'
classpath 'io.fabric.tools:gradle:1.25.1'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
classpath 'com.google.gms:google-services:3.1.2'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
allprojects {
repositories {
jcenter()
google()
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
最佳答案
这是一个 lintValidRelease 问题。您需要在 Gradle 文件中添加 lintOptions。
android {
..
lintOptions {
checkReleaseBuilds false
}
}
关于android - 尝试生成签名的 Apk 时 Gradle 构建错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49604150/
我已经为我的 Android 应用设置了 Google Play 测试版程序。想象一下以下场景: 我将 apk1 作为 versionCode 1 的测试版发布 Beta 用户安装此 Beta 版本
我需要在 android studio 中生成一个未签名的 APK。我看到了其他一些关于此的问题。 Export unsigned apk from a Gradle Project in Andro
我想知道更新是如何进行的?它如何更新特定文件仅更改?我的意思是在更新期间,整个 apk 是否再次安装或仅特定文件更改?它是如何工作的?我只想知道 android market 如何在没有用户提示的情况
如何在使用新 apk 的情况下升级 android 应用程序而不丢失以前的 apk 数据? 最佳答案 有一个versionCode AndroidManifest.xml 中的元素。这是一个整数,每个
我看到 Android 在输出文件夹中同时创建了一个“普通”APK 和一个 androidTest APK? 即 app-dev-debug.apk app-dev-debug-androidTest
Upload failed You uploaded an APK that is signed with a different certificate to your previous APKs.
对我来说,这发生在所有项目中。当我从 Android Studio 生成签名的 apk 时,我收到以下正确消息: 问题:在此之后,当我实际上并没有生成签名的 apk 时,我继续为项目发生的每个构建收到
我需要在 Windows 上反编译 & 重新编译一个 apk... 我正在关注此链接 Reverse Engineer APK 问题是我找不到发出请求的文件(请参阅上面的链接)“找到发出请求的文件 g
我寻找一种方法来制作一个可以更改我的第一个 apk 的默认图标的 apk。例如 ADW Launcher。 我该怎么做?也许是一种获取另一个 apk 的绘图的方法? 感谢您的帮助。 最佳答案 我想您正
我正在开发一个基于图像的应用程序,具有以下属性: 手机版本的 apk 大小(不含图像)约为 15MB,平板电脑版本约为 25MB。 图像总大小约为 30MB。 该应用程序将以测试版状态发布,可能会频繁
假设在网站上我有一个 apk 和网站的在线 JSON 数据,现在依赖于那个 apk 我想用新的 JSON 数据重新生成新的 apk 文件,还需要Manifest文件中的应用图标也要动态变化,包名也要动
今天我注意到当我在 Eclipse 中导出我的应用程序时,我得到了一个无扩展名的文件。我过去没有注意到这一点,所以我将此文件作为我的应用程序的 APK 文件上传到 Google Play。当我今天看到
我有一个同时适用于手机/平板电脑和电视的应用程序。当我在电视上使用 leanback 时,这个项目由 3 个模块组成。第一个(库)包含电视和移动/平板电脑模块通用的所有类,然后我有电视和移动/平板电脑
我制作了一个仅包含微调器和按钮的基本应用程序,但它的 Release模式大小为 1.4 MB,我认为这太大了,因为也有很多低于 200kB 的好应用程序可用 所以我在 gradle 文件中尝试了 b
我的移动开发人员已向我提供了一个 APK 文件,我需要将其上传到商店。它说,你需要在 Release模式下编译它。有没有一种方法可以让我对 apk 执行此操作,使其进入 Release模式并使用 ke
我在里面制作了一个 android 应用程序,我已经在“res/raw”文件夹中放置了一个 apk 文件,现在我在安装我的 apk 时想要什么,raw 文件夹中的 apk 也会安装,而无需再次单击安装
我有一个带有未签名包的 android 应用程序,每当我尝试安装此 apk 时,都会出现以下错误消息:Failure [INSTALL_PARSE_FAILED_NO_CERTIFICATES]。 现
我开发的 Android 应用由不同的人群进行测试。 我们使用 Google Play Beta 方案。 同一组测试人员也提供生产支持。完成测试后,他们需要将设备恢复为生产应用,以便反射(reflec
我有一个已发布的应用程序。该应用程序使用 Google 的许可检查,因此为了测试该应用程序的新版本(使用测试帐户),必须在开发者控制台中上传 APK: 对于尚未上传到 Google Play 的应用程
我正在制作一个应用程序,我想在其中调用其他一些 apk(未预装),它们存在于我手机的 SD 卡中,我希望在安装主应用程序时安装它们。这可能吗?以及如何? 最佳答案 您可以使用以下 Intent 请求
我是一名优秀的程序员,十分优秀!