Extract your dependencies from your top level gradle build. Since you are creating a classpath with your top level gradle and then trying to overwrite it with your other build.gradles
From:
buildscript { repositories { mavenCentral() jcenter() maven { url 'https://maven.fabric.io/public' } } dependencies { classpath 'com.android.tools.build:gradle:2.0.0-alpha6' classpath 'com.novoda:bintray-release:0.2.7' classpath 'io.fabric.tools:gradle:1.+' }}
To: Note. I did not add this commented line, Android-Studio does it automatically
buildscript { repositories { jcenter() } dependencies { classpath 'com.android.tools.build:gradle:2.0.0-alpha6'
You should be able to add any necessary Maven repositories to your individual application gradients, as they must be specific, and jcenter will cover many of them, as @AndroidMechanic , and @Hi I Frogatto tried to say in previous answers and comments. Look here Bintray - JCenter
Another thing, I donβt understand why you manage your libraries by creating gradle in your project as part of your project. You must reference your library from your project using the build.gradle application. You treat the gradle library as a gradle application.
dependencies { compile fileTree(include: '*.jar', dir: 'libs') compile 'com.android.support:support-v4:23.1.0' compile 'com.android.support:appcompat-v7:23.1.0' testCompile 'junit:junit:4.12' }
Make these changes, then see what duplicates, and you can manage it from there.
In addition, I recommend manually synchronizing the project with gradle files when making changes. I did not count on anything, it is important to take a step by step and analyze what is happening, especially when it will not be compiled. This is my opinion, only one way of programming in android.
If instant start creates chaos with a specific project, I will disable it for this project. It is enabled by default, and I had no problems with it. Damage to the assembly may be the result of fuzzy hail in your project.
also:
The gradle shell properties for classpath 'com.android.tools.build:gradle:2.0.0-alpha6' require class 2.10:
distributionUrl=https\://services.gradle.org/distributions/gradle-2.10-all.zip
Watch the latest news Android Tools project site
Or you can install the previous version of Android Studio and use the previous working version of your project.
If you have several git files, I suggest removing the extra ones, save only those that you use for version control.