I upgraded the Android Studio to AS 0.6 then imported the project developed in AS 0.3
I am getting errors like:
Build script error,unsupported Gradle DSL
Think of “Gradle DSL method” as a Java method. So in Gradle, methods can be distinguished by either {} or “.”. So
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
}
is the same as
dependencies.compile fileTree(dir: 'libs', include: ['*.jar'])
where both “dependencies” and “compile” are methods.
So you are including a method somewhere in your build.gradle file that is not supported by your program. For example, make your dependencies this:
dependencies {
nothing 'this.does.nothing.build:gradle:0.7.+'
}
Which is the same as writing:
dependencies.nothing 'this.does.nothing.build:gradle:0.7.+'
And you will see an error saying “unsupported Gradle DSL method found: ‘nothing()’!” Obviously "nothing" is not a real method. I just made it up.
So one of your "android" methods is wrong.
Actually it stated in the error message. So just add
apply plugin: 'com.android.application'
between dependencies
section and android
section