Getting External Libraries Easily
JARs of many frameworks and their dependencies get updated too often now. But you do not want to turn your project into a Maven project just because of this? Then this feature is just for you.
In IntelliJ IDEA 10 you can search for & download libraries with dependencies for any framework published on some public maven repository. Minimum Maven experience is required. Just click ‘Attach Classes from Repository…‘
You can add your company repository to the list of searched repositories, if it is managed by Nexus, by providing the Nexus URL in Settings | Maven | Repository Indices | Nexus Locations list.
Try this in IntelliJ IDEA X EAP and let us know how it works for you.
UPDATE JavaDocs & Sources download as well as the Artifactory support are now available.
Ted Wise says:
August 13, 2010Why just Nexus? Because you’re using the Nexus public index? Artifactory can generate Nexus public indexes if you turn the feature on in the admin console.
So if that’s the reason why the restriction to Nexus you should be able to use Artifactory as well.
Stephen says:
August 13, 2010Would be nice if I could also specify a path to store source files to (optionally zipped).
I hate it when I can’t look into sources, so the feature is not of much use for me without this.
alphageek says:
August 13, 2010Would be great if it can work with Ivy-based project too
Behrang says:
August 14, 2010I guess I was the one who suggested this feature, right? And I am very pleased to see it added to the next version of IDEA. 🙂
Doesn't work for me says:
August 14, 2010Doesn’t work for me.
I’ve tried with google guice 2.0 jars.
They are downloaded from repository, but never attached to the project. I mean the new guice library appears as attached (and contains both guice and aopalliance jars) but they are “not really” attached to the project. I use this feature only as an easy way to fetch some library, but then attach the downloaded jars with Attach Classes…
Certainly it will be a very handy way to attach jars to projects.
buildno = 96.802
Why doesn’t allow Idea IntelliJ About dialog to copy some stuff – like build no?
Doesn't work for me says:
August 14, 2010I’ve tried with google guice 2.0 jars.
They are downloaded from repository, but never attached to the project. I mean the new guice library appears as attached (and contains both guice and aopalliance jars) but they are “not really” attached to the project. I use this feature only as an easy way to fetch some library, but then attach the downloaded jars with Attach Classes…
Certainly it will be a very handy way to attach jars to projects.
buildno = 96.802
Why doesn’t allow Idea IntelliJ About dialog to copy some stuff – like build no?
Baruch Sadogursky says:
August 15, 2010@Ted, I think Gregory just isn’t familiar with Artifactory. This is a shame, I’d expect Jetbrains Maven support developers to be more proficient with Maven market. Anyway, it’s just bad selection of names in UI and in this blog post. Hopefully it will be fixed soon.
Baruch Sadogursky says:
August 16, 2010Looks like IDEA uses REST API and not indexes, so probably it IS compatible only with Nexus. That’s bad. I opened an issue: http://youtrack.jetbrains.net/issue/IDEA-57652?projectKey=IDEA
Richard Osbaldeston says:
August 16, 2010Useful feature though I’m always a little weary of whats really in public repositories, can be fragile. Any chance of JetGroovy plugin being able to reuse this feature to support Groovy Grape declarations from the IDE?
Peter Gromov says:
August 24, 2010Richard, http://plugins.intellij.net/plugin/?id=4702. IDEA X will bundle this plugin. Though it’s not a re-use of the functionality mentioned in the post.
Suresh says:
June 16, 2011I will be helpful if we intellij can autocomplete exclusions
ex
com.xxx.publisher
subsystem-config
1.5.0-SNAPSHOT
org.springframework
spring-core
Suresh says:
June 16, 2011……..
org.springframework
spring-core
Suresh says:
June 16, 2011not able to post the whole thing..typing in words
after exclusions tag if someone does a ctrl space
IDEA should figure out all the jars that get pulled in as a transitive dependency and prompt the user with the exclusion that it can make
Gregory Shrago says:
June 17, 2011Please create a feature request in our tracker at http://youtrack.jetbrains.net/dashboard
dilbert says:
November 17, 2011I have tried and tried again but I couldn’t make it work. I created a new project with a new module with a GWT facet and i wanted to add the gwt-user dependancy to it via this feature. No matter what I wrote in the “coordinates” box (I tried gwt, gwt-user, com.google.gwt, com.google.gwt:gwt-user, com.google.gwt:gwt-user:2.4.0 and various others) it would never find the library. On the other hand, when I wrote hibernate (which I don’t need) it found 163 mqtches :(. Maybe I configured something wrong. Thanks for your help.
dilbert says:
November 18, 2011Also in 10.5.2 one can not choose the repository URL to download from like in the dialog above.
ganjo says:
April 14, 2016For downloading external libraries, go to this website: http://jar-download.com/
Erik says:
January 20, 2018I just tried org.jetbrains.exposed, and it didn’t find it. The only org.jetbrains it finds are for annotations.