As the question says, how to package a Netbeans Maven project exactly the way a Netbeans native project is packaged:
- All the dependencies in a separate lib folder
- The main project jar with a manifest that includes the lib folder on it's classpath
As the question says, how to package a Netbeans Maven project exactly the way a Netbeans native project is packaged:
In your pom.xml file ...
1) Add this code to your project->properties node. This will define your main class in a central place for use in many plugins.
2) Add this code to your project->build->plugins node. It will collect all your jar dependencies into a lib folder AND compile your main class jar with the proper classpath reference: