简体   繁体   中英

Idea Intellij: Ubuntu and Maven: Idea dependency not found error

I'm trying to import dependencies in Maven via Idea Intellij, however I get a Dependency [version] not found error:

在此处输入图像描述

It happens for all dependencies in pom.xml .

I checked the local repository /home/<User_Name>/.m2 folder and the jars are there:

在此处输入图像描述

在此处输入图像描述

在此处输入图像描述

So the jars exist, but Idea doesn't see them. I do reload Idea's Maven by clicking the left round button:

在此处输入图像描述

It worked fine on Windows, but doesn't on Ubuntu 18.04.

Try going to IntelliJ IDEA -> Preferences -> Build, Execution, Deployment -> Build Tools -> Maven -> Importing and mark the options like in the image below:

在此处输入图像描述

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