12.1. Getting Started

In this chapter, we will see how to build and run graphical applications in Java and JavaFX on the Odin server. To do so, you first need to ensure that your terminal emulator supports X-forwarding. This allows the Graphical User Interface (GUI) parts of your application to be forwarded to (and viewed on) your local computer. Since the application is running on Odin, we need to make sure the GUI shows up on our machines instead of on Odin. To check your setup, work through the rest of this section of the tutorial.

  1. First, log in to Odin using the ssh command along with the -XYC option. As always, be sure to replace username with your Odin username.

    ssh -XYC username@odin.cs.uga.edu
    

    If you encounter problems in this step, then please ensure that you have followed the instructions provided at the beginning of the semester for MacOS users or Windows 10 users.

    Also, the -X, -Y, and -C options can be used individually with or without each other. See the manual page for ssh for more information about the differences between these options.

  2. Use the following command to download and execute a shell script that retrieves the starter code for this tutorial and place it into a subdirectory called cs1302-javafx:

    curl -s -L https://git.io/fhAR8 | bash
    
  3. Change into the cs1302-javafx directory that was just created and look around. There should be multiple Java files contained within the directory structure. To see a listing of all of the files under the src subdirectory, use the tree command as follows:

    tree src