13.07.2015 Views

Java™ Application Development on Linux - Dator

Java™ Application Development on Linux - Dator

Java™ Application Development on Linux - Dator

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

238Chapter 10Integrated <str<strong>on</strong>g>Development</str<strong>on</strong>g> Envir<strong>on</strong>mentsUncompress the archive:bunzip2 NetBeansIDE-release35.tar.bz2This will leave the file NetBeansIDE-release35.tar in place of the.bz2 file.You can examine the c<strong>on</strong>tents of the TAR file with:tar -tvf NetBeansIDE-release35.tar | moreHere the opti<strong>on</strong>s (-tvf) specify to show a table of c<strong>on</strong>tents (-t) in verbose,that is, l<strong>on</strong>g, form (-v) from the specified file (-f) followed by the TARfilename. The output from tar here is piped into more so that you can pagethrough it. Type q when you’ve seen enough, or leave off the | more to let itrun through without pausing.Notice that the names of all the files in the TAR archive begin withnetbeans/ which tells us that if we untar the file, it will put all the files into adirectory called netbeans. Therefore, we d<strong>on</strong>’t need to make such a folderbeforehand.Change directory to the directory where you would like to installNetBeans. If you are <strong>on</strong> a system that may be used by different users, you’llprobably want to put it in a more public locati<strong>on</strong> like /usr/local or /opt. Ifit is for your pers<strong>on</strong>al use, you can put it anywhere—just be sure that you havewrite permissi<strong>on</strong>s <strong>on</strong> the directory where you want to install NetBeans.(Reminder: use ls -ld . to see the permissi<strong>on</strong>s of the current directory.)The tar command to untar everything in place is simple:tar -xf NetBeansIDE-release35.tarThis will extract (-x) all the files that are in the TAR file (-f) namedNetBeansIDE-release35.tar. If you’d like to see each file get named as itis extracted, then change the -xf to -xvf (v for verbose) and you will see awhole l<strong>on</strong>g list of filenames displayed <strong>on</strong> your screen as the file is unpacked.Next, we need to adjust the startup parameter in the c<strong>on</strong>figurati<strong>on</strong> file.The file is in the netbeans directory that you just untarred. In there is a directorynamed bin, and in there is a file called ide.cfg. Open this file with aneditor and change the line that begins -jdkhome so that the pathname refersto the locati<strong>on</strong> of your Java <str<strong>on</strong>g>Development</str<strong>on</strong>g> Kit (JDK, see Chapter 5).Here’s an example of the c<strong>on</strong>tents of ide.cfg:

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!