Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is nbactions.xml used for?

Tags:

java

xml

netbeans

After searching for a little while I figured it has to do with using maven and net beans for building an application, but I can't seem to find good documentation on that. Which goal could be achieved by using nbaction.xml? Which would be its equivalent for Eclipse, if there even is one?

like image 767
eduardohl Avatar asked Aug 28 '12 16:08

eduardohl


1 Answers

The nbactions.xml file is used by Netbeans to call custom Maven goals. It is even possible to change the behavior of the built in the "Build, Test and Run" commands in Netbeans using it.

The project Properties > Actions settings are stored in this file.

There are more details in the accepted answer to this Stack Overflow question relating to defining goals in netbeans: Invoking Actions other than Build and Clean & Build

I have not been using Eclipse lately, but I suspect you can easily replicate this functionality using custom run configurations. I believe that using the m2eclipse plugin offers this functionality by invoking Run as... / Maven build.

You may also find this other Stack Overflow answer helpful configuring m2eclipse: How do I start Maven "compile" goal on save in Eclipse?

like image 52
MikeG Avatar answered Nov 16 '22 22:11

MikeG