After updating IntelliJ from version 12 to 13, the following Maven-related plugins cannot be resolved:
org.apache.maven.plugins:maven-clean-plugin:2.4.1
org.a
Uncheck the "Work offline" checkbox in Maven settings.
I have change the Maven home directory from Bundled(Maven 3) to Bundled(Maven 2) in the maven setting. And this works for me. Have a try!
SOLVED !!!
This is how I fixed the issue...
Tried again one of the answers in the thread which says 'If that does not work, Invalidate your caches (File > Invalidate caches) and restart.' Did that but again no luck.
Tried These options .. Go to Settings --> Maven --> Importing and made sure the following was selected
Import Maven projects automatically
Create IDEA modules for aggregator projects Keep source...
Exclude build dir...
Use Maven output...
Generated souces folders: "detect automatically"
Phase to be...: "process-resources"
Automatically download: "sources" & "documentation"
Use Maven3 to import
project VM options for importer: -Xmx512m
But again no success.
I had this problem for years with the maven-deploy plugin, and the error showed up even though I was not directly including the plugin in my POM. As a work-around I had to force include the plugin with a version into my POMs plugin section just to remove the red-squiggly.
After trying every solution on Stack Overflow, I found the problem: Looking into my .m2/repository/org/apache/maven/plugins/maven-deploy-plugin
directory there was a version 'X.Y' along with '2.8.2' et al. So I deleted the entire maven-deploy-plugin directory, and then re-imported my Maven project.
So it seems the issue is an IntelliJ bug in parsing the repository. I would not not remove the entire repository though, just the plugins that report an error.
For me, there was a mistake in the settings.xml. I was using http:// in the url due to which it wasn't working. Once i removed it the plugins were downloaded successfully.
<proxy>
<id>optional</id>
<active>true</active>
<protocol>http</protocol>
<host>www-proxy.xxxx.com</host>
<port>80</port>
<!-- <nonProxyHosts>local.net</nonProxyHosts>-->
</proxy>
<!-- Proxy for HTTPS -->
<proxy>
<id>optional1</id>
<active>true</active>
<protocol>https</protocol>
<host>www-proxy.xxxx.com</host>
<port>80</port>
<!--<nonProxyHosts>local.net</nonProxyHosts>-->
</proxy>
I had the same error and was able to get rid of it by deleting my old Maven settings file. Then I updated the Maven plugins manually using the mvn command:
mv ~/.m2/settings.xml ~/.m2/settings.xml.old
mvn -up
Finally I ran the "Reimport All Maven Projects" button in the Maven Project tab in IntelliJ. The errors vanished in my case.