Reputation: 2841
I have noticed that my IntelliJ doesn't properly show javadoc/sources. I have downloaded them thru right click -> maven -> download sources and documentation. When I go to the directory where its supposed to be located, I find everything that I need :
xxx-javadoc.jar.lastUpdated
xxx.sources.jar.lastUpdated
The issue seems to be .lastUpdated part. When I look at my project dependencies I can see clearly that intelliJ looks for xxx-javadoc.jar instead of
xxx-javadoc.jar.lastUpdated
How can I make sure that IntelliJ properly downloads and names javadoc/sources properly? I don't want to manually rename everything and then manually set javadoc/sources through IntelliJ interface.
I think this issue happened when I interrupted the download of sources/documentation
Upvotes: 1
Views: 348
Reputation: 2841
Ok, I have searched around and problem was probably caused by interuption of download sources/documentation process. Using bat file :
@echo off
setlocal EnableDelayedExpansion
set last=?
for /f %%I in ('dir /s /b /o:n /a-d "*.lastUpdated"') do (
if !last! NEQ %%~dpI (
set last=%%~dpI
echo !last!
rd /s /q !last!
)
)
goto end
:end
I managed to remove all the necessary files. Now downloading again. If this happens to you, use the above bat script if you are on windows.
Upvotes: 0
Reputation: 311853
The .lastUpdated
files are not the jar fails themselves, but a mechanism that Maven uses to track when it last updated a file. I.e., the file you should load in IntelliJ is the jar file, not the .lastUpdated
file.
If an interrupted/corrupted update is causing issues, remove that fail along with its .lastUpdated
file and download (synchronize in IntelliJ) it again.
Upvotes: 2