First Time: Tools Setup

Getting set up for this course requires the following steps, if you haven’t done them for a previous course, club, or project:

  1. Install git on your machine if necessary.
  2. Install Julia using the juliaup tool.
  3. Install and set up VS Code if you don’t already have an editor you’d like to use. VS Code is an editor of choice for Julia, as it as a rich and well-supported Julia extension. If you have a different coding environment, please find instructions for how to set it up to edit Julia.
  4. Set up a GitHub account.

Instructions

Install Git

If you have already installed git, you don’t need to worry about this section. If you haven’t, download the appropriate version for your operating system.

Mac Versions

If you have a Mac, be aware if you have an Apple Silicon (M1 or M2) Mac or an Intel Mac. Many of the installations you will go through in this exercise have different versions for each processor type, and the program may not work properly if you still the wrong version. There’s nothing that can’t be undone, but it’s easier to be install the correct version first!

Install Julia

I recommend installing Julia using the juliaup tool, which will let you easily manage versions in the future and works seamlessly with VS Code. The instructions can be found at the JuliaUp GitHub repository, but we will summarize them here.

Installing Juliaup on Windows

If your computer uses Windows, you can install Juliaup from the Windows Store.

Installing Juliaup on MacOS

If you have a Mac, open a terminal (such as the Terminal app) and enter:

curl -fsSL https://install.julialang.org | sh

Installing Julia 1.10.2

Once you install Juliaup, install Julia version 1.10.2 by opening a terminal (in MacOS or Linux) or the command line (in Windows) and entering:

juliaup add 1.10.2
juliaup default 1.10.2

This will install Julia 1.10.2 and make it the default version, which should maximize package compatibility throughout this course. Going forward, if you want to add new versions or change the default, you can follow the Juliaup instructions.

Install and Set Up VS Code

You can skip this section if you already have a coding environment you like; just set it up to work with Julia. Otherwise, VS Code is as close to an officially supported editor for Julia as you can get. We will follow this guide for setting up VS Code with Julia.

Installing VS Code

You can download it here; open the downloaded file to install.

Install the Julia Extension

  1. Open VS Code.

  2. Select View and click Extensions to open the Extension View. This view can also be found on the sidebar with the following logo:

    VS Code Extensions View Logo.

  3. Search for julia in the search box. Click the green install button.

  4. Restart VS Code once the installation is complete. It should automatically find your Julia installation; talk to Vivek if not.

The Julia VS Code extension offers you some nice features. You can start a REPL (an interactive Julia coding environment) by opening the “Command Palette” (View -> Command Palette, or CTRL/CMD+SHIFT+P) and typing “REPL” to bring up “Julia: Start REPL”. You can also create *.jl files to write Julia code and execute line by line. However, we will primarily use Jupyter notebooks in this class, but this might be useful for testing code or for your project.

Install the Jupyter Notebook Extension

The Jupyter Notebook extension allows you to export a Jupyter notebook to PDF or to HTML and then to PDF.

PDF Export for Gradescope

You will need to export every notebook to a PDF for submission to Gradescope. Direct export to PDF requires a LaTeX installation. If you would like to go this route, please look at the LaTeX installation instructions for your operating system.

Otherwise, exporting to HTML and then using your browser to save the resulting page to a PDF is a perfect solution.

Follow the same instructions as above, but search for jupyter and install the Jupyter extension. Restart VS Code.

Set Up GitHub

Create GitHub Account

If you already have a GitHub account, you can use that for this course and do not need to create a new account.

Otherwise, create an account. It doesn’t have to be linked to your Cornell email or use your Cornell NetID.

For labs and homework assignments (we will work on Lab 1 in class and Homework 1 is available), you should use the GitHub Classroom link to “accept” the assignment provided on Ed Discussion, which will give you your own GitHub repository for that assignment. The first time you click one of these links, you will need to link your place on the course roster with your GitHub account.

When application exercises require notebook use (which is the case here, but will not always be), you can follow the workflow in these next steps, and will be prompted to do so in the instructions for that exercise.

You can do almost everything that you will need to do for this course with GitHub directly through VS Code, or you can use the GitHub UI or the Terminal. We will assume in these instructions that you will just work through VS Code.