NetBeans Tips
will show you many useful informations that may help you to improve your NetBeans experience.
Note that all these tips work with NetBeans 6.9 and 6.8, and would probably work with many previous versions. Let's go :
NetBeans Tip #1
Q : NetBeans 6.9 Ant tasks are slower that NetBeans 6.8 ones, why ?
R : NetBeans 6.9 uses Ant 1.8 whereas NetBeans 6.8 (and previous like 6.7 or 6.5) uses Ant 1.7. You must know that many Ant 1.8 tasks, like complitation, JUnit tests, etc, are slower than Ant 1.7. It can take twice time !
A solution can be to ask NetBeans to use Ant 1.7 instead of 1.8. You only have to download and install (extract) Ant 1.7 and go into NetBeans : Tools / Options / Miscellaneous / tab "Ant" / update the "Ant Home" value, and validate.
With the latest Ant 1.7 build, you will see "Apache Ant version 1.7.1 compiled on June 27 2008".
Try a build or a JUnit test : it's faster :)
NetBeans Tip #2
Q : I install new plugins but they disappear after each NetBeans restart, why ?
R : You are probably working with Vista or Seven, right ? Update the NetBeans shortcut to launch it as an administrator.
Note that you will have the same problem while removing plugins : without the administrator rights, all theses modification cannot be done, so they will not be effective after each netBeans reboot.
An other solution can be to use the ZIP distribution of NetBeans and extract it in a non-protected folder (or install NetBeans in a non protected folder) : you won't need the administrator rights. It is not elegant, but it may work.
NetBeans Tip #3
Q : NetBeans editor shows uncomprehensive errors hints while the same code was good before, why ?
R : Sometime (probably an old bug) you have to empty the NetBeans cache.
- Stop NetBeans
- Go to this folder "<user-dir>\.netbeans\6.9\var\cache" (replace 6.9 by your NetBeans version) and delete all its content
- Start NetBeans
- Try a Clean and Build task
NetBeans Tip #4
Q : I'd like to install NetBeans in a virtualized Windows XP (with Oracle VirtualBox) but the process never ends and the CPU load stays at 100%
R : Launch the NetBeans installer in Windows 2000 compatibility mode. It will be slow to install, but it works;
NetBeans Tip #5
Q : I'd like to make a backup of my NetBeans installation. What are the files to save, how does it work ?
R : NetBeans is very easy to backup. You have to stop it and save these directories (we will assume that you want to backup NetBeans 6.9 on a Windows computer, NetBeans installed in the default path) :
- "<user-dir>\.netbeans\6.9"
- "<user-dir>\.nbi"
- "C:\Program Files\NetBeans 6.9"
Note about ".nbi" : if you installed many versions of NetBeans, go to the "product-cache" folder, and explore the "nb-base", "nb-javase" etc folders, you will see sub-directories for each versions of NetBeans, like "6.9.0.0.0" for NB 6.9. These directories are very small, so you can choose to backup the entire ".nbi" directory instead of backup the "6.9.0.0.0" directories only.
To restore a backup, you only have to stop NetBeans, replace the current NetBeans directories by the backup, and start NetBeans.
You can easily automatize it with a short BAT or SH script that compresses the three directories into zipped files :)
Latest comments