gradle-plugin
Difference apply from vs apply plugin
The actual difference between apply from: and apply plugin: is that the former is to be used for script plugins given a path to the local file system or a URL to a remote location, and the latter is used for binary plugins using the plugin id. You can read more about it in Gradle … Read more
build failing during merge resources with Android Gradle plugin 3.3.0
Updated 19th April, 2019 This issue has been fixed in Android Gradle Plugin 3.4.0. After upgrading to Android Studio 3.4.0, the temporary fix suggested in the original answer can be removed. Hurray! Original This is a bug in AAPT2 in Android Gradle Plugin 3.3.0, when building a project with larger png’s (around 2-3 mb and … Read more
build failing during merge resources with Android Gradle plugin 3.3.0
Updated 19th April, 2019 This issue has been fixed in Android Gradle Plugin 3.4.0. After upgrading to Android Studio 3.4.0, the temporary fix suggested in the original answer can be removed. Hurray! Original This is a bug in AAPT2 in Android Gradle Plugin 3.3.0, when building a project with larger png’s (around 2-3 mb and … Read more
How to fix “plugin was not found in any of the following sources”
I saw the problem even on command line and it helped when I added plugin management to the start of setting.gradle file: pluginManagement { repositories { maven { url “https://plugins.gradle.org/m2/” } gradlePluginPortal() } }
Android-studio 3.4.0-3.4.2 Gradle ERROR: No value has been specified for property ‘manifestOutputDirectory’
Mac OS – Click Android Studio > Preferences > Experimental then you have to uncheck – Only sync the active variant. Windows – File > settings > Experimental then you have to uncheck – Only sync the active variant.
How can the gradle plugin repository be changed?
Gradle 3.5 and (presumably) later Gradle 3.5 has a new (incubating) feature, allowing finer control of the plugin dependency resolution, using the pluginManagement DSL: Plugin resolution rules allow you to modify plugin requests made in plugins {} blocks, e.g. changing the requested version or explicitly specifying the implementation artifact coordinates. To add resolution rules, use … Read more
Update Gradle in Flutter project
Here is how I upgraded gradle in my older Flutter project: Create a new temp project with the latest version of Flutter. You’ll use this to see what version of gradle Flutter is using nowadays. In the temp project open android/build.gradle check the classpath version of gradle being used and update that in your old … Read more
org.gradle.api.InvalidUserCodeException: Querying the mapped value of provider (java.util.Set) before task … has completed is not supported
Under projects build.gradle file update the com.google.gms:google-services to version 4.3.14. dependencies { classpath ‘com.google.gms:google-services:4.3.14’ }
cvc-complex-type.2.4.a: Invalid content was found starting with element ‘base-extension’. One of ‘{layoutlib}’ is expected
Upgrade your com.android.tools.build:gradle in your build.gradle file to the latest version e.g. classpath ‘com.android.tools.build:gradle:7.0.4’ And upgrade your gradle-wrapper.properties to the latest version i.e. #Tue Apr 12 23:39:17 AEST 2022 distributionBase=GRADLE_USER_HOME distributionUrl=https\://services.gradle.org/distributions/gradle-7.6-bin.zip distributionPath=wrapper/dists zipStorePath=wrapper/dists zipStoreBase=GRADLE_USER_HOME Optionally, you can upgrade it using Project-Structure UI