build.gradle

Android Studio 2.2.3 Gradle Build Running Stuck

时光总嘲笑我的痴心妄想 提交于 2019-12-17 21:08:23
问题 I download android studio 2.2.3 and load my project. But Gradle Build Running Stuck. It continuously shows that and i am not able to run my app. what is the issue can any one help me with that? Executing tasks: [:app:generateDebugSources, :app:generateDebugAndroidTestSources, :app:mockableAndroidJar, :app:prepareDebugUnitTestDependencies] buildscript { repositories { jcenter() } dependencies { classpath 'com.android.tools.build:gradle:2.2.3' // NOTE: Do not place your application dependencies

Android Studio 2.2.3 Gradle Build Running Stuck

早过忘川 提交于 2019-12-17 20:57:32
问题 I download android studio 2.2.3 and load my project. But Gradle Build Running Stuck. It continuously shows that and i am not able to run my app. what is the issue can any one help me with that? Executing tasks: [:app:generateDebugSources, :app:generateDebugAndroidTestSources, :app:mockableAndroidJar, :app:prepareDebugUnitTestDependencies] buildscript { repositories { jcenter() } dependencies { classpath 'com.android.tools.build:gradle:2.2.3' // NOTE: Do not place your application dependencies

AndroidStudio: What does 'debuggable' do?

半腔热情 提交于 2019-12-17 20:54:22
问题 I would like to know exactly what the debuggable true statement does: // build.gradle android { buildTypes { debug { debuggable true } } } I am able to debug without it using the emulator (genymotion): the breakpoints work; the Log.d(...) statements output to the Android Monitor; Since the debuggable flag is inside the debug section, it seems redundant anyway. Shouldn't it be outside the buildTypes section, indicating to the ide that the debug buildtype should be used? It would also be nice

Error:Execution failed for task ':app:transformClassesWithDexForDebug'. > com.android.build.api.transform.TransformException:..non-zero exit value 3

只谈情不闲聊 提交于 2019-12-17 20:12:33
问题 After Clean Project -> Rebuild Project my android project I am getting below error Error:Execution failed for task ':app:transformClassesWithDexForDebug'. > com.android.build.api.transform.TransformException: com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command '/usr/lib/jvm/java-7-oracle/bin/java'' finished with non-zero exit value 3 Gradle : apply plugin: 'com.android.application' android { compileSdkVersion 23 buildToolsVersion "23.0

Android: Execution failed for task ':app:processDebugResources'

折月煮酒 提交于 2019-12-17 19:48:38
问题 Error:Execution failed for task ':app:processDebugResources'. com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command '/home/mobi27/opt/AND-Studio/Android/Sdk/build-tools/22.0.1/aapt'' finished with non-zero exit value 1 回答1: My solution is: Menu Build -> Clean Project. I deleted and pasted a picture a while before. The picture has the same problem, so something wrong happened. 回答2: In my case I tried to change buildToolsVersion in gradle ,

Pulltorefresh add to gradle

不羁岁月 提交于 2019-12-17 19:09:26
问题 can anyone help me add this library in build.gradle Android Studio. https://github.com/chrisbanes/Android-PullToRefresh I know it is deprecated but I want to use it, I would appreciate if someone could help me what to write in dependencies { compile 'com.android.support:support-v4:18.0.0' compile 'com.android.support:appcompat-v7:+' compile '????' } as mentioned I want to use the deprecated library not new Actionbar-Pulltorefresh. tried to google it but couldn't find any help. 回答1: I suggest

create version.txt file in project dir via build.gradle task

雨燕双飞 提交于 2019-12-17 18:47:57
问题 Apologies in advance for my ignorance. I'm very new to gradle. My is goal is to have some task in my build.gradle file, wherein a file 'version.txt' is created in my project directory whenever I run the gradle terminal command in my project root. This 'version.txt' file needs to contain version metadata of the build, such as: Version: 1.0 Revision: 1z7g30jFHYjl42L9fh0pqzmsQkF Buildtime: 2016-06-14 07:16:37 EST Application-name: foobarbaz app (^Revision would be the git commit hash of the HEAD

Android Studio - Gradle sync error

陌路散爱 提交于 2019-12-17 18:38:52
问题 I have a synchronization error in Android Studio. I Use: 1.0.2 version from canary channel. Gradle : I tried with version 2.2.1(downloaded from https://www.gradle.org/downloads) and self-download version. JDK : jdk1.8.0_05 I created a new project and the error is always the same: Error:Unable to find method 'org.objectweb.asm.ClassReader.getMaxStringLength()I'. Possible causes for this unexpected error include: Gradle's dependency cache may be corrupt (this sometimes occurs after a network

Android Studio 3.0: buildToolsVersion not found in gradle files

自作多情 提交于 2019-12-17 18:27:55
问题 I recently installed new stable version of Android Studio (v3.0). Then created a new project and there was not any problem. But saw there is no buildToolsVersion field in the app-level build.gradle file. Even I searched all project files ( Ctrl Shift F ), but didn't find anything! What does this mean? And how can I determine what is the version of Build Tools in my app module? build.gradle (Project): // Top-level build file where you can add configuration options common to all sub-projects

Gradle - Could not find or load main class

倾然丶 夕夏残阳落幕 提交于 2019-12-17 10:56:07
问题 I'm trying to run a very simple project using Gradle and running into the following error when using the gradlew run command : could not find or load main class 'hello.HelloWorld' Here is my file structure: SpringTest -src -hello -HelloWorld.java -Greeter.java -build -libs -tmp -gradle -wrapper -build.gradle -gradlew -gradlew.bat I excluded the contents of the libs and tmp folders because I didn't think that would be relevant information for this issue, but I can add it in if need be. Here is