Pytan
Pytan

Reputation: 1684

Gradle not working after updating Android Studio

Gradle does not work at all, even gradle -v after updating android studio (4.3.1). I'm not pretty sure Android Studio caused this issue or not.

I installed Gradle from sdkman. The Gradle version is 6.6.1. When I run any Gradle command in terminal, the process keep running but nothing display. The path is not an issue here. Computer recognize Gradle itself.

Do you know any ideas to fix the issue?

I already uninstall/install Gradle, remove .gradle folder, restart a computer, remove cache and stuff like that...

Upvotes: 0

Views: 474

Answers (1)

Abhinav Kulshreshtha
Abhinav Kulshreshtha

Reputation: 2205

Android Studio likes to use it's bundled JDKs and SDKs by default and change the location of it's settings every few releases. It doesn't like when you try to customize settings to your preferences, even something as trivial as choosing your own default project save location.

Currently (in version 4.2.x), I could only find gradle path in global settings, which turns out that even if you set global setting for gradle path, you would still need to configure it per project level.

So for sake of sanity, forget global settings and configure it per project level. Gradle Configuration per project

There are some forum discussion which suggests that android studio automatically switched kotlin compiler or java compiler from your gradle settings, but there are some conflicting articles too.
If you try to discuss it on their forum, they will tell you it's bad decision to change jdk because of compatibility reasons, won't help you much. This is based on my multiple bad experiences on their forum. Choosing your own JDK, Kotlin, build-tools etc has been active sore-point with community.

PS: Kotlin compiler settings is available in Other settings.Kotlin compiler setting

Upvotes: 1

Related Questions