Refer to TaT_HackingNetBeansXMLLayerPartOne for more details on where to use the following tricks.
<file name="org-nvarun-tat-separatorAfter.instance">
<attr name="instanceClass" stringvalue="javax.swing.JSeparator"/>
<attr name="position" intvalue="175"/>
</file>
<file name="org-nvarun-tat-separatorBefore.instance">
<attr name="instanceClass" stringvalue="javax.swing.JSeparator"/>
<attr name="position" intvalue="125"/>
</file>
<folder name="Toolbars">
<folder name="Build">
<file name="org-nvarun-tat-SayCheez.shadow">
<attr name="originalFile"
stringvalue="Actions/Tools/org-nvarun-tat-SayCheez.instance"/>
<attr name="position" intvalue="325"/>
</file>
</folder>
</folder>
<folder name="Menu">
<folder name="Tools">
<file name="org-nvarun-tat-SayCheez.shadow">
<attr name="originalFile"
stringvalue="Actions/Tools/org-nvarun-tat-SayCheez.instance"/>
<attr name="position" intvalue="150"/>
</file>
<file name="org-nvarun-tat-separatorAfter.instance">
<attr name="instanceClass" stringvalue="javax.swing.JSeparator"/>
<attr name="position" intvalue="175"/>
</file>
<file name="org-nvarun-tat-separatorBefore.instance">
<attr name="instanceClass" stringvalue="javax.swing.JSeparator"/>
<attr name="position" intvalue="125"/>
</file>
</folder>
</folder>
Note that these tricks apply to the module which declares the action. You cannot remove an action declared in another module, but you can hide it: DevFaqSwitchingMenusByContext
(Reposted from this entry on NetBeans Zone.)