简体   繁体   中英

android studio unable to find local maven repository

I placed the files of the repository in the.m2 folder but android studio is unable to resolve it

Caused by: org.gradle.internal.resolve.ModuleVersionNotFoundException: Could not find com.redcpt:sdk:0.0.1

does anyone know what might be the issue

In the comments you mention "the structure of that folder is sdk -> 0.0.1 ->.pom, .jar, .aar files here." . That is the wrong location. A Maven dependency with coordinates com.redcpt:sdk:0.0.1 should be saved in .m2/repository/com/redcpt/sdk/0.0.1/ .

It might be simpler to use Maven to install files into your local repository, see also How to add local jar files to a Maven project? (although I don't know what needs to be done to store the .aar file that way).

Android Studio automatically places the Maven repositories in the correct location when you download them from Maven. There's no reason to go into any local maven folders.

Start a new project from scratch while connected online and see if that helps. You will be given updated options on dependencies sourced from Maven.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM