Quantcast
Channel: Programming – Xinyustudio
Viewing all articles
Browse latest Browse all 284

‘com.github.dcendents.android-maven’ not found, the solution

$
0
0

Recently, I build some open source Android libraries, and when building the project, below error occurred:

Error:(2, 0) Plugin with id ‘com.github.dcendents.android-maven’ not found.

Quick Solution:

install Yarn, everything works!

Mac: brew install yarn
Windows: refer to this link.

 

A less elegant solution is to manually change the top level build.gradle:

From

dependencies {
classpath ‘com.android.tools.build:gradle:2.2.2’
}

To –>

dependencies {
classpath ‘com.android.tools.build:gradle:2.2.2’
classpath com.github.dcendents:android-maven-gradle-plugin:1.5  //Add this
classpath com.jfrog.bintray.gradle:gradle-bintray-plugin:1.7.3      //Add this

}

Rebuild. It should work. But this is tedious, for every project (e.g. react-native), you repeat doing so?  Emmmmmm!

Now try to create a new react-native project using:

react-native init ProjectName

Run the project:

react-native run-android  // or
react-native run-ios

It compiles and works! Happy coding.


Filed under: Android Tagged: 'com.github.dcendents.android-maven' not found, 0) Plugin with id, android, bintray, class path, Error:(2, Gradle, how to, jfrog, maven gradle plugin, not found, the solution, troubleshooting

Viewing all articles
Browse latest Browse all 284

Trending Articles