Resource nexus-maven-repository-index.properties does not exist in IntelliJ

夙愿已清 提交于 2020-01-30 18:53:08

问题


While experimenting with Grails 3 under IntelliJ I found the following warning:

 Unindexed remote maven repositories found. Disable...
 The following repositories used in your gradle projects were not indexed yet: 
 https://repo.grails.org/grails/core
 If you want to use dependency completion for these repositories artifacts,
 Open Repositories List, select required repositories and press "Update" button (show balloon)

If I am trying to resolve an issue, I get next error:

FileNotFoundException: Resource nexus-maven-repository-index.properties does not exist in IntelliJ

I would prefer to know, what does it mean? If repository is marked as "remote", then why the problem is absence of some (local?) file?

UPDATE

I think this is not related with Grails actually.

How to know more details on error, occurring in Indexed Maven Repositories Window in IntelliJ on Update button?

The popup message says

Resource nexus-maven-repository-index.properties does not exist in IntelliJ


回答1:


  • If you're using your custom repository
  • AND it is Nexus 3.x

chances are high that you forgot to set up a Task to publish your maven repository indexes.

Log in via browser. Go to Administration/System/Tasks/Create Task/Create Publish Maven indexes Task

Set it for an hourly publish. Done.




回答2:


For me the solution was to delete the folder ~/.m2/repository. This made Maven to re-index everything correctly.

Failed trials, that may work for someone else:

  • Build, Execution, Deployment → Build Tools → Maven → Repositories : Selecting the repositories and click updates.
  • Build, Execution, Deployment → Build Tools → Maven: Giving more memory JVM
  • Delete folder ~/.IntelliJIdea2016.3/system/caches



回答3:


You can try using grails/repo and grails/plugins instead of grails/core.

For example, in build.gradle:

repositories {
    mavenLocal()
    maven { url 'http://repo.grails.org/grails/repo' }
    maven { url 'http://repo.grails.org/grails/plugins' }
}

I tested on IntelliJ Community 15 with Grails 3.0.9, JVM Version: 1.8.0_45, Apache Maven 3.3.9 and Gradle 2.3.




回答4:


The same error occurs for Artifactory users. Solved with sanya's hint. Make sure the local repositories are included.

After that the repo works:



来源:https://stackoverflow.com/questions/34104305/resource-nexus-maven-repository-index-properties-does-not-exist-in-intellij

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!