Warning:android-apt plugin is incompatible

  • build.gradle 中 删除以下内容:
1
apply plugin: 'com.neenbedankt.android-apt'
  • buildscriptdependencies 中删掉:
1
classpath 'com.neenbedankt.gradle.plugins:android-apt:1.8'
  • 替换 dependencies 中的 apt:
1
apt 'com.google.dagger:dagger-compiler:2.0.2'

替换为:

1
annotationProcessor  'com.google.dagger:dagger-compiler:2.0.2'
  • 替换 jacocoClasspath:
1
jacocoClasspath = configurations['androidJacocoAnt']

替换为

1
jacocoClasspath = configurations['jacocoAnt']