android-gradle

Gradle deprecation “Relying on packaging to define the extension of the main artifact…” in Android Studio project can be fixed?

≡放荡痞女 提交于 2019-11-29 05:30:19
I'd like to learn how to use Android Studio at the best, but I still have limited experience especially in building with Gradle . Executing tasks: [clean] Relying on packaging to define the extension of the main artifact has been deprecated and is scheduled to be removed in Gradle 2.0 :app:clean UP-TO-DATE BUILD SUCCESSFUL Even if everything works I would like to avoid using deprecated methods; I state that I see this question and tried to understand the deprecation message but fairly the focus for me now is understanding building APK on Android Studio and how to put hands in a project created

Program type already present: com.google.android.gms.internal.zzfq

≯℡__Kan透↙ 提交于 2019-11-29 05:29:18
I getting this error. Despite trying all thing I am unable to resolve it. Please help me. Things that I tried are: Delete .build , .idea etc then rebuild Clean and rebuild Change version of compile library Thank you plugins apply plugin: 'com.android.application' apply plugin: 'kotlin-android' apply plugin: 'kotlin-android-extensions' apply plugin: 'io.fabric' Android android { dexOptions { preDexLibraries = false javaMaxHeapSize "2g" } compileSdkVersion 27 buildToolsVersion '27.0.3' defaultConfig { applicationId "com.funzone.alarmnap" minSdkVersion 16 targetSdkVersion 27 versionCode 1

distribute Android library in jCenter to use in gradle

匆匆过客 提交于 2019-11-29 05:16:20
I have a library project with a module that is just for library classes and views. I've been searching over the internet how to distribute it in jCenter to use as a gradle dependency but nothing works. While this isn't done yet, how can I use this module in others projects? PS: I use Android Studio on Windows 10. Many of the tutorials and directions online are out of date or are very hard to follow. I just learned how to do this myself, so I am adding what will hopefully be a quick solution for you. It includes the following points Start with your Android library Set up a Bintray account Edit

Android MultiDex - Questions on Inner Workings

老子叫甜甜 提交于 2019-11-29 04:07:39
I recently discovered the new MultiDex functionality from Android for working with apps having more than 65,000 references. See: https://developer.android.com/tools/building/multidex.html Can someone help me understand the following questions: 1) How does the Gradle build plugin determine what to put in the primary dex file (classes.dex) vs the secondary dex files? Based on the doc there are certain things required to be in primary dex but it doesn't give any examples. Are all activities required to be in the primary dex file? Quoted Text: There are complex requirements regarding what classes

Gradle DSL method not found: 'implementation()'

我的未来我决定 提交于 2019-11-29 03:12:20
I had this error Error:(45, 0) Gradle DSL method not found: 'implementation()' Possible causes:<ul><li>The project 'LaTaxi2' may be using a version of the Android Gradle plug-in that does not contain the method (e.g. 'testCompile' was added in 1.1.0). <a href="fixGradleElements">Upgrade plugin to version 2.3.3 and sync project</a></li><li>The project 'LaTaxi2' may be using a version of Gradle that does not contain the method. <a href="open.wrapper.file">Open Gradle wrapper file</a></li><li>The build file may be missing a Gradle plugin. <a href="apply.gradle.plugin">Apply Gradle plugin</a></li>

Gradle build not working: Execution failed for task ':MyApp:compileDebug'

跟風遠走 提交于 2019-11-29 02:51:21
I'm trying to migrate a project to Gradle, but I get an exception raised everytime I run the command gradle build --stacktrace I'm using Gradle 1.6. Here's the stack trace for the error: :MyApp:compileDebug FAILED FAILURE: Build failed with an exception. * What went wrong: Execution failed for task ':MyApp:compileDebug'. > Compilation failed; see the compiler error output for details. * Try: Run with --info or --debug option to get more log output. * Exception is: org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':MyApp:compileDebug'. at org.gradle.api.internal.tasks

Android Studio: Could not find com.android.tools.build:gradle:2.0.0-alpha2

泄露秘密 提交于 2019-11-29 02:48:10
Recently I have updated my Android Studio to latest version from Latest Android Studio Canary Build: 2.0 Preview After updating to the new version, my current working directory stop working at all. Every single time when I am trying to clean and build a project they will give me an error like this Blockquote 'Error:Could not find com.android.tools.build:gradle:2.0.0-alpha2. Searched in the following locations: file:/Applications/Android Studio.app/Contents/gradle/m2repository/com/android/tools/build/gradle/2.0.0-alpha2/gradle-2.0.0-alpha2.pom file:/Applications/Android Studio.app/Contents

Android Seek bar with specified hint

好久不见. 提交于 2019-11-29 02:45:07
I am new to android Please any one help.how to change Seek bar hint.I have four types of food in seek bar.When I change the Seek bar to one food item.I need to show a hit message that related food item. Check this discreteSeekBar , Dependencies It uses com.android.support:support-v4 as the only dependency . Usage repositories { jcenter() } dependencies { compile 'org.adw.library:discrete-seekbar:1.0.1' } You can use these libraries for android tooltip. Follow these link. https://github.com/xizzhu/simple-tool-tip https://github.com/sephiroth74/android-target-tooltip 来源: https://stackoverflow

relation between gradle version and gradle build tool version

自古美人都是妖i 提交于 2019-11-29 02:23:44
I'm new to gradle and got 2 questions: gradle itself is a build tool, so why is the need for Android gradle tool com.android.tools.build:gradle:0.7.+ in the script? What is the relation between the version of gradle installed (say 1.9) and the version of that Android gradle tool, like 0.7.+ in classpath 'com.android.tools.build:gradle:0.7.+' . If I changed the latter's version to 0.8.+ then the build fails on 'could not find plugin AppPlugin'. I will try to answer your questions. As you said, Gradle is a build tool, but the line you have mentioned in your first question is referring to Gradle

Error on installing apk - parsing the package

寵の児 提交于 2019-11-29 02:13:28
I am working on an android app and everything works fine when I build it in my local system and run on emulator, but as soon as I make and release and install apk on my phone, it crashes with error - There was an error parsing the package As you can see, I am building with latest SDK and build tools, and my phone is running the same version on API too. I have Untrusted Sources installation allowed too. I am taking help of "Build a release version" section on this link. It is generating a file like - app-release-unsigned.apk in my app/build/outputs/apk folder. Please help with it. Emulator AVD