build.gradle

How to fix this error duplicate class found in module class.jar

两盒软妹~` 提交于 2020-01-14 13:02:44
问题 I got this error when I try to generate signed apk for my project Duplicate class com.google.android.gms.measurement.AppMeasurement found in modules classes.jar (com.google.android.gms:play-services-measurement-impl:16.5.0) and classes.jar (com.google.firebase:firebase-analytics-impl:10.0.1) Duplicate class com.google.firebase.analytics.FirebaseAnalytics found in modules classes.jar (com.google.android.gms:play-services-measurement-api:16.5.0) and classes.jar (com.google.firebase:firebase

Provided Gradle Dependency Is AAR not JAR

自作多情 提交于 2020-01-12 11:40:13
问题 I have an issue where I'm trying to include a library in my project called the ParseLoginUI . The issue is it uses the provided tag instead of compile. I believe the provided tag means that the project needs to supply this dependency in order for the library to work rather than this library compiling the libraries itself. So in my Android library it references the Facebook SDK like so. provided 'com.facebook.android:facebook-android-sdk:4.0.1' Then in my mobile/build.gradle which is my main

Provided Gradle Dependency Is AAR not JAR

落花浮王杯 提交于 2020-01-12 11:40:09
问题 I have an issue where I'm trying to include a library in my project called the ParseLoginUI . The issue is it uses the provided tag instead of compile. I believe the provided tag means that the project needs to supply this dependency in order for the library to work rather than this library compiling the libraries itself. So in my Android library it references the Facebook SDK like so. provided 'com.facebook.android:facebook-android-sdk:4.0.1' Then in my mobile/build.gradle which is my main

Configuration with name 'compileClasspath' not found

こ雲淡風輕ζ 提交于 2020-01-12 06:50:08
问题 When I migrate to com.android.tools.build:gradle:3.0.0-beta3 and Gradle 4.1, I am seeing the following error: Caused by: org.gradle.api.artifacts.UnknownConfigurationException: Configuration with name 'compileClasspath' not found. at org.gradle.api.internal.artifacts.configurations.DefaultConfigurationContainer.createNotFoundException(DefaultConfigurationContainer.java:123) at org.gradle.api.internal.DefaultNamedDomainObjectCollection.getByName(DefaultNamedDomainObjectCollection.java:229) at

Override resources with gradle depending on buildType

纵饮孤独 提交于 2020-01-11 15:34:05
问题 I want to override some strings in my res/strings.xml with gradle. I know that since Android Gradle Plugin 0.7.+ theres the possibilty to have a variant specific source folder. But my app has a lot of flavors and I don't want to add additionally variant specific folders. UPDATE 2014-01-17 What I want in detail: I have some variables in my Resources that are depending only by the buildType (e.g. "release"). First I thought my SOLUTION_1 (override data after resources were merged) is nice,

Can't import project to android studio

£可爱£侵袭症+ 提交于 2020-01-11 05:18:08
问题 I'm trying to use this library I've added compile 'net.rdrei.android.dirchooser:library:2.0@aar' to dependecies. My top level build file // Top-level build file where you can add configuration options common to all sub-projects/modules. buildscript { repositories { mavenCentral() } dependencies { classpath 'com.android.tools.build:gradle:0.8.+' } } allprojects { repositories { mavenCentral() } } And it gives me error "failed to refresh gradle project" with reference to the project, that I'm

java.lang.NoClassDefFoundError: when trying to run jar

扶醉桌前 提交于 2020-01-11 04:43:07
问题 I have a spring boot project using gradle apply plugin: 'java' apply plugin: 'idea' apply plugin: 'jetty' apply plugin: 'war' apply plugin: 'org.springframework.boot' repositories { mavenCentral() } dependencies { compile("org.springframework.boot:spring-boot-starter-web:1.5.1.RELEASE") { exclude module: "spring-boot-starter-tomcat" } compile group: 'org.springframework.boot', name: 'spring-boot-starter-jetty', version: '1.5.1.RELEASE' compile group: 'org.springframework.boot', name: 'spring

DexArchiveMergerException: Unable to merge dex

◇◆丶佛笑我妖孽 提交于 2020-01-11 03:53:06
问题 Just after updating Android studio 3.0 yesterday from 2.3.3 version, I am facing issue related to DexMergerException. Someone else also posted question-related to this. But in this question, I want to analyze the stack trace to find the related solution(since i am newbiew here..). I am unable to resolve it even after excluding group that might be using it. Since I am not aware of which component colliding with HttpCore so I'd use this code to exclude httpCore: implementation ('com.android

Failed to sync Gradle project

喜夏-厌秋 提交于 2020-01-10 07:18:21
问题 I am using Android studio 1.3.1 and getting this failed to sync Gradle project error : Error:Unable to start the daemon process: could not reserve enough space for object heap. Please assign more memory to Gradle in the project's gradle.properties file. For example, the following line, in the gradle.properties file, sets the maximum Java heap size to 1,024 MB: org.gradle.jvmargs=-Xmx1024m my default org.gradle.jvmargs=-Xmx2048 and MaxPermSize=512m still it is showing me this error, can

Failed to sync Gradle project

为君一笑 提交于 2020-01-10 07:18:09
问题 I am using Android studio 1.3.1 and getting this failed to sync Gradle project error : Error:Unable to start the daemon process: could not reserve enough space for object heap. Please assign more memory to Gradle in the project's gradle.properties file. For example, the following line, in the gradle.properties file, sets the maximum Java heap size to 1,024 MB: org.gradle.jvmargs=-Xmx1024m my default org.gradle.jvmargs=-Xmx2048 and MaxPermSize=512m still it is showing me this error, can