Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

NetBeans: How to add library from Maven repo for non-maven project

For a plain "Java application" project, how can I add a dependency or library from Maven? If I right click on "Libraries" in the projects pane, it only allows me to add local libraries. But if my project is a Maven Java Application, then there's the "Dependencies" node in the projects pane, and from there I can right click and choose "Add dependency...".

I'm using NetBeans 8.0.

like image 225
KFL Avatar asked Apr 25 '14 22:04

KFL


1 Answers

You can either download the library manually e.g. from http://search.maven.org (don't forget the transitive dependencies as well!). Or if you're using Ant (the default project type in NetBeans): consider to use Ant Ivy to manage your dependencies.

like image 109
Puce Avatar answered Oct 16 '22 08:10

Puce