build.gradle

How to run copy task with android studio into assets folder

我们两清 提交于 2019-12-28 02:51:50
问题 So far I have added the following to the end of my "build.gradle" task copyFiles(type: Copy) copyFiles { description = 'Copies html5 files from the common library...' from '../../www' into 'assets/www' include('**/*') } Now I just need some help on how o make this task get executed everytime (before) compiling the android source. I can run the copy task manually from command line, but Id like to have it run when I click "run" in android studio. With the help of suggestion below, I have added

Difference between build.gradle(Project) and build.gradle(Module)

﹥>﹥吖頭↗ 提交于 2019-12-28 01:49:05
问题 I am trying to add a dependency of Android Asynchronous Http Client into my project. So there are two build.gradle files are there in the project. As per my understanding, there are different kind of dependencies: One which defined on the root level of build.gradle(Project:My-app) One inside the buildscript of the build.gradle(Project:My-app) Another is build.gradle(Modules:app) This question is about repositories for dependencies of the buildScript, explain a bit about first two types. Also

Java finished with non-zero exit value 2 - Android Gradle

谁说我不能喝 提交于 2019-12-27 08:15:06
问题 I'm getting this error executing my Android app (I cleaned it and then built it, but the error is still present) Sync: OK Make Project: OK Clean: OK Run: Error Error:Execution failed for task ':app:dexDebug' .com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Program Files\Java\jdk1.7.0_25\bin\java.exe'' finished with non-zero exit value 2 My gradle file: apply plugin: 'com.android.application' android { compileSdkVersion 21

Java finished with non-zero exit value 2 - Android Gradle

≡放荡痞女 提交于 2019-12-27 08:14:51
问题 I'm getting this error executing my Android app (I cleaned it and then built it, but the error is still present) Sync: OK Make Project: OK Clean: OK Run: Error Error:Execution failed for task ':app:dexDebug' .com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Program Files\Java\jdk1.7.0_25\bin\java.exe'' finished with non-zero exit value 2 My gradle file: apply plugin: 'com.android.application' android { compileSdkVersion 21

Local Path doesn't exist

主宰稳场 提交于 2019-12-25 16:44:55
问题 After updating Android Studio to 0.4.5, I cannot get my application to build. I have the following configurations: dependencies { classpath 'com.android.tools.build:gradle:0.8.+' compile 'com.android.support:support-v4:19.0.1' compileSdkVersion 19 buildToolsVersion "19.0.1" defaultConfig { minSdkVersion 14 targetSdkVersion 19 renderscriptTargetApi 19 renderscriptSupportMode true NOTE: Cleaning + Rebuilding the project, deleting .iml/idea files and reimporting the project, setting APK_PATH,

Why my gradle building taking too much time?

怎甘沉沦 提交于 2019-12-25 07:39:50
问题 I am developing the app which has apk size 28 MB. What should I do so that I take less time. If I run on emulator than it takes 5-7 mins but if I run it on device than it is taking more than 10 min. 回答1: you can set file->setting->search 'Gradle'-> check 'use local gradle distribution' and check 'offline work' .. in android studio. it will improve gradel building time. 回答2: I too had this issue, what i had done was disabling instant run in the project settings, and rebuilding the project. 回答3

Merged rootsChanged not allowed inside rootsChanged, rootsChanged level == 1

五迷三道 提交于 2019-12-25 06:03:08
问题 On Gradle sync of my Android application in Android Studio my Event Logs shows me the Following Error: Throwable:Merged rootsChanged not allowed inside rootsChanged, rootsChanged level == 1 But I don't know what is it for and how to resolve it. I had searched for it but didn't find anything relevant to it. Can anybody can help me for the same? Thanks in Advance. 回答1: It seems related to some change in your modules. Check https://code.google.com/p/android/issues/detail?id=183881 Do the follow

Merged rootsChanged not allowed inside rootsChanged, rootsChanged level == 1

半世苍凉 提交于 2019-12-25 06:01:05
问题 On Gradle sync of my Android application in Android Studio my Event Logs shows me the Following Error: Throwable:Merged rootsChanged not allowed inside rootsChanged, rootsChanged level == 1 But I don't know what is it for and how to resolve it. I had searched for it but didn't find anything relevant to it. Can anybody can help me for the same? Thanks in Advance. 回答1: It seems related to some change in your modules. Check https://code.google.com/p/android/issues/detail?id=183881 Do the follow

Why does the generated Cloud Endpoints library change its version now and then?

末鹿安然 提交于 2019-12-25 05:29:22
问题 An App Engine project in Android Studio is (by default) configured to generate a client library, which can be consumed by an Android and/or iOS app. Gradle is configured to auto-generate the library: apply plugin: 'appengine' appengine { downloadSdk = true appcfg { oauth2 = true } endpoints { getClientLibsOnBuild = true getDiscoveryDocsOnBuild = true } } Note there is no version specified anywhere here. As specified in https://cloud.google.com/appengine/docs/java/endpoints/gen_clients, the

Duplicate Entry Error - Dependancy and Project Module Confliction - Android

你离开我真会死。 提交于 2019-12-25 04:40:33
问题 First of all. Below is the error that I am getting. Now, What I am doing is like below.... I am integrating Speech To Text service of IBM. I have founded a demo HERE! I am also using another two Services of IBM named Personality Insights and Cloudant Database . I have successfully integrated Speech To Text example. But When I integrate Personality Insights and Cloudant Database it gives me above error. WHAT I HAVE IDENTIFIED: In STT demo there is a module called speech-android-wrapper . Which