NetBeans platform development with JRebel even more simplified
Many things in the JRebel universe have changed in the last months. Several new versions of JRebel were released, Zeroturnaround acquired Javeleon  and the JRebel-Plugin for NetBeans IDE got better and better.
Especially the support for developing NetBeans platform/RCP applications has been improved. In my posts , ,  I showed you how to configure JRebel to reload your changes within NB platform/NB IDE modules. These are mostly obsolete. The whole process has been simplified, the number of manual steps have been reduced. For example: you don’t need to modify any property-file anymore to tell NetBeans to load the JRebel as javaagent.
Please note that the following description only applies to ant-based module development. The maven-based module development still requires some additions to the pom.xml to get JRebel running.
So if you want to use JRebel to “instantly reload” your compiled changes to a fixed- (or locally compiled bleeding-edge-dev-) version of NetBeans IDE (or your own target platform) you have to follow these simple steps:
- install the JRebel-NetBeans-Plugin from the plugin portal and register your license, if not already done
- open your module (or open a module from the checkout sources of NB IDE)
- generate a
rebel.xmlin the source folder of the module – let the JRebel-plugin do this for you (right click on the project node, then “
- make sure that the JRebel icon in the toolbar is checked (this is important, because this tells the plugin to add the
-javaagentargument to command line of the next run/debug)
- run the module (you will see the JRebel headers in the output window, which means JRebel is loaded, and the target platform with your module activated will be opened)
- make your changes to the code, compile via
F9(this includes saving – that’s the trick)
- go back to the previously started instance of the target platform, repeat your actions and the changes in code are reloaded instantly (Please note that reloads of changes to layer.xml or additions to bundle.properties aren’t supported. In this case you still have to “
build” and “
run” the module again.)
This makes it much easier (at least for me) and I hope this simplicity will also attract other developers to write plugins or even to contribute to NB IDE development.
Tested with NB7.3/7.4dev, JRebel-NB-Plugin 1.5.1 and JRebel 5.2.2.
Update 2013/10/13: To use JRebel with locally compiled bleeding-edge-dev version of NetBeans IDE you still have to set the
tryme.arg.hack property in
nbbuild/build.properties as described in 
tryme.arg.hack=-J-Dnetbeans.full.hack=true -J-noverify -J-javaagent:c:/Users/markiewb/AppData/Roaming/NetBeans/7.4/jrebel/jrebel.jar -J-Xbootclasspath/p:C:/Users/markiewb/AppData/Local/Temp//rebelboot.jar -J-Drebel.log=true
Tested with JRebel 6.0-M3 and NB7.4