Rudresh Rajvansh
Rudresh Rajvansh

Reputation: 59

Executing Gradle without a settings file has been deprecated : How to write a setting file and where to save

hello friends i am new to android studio(ver :3.6.1) and gradle(ver:6.0.3) i have just somehow installed it (means my gradle was not installing or taking time so i manually installed files in chrome and placed it in folder and everything is okay but due to version upgrade i am facing this issue) and when i used to sync it , it shows me error that the Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.Use '--warning-mode all' to show the individual deprecation warnings. See https://docs.gradle.org/6.3/userguide/command_line_interface.html#sec:command_line_warnings then i did same build with --warning-mode all and i got this message --Executing Gradle tasks as part of an undefined build has been deprecated. This will fail with an error in Gradle 7.0. Consult the upgrading guide for further in formation: https://docs.gradle.org/6.3/userguide/upgrading_version_5.html#executing_gradle_without_a_settings_file_has_been_deprecated afterthat i went to the given link and then i found this Have A look to Image i don't know how to write the setting.gradle or setting.gradle.kts file and where to save it i once tries to save it in my gradle home folder but it gave me another error that the method i used to do so is not known i have attached my gradle project build log screenshots have a look to image thank u i hope u will help me please give me suggestions and help me to do it 😞😞

Upvotes: 2

Views: 19893

Answers (1)

Thomas Kläger
Thomas Kläger

Reputation: 21490

No need to hurry - as long as you don't upgrade to Gradle 7.0 nothing bad will happen. And since Gradle 6.3 has been released quite recently the next release is at least 5 to 6 weeks away...

If your project is a simple project without subprojects, the settings.gradle file can be an empty file (though it needs to exist).

You must place it into the same directory as your build.gradle file.

You need more content in the settings.gradle file if you start creating multi-project builds. The documentation about multi-project builds is part of the gradle documentation (what a surpise!): https://guides.gradle.org/creating-multi-project-builds/

Detailed information about the allowed settings are available at https://docs.gradle.org/current/dsl/org.gradle.api.initialization.Settings.html

Upvotes: 4

Related Questions