build.gradle

All the libraries must use the same versions

|▌冷眼眸甩不掉的悲伤 提交于 2019-11-28 06:14:32
问题 My depencies dependencies { compile 'me.dm7.barcodescanner:zxing:1.9' implementation fileTree(dir: 'libs', include: ['*.jar']) implementation 'com.android.support:appcompat-v7:26.1.0' implementation 'com.android.support:design:26.1.0' implementation 'com.android.support.constraint:constraint-layout:1.0.2' testImplementation 'junit:junit:4.12' androidTestImplementation 'com.android.support.test:runner:1.0.1' androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'

Install gradle for using in cordova build android

我的未来我决定 提交于 2019-11-28 06:01:11
I have installed cordova and android sdk on linux mint 17, and downloaded gradle 2.4 (bin) and extracted it and set path to it, now I can get gradle -v from terminal, its ok, but when i want to build cordova : cordova build it starts to download gradle 2.2.... how i can set it to use current gradle 2.4 insteed downloading older version? gradle -v ------------------------------------------------------------ Gradle 2.4 ------------------------------------------------------------ Build time: 2015-05-05 08:09:24 UTC Build number: none Revision: 5c9c3bc20ca1c281ac7972643f1e2d190f2c943c Groovy: 2.3

Android Studio gradle doesn't compile the specified version

三世轮回 提交于 2019-11-28 05:53:34
I've been developing this small project for some days now but suddenly today, Android Studio started to give me this error Error:Execution failed for task ':app:processDebugManifest'. > Manifest merger failed : uses-sdk:minSdkVersion 14 cannot be smaller than version 14 declared in library com.android.support:support-v4:21.0.0-rc1 I understood that it is because it's trying to compile the library of Android-L. The version I want it to compile is the old version but it won't. It keeps giving me the above error no matter which version I enter. Here is the dependencies. dependencies { compile

Gradle: Error: more than one library with package name 'com.google.android.gms'

我的未来我决定 提交于 2019-11-28 05:18:05
What does this error message mean? I don't have duplicated packages in my project Error:Execution failed for task ':SimpleReader:processDebugResources'. Error: more than one library with package name 'com.google.android.gms' You can temporarily disable this error with android.enforceUniquePackageName=false However, this is temporary and will be enforced in 1.0 My build.gradle looks like this: buildscript { repositories { maven { url 'http://repo1.maven.org/maven2' } mavenCentral() } dependencies { classpath 'com.android.tools.build:gradle:0.9.1' } } apply plugin: 'android' android {

resValue gradle error: Unsupported type “String” in “generated.xml”

青春壹個敷衍的年華 提交于 2019-11-28 05:17:09
A few weeks ago I posted a question How to override resources depending on buildType . And just yesterday there was a gradle plugin release for android . Based on this post on G+ I decided to write this question. The problem I have described in detail: I want to create some resource values depending on the buildType , but this doesn't work properly: The file "generated.xml" will be only created if I make a complete build over the command line: gradlew build But I also get an error by building the complete project over comannd line: * What went wrong: Execution failed for task ':app:merge

How to declare gradle version 5.0 in build.gradle?

心不动则不痛 提交于 2019-11-28 04:47:53
问题 I used task wrapper when Gradle was 4.x but when I change gradleVersion to 5.0 , gradle wrapper states that it can't add a task with the same name. This didn't happen when it was 4.x when I could just change from 4.8 to 4.9 without issues. Does Gradle changed how task wrapper works? 回答1: Defining a custom wrapper task in your build script has been deprecated since Gradle 4.8 version, see Gradle 4.8 depreciations (section Overwriting Gradle's built-in tasks" section ) Since version 4.8 (and

Getting out of memory issue after updating buildToolsVersion '23.0.1' in Android studio

爷,独闯天下 提交于 2019-11-28 04:27:05
I am getting out of memory issue very often after updating buildToolsVersion '22.0.1' to buildToolsVersion '23.0.1' I am really confused and dont know how to solve this issue, since this error showing only with buildTools version 23.0.1 . Whereas it is working fine when I change it to 22.0.1 . Please help me. I am posting the error which I am getting as follows, Uncaught translation error: java.util.concurrent.ExecutionException: java.lang.OutOfMemoryError: Java heap space Uncaught translation error: java.util.concurrent.ExecutionException: java.lang.OutOfMemoryError: Java heap space Uncaught

How to run Gradle test when all tests are UP-TO-DATE?

佐手、 提交于 2019-11-28 04:26:36
I have my grade script set up. When I execute the Gradle build, everything is working and it runs the jUnit tests. After that when I run the Gradle test I get the following: C:\Users\..\..\Project>gradle test :compileJava UP-TO-DATE :processResources UP-TO-DATE :classes UP-TO-DATE :compileTestJava UP-TO-DATE :processTestResources UP-TO-DATE :testClasses UP-TO-DATE :test UP-TO-DATE When I perform gradle clean , then Gradle build works, of course... I want to be able to reset only the tests, not build the whole project: how should I do this? Amnon Shochot One option would be using the --rerun

Android Studio building errors using react native app

北慕城南 提交于 2019-11-28 04:23:10
问题 I have been trying to create an app using react native using expo tools xde and then detach it using exp detach, when I open in Android Studio I get quite many error when building like: Using incompatible plugins for the annotation processing Configuration 'compile' is obsolete and has been replaced with 'implementation' and 'api'. It will be removed at the end of 2018. For more information see: http://d.android.com/r/tools/update-dependency-configurations.html The specified Android SDK Build

What is the best way to solve the UNEXPECTED TOP-LEVEL EXCEPTION?

删除回忆录丶 提交于 2019-11-28 04:14:50
问题 When I make the application use many libraries. I usualy meet a error is UNEXPECTED TOP-LEVEL EXCEPTION This error have some reason as: Number function > 65k, we need enable multidex for it There are some libs is nested, we need add exclude in build.gradle. About second case, it is very difficult to detect what is the lib have been nested. If you have experience on this issue, please share me. UPDATE: dependencies { compile files('libs/ormlite-android-4.48.jar') compile files('libs/ormlite