在从github clone 下项目来,导入工程跑不起来,报的如下错误:
Error:No service of type Factoryavailable in ProjectScopeServices.
是maven的版本出现了问题:
在工程的build.gradle 文件下将
buildscript{
repositories{
jcenter() }
dependencies{
classpath'com.android.tools.build:gradle:2.1.3'
classpath'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.2'
classpath'com.github.dcendents:android-maven-gradle-plugin:1.3'
}
}
google后发现:
直接将' classpath com.github.dcendents:android-maven-gradle-plugin:1.3'更新到1.4.1就可以解决问题了。