Now that you have upgraded from Windows to Ubuntu (like me :-) ), let’s see how to setup NetBeans quickly on your new Ubuntu machine without wasting much time.
Step 1: Install JDK
Install jdk on your machine using the super easy install option in Ubuntu. Open the terminal and type:
sudo apt-get install sun-java6-jdk
This will install the latest jdk available in the Ubuntu repository. This is cool because, you need not worry about updating your jdk whenever a new release is available. Your system’s “Update Manager” will take care of the rest.
Once the jdk is downloaded, you will be prompted to agree a license agreement in the terminal. Press “TAB” key to select the “Ok” option and then press “Enter”.
Next you will be shown another prompt, use your “arrow” keys to select “Yes” option and press “Enter” to start the install process.
Step 2: Install NetBeans
Verify whether jdk is installed on your machine by typing “java -version” in the terminal. If everything is ok, go and get yourself a copy of netbeans installer.
Once the netbeans installer is downloaded, right click the downloaded file (which should have “.sh” extension), click “Properties”, go to the “Permissions” tab and check the “Allow executing file as program” checkbox.
Now double click the file and click “Run” to start the installation process.
Step 3: Start NetBeans with Nimbus Look and Feel
Let’s face it. The default look and feel (GTK) of NetBeans on Ubuntu (and that of Ubuntu too) sucks. You probably don’t want your friends to ridicule your IDE and say “Is this NetBeans 1.0?”. You don’t want that, right?
But fortunately, there is a saviour in the form of “Nimbus” which is available from JDK 6 Update 10 onwards. And instructing NetBeans to start with “Nimbus” look and feel is very easy. Just right click your “NetBeans” icon on your desktop and click “Properties”. In the “Command” text field add the word ” –laf Nimbus”.
In my case, it looks like:
/bin/sh “/home/james/netbeans-6.5/bin/netbeans” –laf Nimbus
Now restart NetBeans to see your IDE skinned in Nimbus.
If you want NetBeans to look like other apps on your system, skin your Ubuntu with Nimbus theme too.
Step 4: Configure your video driver to ensure that NetBeans displays large files properly
In a perfect world, you don’t need this step but unfortunately you might need to configure your video driver properly to ensure that NetBeans displays large files properly. Otherwise, your IDE editor might display large files like this when you scroll your mouse:
Relax, this is not a bug in NetBeans but rather it’s just a little misconfiguration by Ubuntu. Fortunately, there is a solution to this issue and follow this netbeans wiki page to solve this.
Step 5: Choose the right font for your editor
Some of you might not like the default font used by the NetBeans editor on Ubuntu. For example, I like the crispy “Bitstream Vera Sans Mono” font with font size “13”. But if you are satisfied with the default editor font, it’s fine.
Step 6: Install path-tools plugin to integrate NetBeans with your filesystem browser
I strongly recommend you to use the excellent “path-tools” plugin which help you to integrate your NetBeans IDE with the nautilus file manager in Ubuntu. With this plugin, you can easily navigate to your netbeans projects located in your filesystem. Go grab it from the plugin portal.
And don’t forget to install your favourite version control system like subversion, mercurial, git etc to enjoy the benefits offered by your IDE.
That’s it for now. It will be great to see your suggestions, comments and tips you employ on your Ubuntu machine. Enjoy..!