Maven : error in opening zip file when running maven

后端 未结 17 2173
-上瘾入骨i
-上瘾入骨i 2020-11-29 03:28
[ERROR] error: error reading C:\\Users\\suresh\\.m2\\repository\\org\\jdom\\jdom\\1.1\\jdom-1.1.jar; error in opening zip file
[ERROR] error: error reading C:\\Users         


        
17条回答
  •  既然无缘
    2020-11-29 03:52

    Deleting the entire local m2 repo may not be advisable. As in my case I have hundreds and hundreds of jars in my local, I don't want to re-download them all just for one jar. Most of the above answers didn't work for me, here is what I did.

    STEP:1: Ensure if you are downloading from the correct Maven repo in you settings.xml. In my case it was referring to http://central.maven.org/maven2/ as https://repo1.maven.org/maven2/. So it was getting corrupted or going otherwise?

    STEP:2: Delete the folder containing the artifact and other details in your local machine.This will force it download it again upon next build

    STEP:3: mvn clean install :).

    Hope it helps.

提交回复
热议问题