We will use GitHub for all things related to code in class, including sharing lecture code examples, sharing starter homework and project code, submitting homeworks and projects, and collaborating on projects. It is a software development platform built on top of the git
software, which is version control system for software.
Use this guide to get started with GitHub for the first time and learn some of the basics of the git
software it is built upon.
If you do not yet have a free GitHub account, you need to create one:
When creating an account for this class (including accounts already created), keep in mind:
Choose a professional username.
Add information to your profile, including a professional profile photo and brief bio (including your degree and expected graduation date).
Add your @dons.usfca.edu
and @usfca.edu
emails to your account. Go to “Settings” » “Access” » “Emails” to add an email.
The @usfca.edu
version of your email is an alias that forwards to your @dons.usfca.edu
account. Some university services use this alias, including Canvas and Zoom. That is why you need to add both forms of your email address.
Apply for the GitHub Student Developer Pack after adding your university emails to your account.
You can see the instructor’s profile page for an example. When done with this class, you’ll be able to show off your GitHub profile to potential employers.
<aside> <img src="/icons/warning_gray.svg" alt="/icons/warning_gray.svg" width="40px" /> Using your GitHub username and password authentication no longer an option for authentication via the command-line.
</aside>
You will need to access your private GitHub repositories on your own local system to run and develop code. There are two options for accessing your private repositories:
Using SSH, which involves generating SSH keys per system you want to access GitHub from. If you already use SSH (for example, to access stargate.cs.usfca.edu
), then that approach may be more convenient since you likely already have SSH keys generated.
Using HTTPS, which involves generating a personal access token (instead of a password). If you do not already use SSH, I recommend the HTTPS method. It allows more fine-grained control, including when it should expire. With this option, make sure to configure an expiration after the end of the semester, and add both “repo” and “workflow” access:
Screenshot of GitHub interface for creating a personal access token and setting its permissions.
Either way works; they each have different pros and cons. When you know which method you prefer, go to the Authenticating with the command line article on GitHub for details about get started.
You should only need to complete this step once for the entire semester!