Gradle buildscript dependencies
问题 What is the difference between declaring repositories in the buildScript section of the gradle build or in the root level of the build. Option 1: build.gradle : buildScript { repositories { mavenCentral(); } } or build.gradle : repositories { mavenCentral(); } 回答1: The repositories in the buildScript block are used to fetch the dependencies of your buildScript dependencies. These are the dependencies that are put on the classpath of your build and that you can refer to from your build file.