Wednesday, October 22, 2008

NetBeans Syntax Highlighting Settings Migration

Hi there,

Unfortunately till now, NetBeans doesn't provide a way to manual store and retrieve the syntax highlighting settings for the editor. This is painful if you decide to migrate the settings between two or more development machines cause you need to manual adjust the settings for each one. Further it causes problems if you would like to share the settings with a friend or back it up.

Fortunately enough though there is a solution, a manual one!. NetBeans stores all of its configuration data in the user's home directory(e.g /home//.netbeans). Inside that directory you will find a folder for each NetBeans release you might have installed. For example:

/home/username/.netbeans/6.1 (For the NetBeans 6.1 release)
/home/username/.netbeans/6.5rc1 (For the NetBeans 6.5 release candindate release)

That is under Linux though, please fellow window users help here (I think it may be somewhere around C:\Documents And Settings\\...)

If you have adjusted your syntax highlighting settings, then in the NetBeans directory you will find a folder named "Editors"

/home/username/.netbeans/6.1/config/Editors/ (For the 6.1 release)

If you now copy the "Editors" folder and paste into another NetBeans instance(in /home/username/.netbeans/6.5rc1/config/) for the NetBeans 6.5 rc1 release ,all of your syntax highlighting settings would migrate. Easy ee! :)

Note:

This tip is completely unofficial, I described a method that worked for me but I cannot make any guarantees that it will work for you. Try it with caution...

That's all for now, I would love to hear your comments.

No comments: