Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
395 views
in Technique[技术] by (71.8m points)

Intellij IDEA Maven Import problems

I wanted to switch to IntelliJ for forge modding (minecraft). When I do what they are saying to do on internet, I get a maven error...

            Unindexed remote maven repositories found. Disable...
            The following repositories used in your gradle projects were not indexed yet: 
            http://files.minecraftforge.net/maven
            If you want to use dependency completion for these repositories artifacts,
            Open Repositories List, select required repositories and press "Update" button

When I click update, it loads for half a second and then gives the same error again... I searched on internet and nobody seems to have my problem... help please ?

Question&Answers:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

Check idea.log for errors. It may fail with OutOfMemory error in which case you can try increasing the heap size for Maven Importer (VM options for importer) and IDE heap size.

Try not to exceed 750-1024m for -Xmx value if you are running on a 32-bit JVM (default), otherwise it may crash or fail to start.

If you need to use more heap, switch to 64-bit Java and specify the same 64-bit JVM for Maven (JDK for importer) in IntelliJ IDEA settings.

Another possible case is if IDE cannot connect to the Maven process. On some systems it's needed to edit the hosts file so that localhost resolves correctly.

There was also a bug caused by Nvidia driver (java process was crashing). Make sure you have the latest driver if this applies to your hardware.

If all the above doesn't help, share your idea.log file.

Note that indexing repositories is not required for working with a project, but it may indicate that Maven fails to work for one of the reasons above (or some other). See if the dependencies for the project were imported and if you can build the imported project in IDEA.

Some repositories cannot be indexed at all, in this case just ignore the error.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...