1 : build.gradle project添加
classpath'com.android.tools.build:gradle:2.1.0'
classpath'com.neenbedankt.gradle.plugins:android-apt:1.8'
2 :buil.gradle app添加
applyplugin:'android-apt'
compile'com.jakewharton:butterknife:8.2.1'
apt'com.jakewharton:butterknife-compiler:8.2.1'
3 :去setting/plugins/添加butterknife
然后restart一下就ok
注意:ButterKnife.bind(this); 要放在布局文件下方