GitHub @ SUNY Geneseo

GitHub @ SUNY Geneseo

Geneseo has our own instance of GitHub Enterprise Cloud. This article explains requesting access to the service and how accounts work with our organization.

Git vs. GitHub

Although Git and GitHub both have "Git" in their name, they are not the same thing. 

Git is an open-source version control system that is installed locally on your computer. You create local repositories for files, usually source code files and their associated documentation, which are then linked to a remote repository, such as GitHub, and changes to the files are pushed to and pulled from this storage repository to ensure you always have the most up-to-date versions of the files while also being able to review what has changed in the files between fetch operations. You can read more about Git and download it from the official Git website.

GitHub is a website that houses remote Git repositories from all over the world. This allows visitors to view other people's repositories, if they are publicly available, and download the code or even copy it to a repository of their own through a process known as cloning. You can also create a "fork" of a repository which is a copy of the code that you can keep synced to the original and use to suggest changes to the original code by submitting a "pull request". GitHub also provides additional features for its repositories, such as running certain actions when code is pushed or pulled. Multiple collaborators can be added to a single GitHub repository to work on a project together. Multiple repositories can be grouped under an organization, like SUNY Geneseo, for people within that organization to collaborate across repositories.

Explaining all the features of Git and GitHub is beyond the scope of this document. If you are just getting started and would like to learn more, GitHub offers documentation on both Git and their platform:

In the top left of the page, click on Version to change which version of GitHub the documentation provides information for. Free, Pro, & Team is sufficient for learning about your personal account, however, operations relating specifically to working with our organization will fall under the Enterprise Cloud version.

Do you Need Access to SUNY Geneseo's GitHub?

GitHub is available for anyone on the internet to use. Here are some facts to consider before you request access to our organization:

  • If you are just looking to use GitHub for personal projects or to learn Git, you can create a free account at https://github.com at any time

  • A free account can create public and private repositories which are owned by that account

  • Access to these repositories and the code in them is not lost when you leave Geneseo

  • Access to the SUNYGeneseo organization is an extension of your account rather than the core feature of it

  • You only really need access to the SUNYGeneseo organization if you are collaborating on a project whose repository lives in or should live in the organization

Should your Repository Live in SUNYGeneseo?

Repositories that are created under your personal account belong to that account, and you will have access to them as long as you have access to the account. Repositories created under the SUNYGeneseo organization are owned by the organization, and you will lose all access to them when you leave Geneseo (unless they are public). With that in mind, here are the reasons your repository should live in the SUNYGeneseo organization:

  • The project the code belongs to a Geneseo department which will continue to support the project after you leave

  • The code is for operations in a campus department, and they will continue to use the code after you leave

  • The code is for a class/research that should be retained by Geneseo after you leave

  • The code is meant to be shared internally or the public with Geneseo as the owner rather than yourself

  • You are a member of CIT working on a project that collaborates with other departments or the project is not for internal CIT use

How GitHub Accounts Work with our Organization

It is important to understand a few facts about how GitHub accounts work with our organization for SUNY Geneseo:

  • Your GitHub account is not an account owned by SUNY Geneseo, instead it is a personal account you connect to our organization

  • The account is connected to your Single Sign-on identity, allowing you to access our organization

  • When you are invited to join the organization, you will receive the invitation in your Geneseo email, but your Geneseo email is not automatically added to any personal GitHub accounts you own, even when you sign in with an account to accept the invitation to the organization

  • When you leave Geneseo, your access to the SUNY Geneseo GitHub organization is removed, however, your GitHub account is not deleted

  • Repositories you create in the SUNY Geneseo organization belong to that organization, and when you leave Geneseo, you will lose access to any internal or private repositories you created or were a member of. You will still be able to view any public repositories in the organization. You will also not lose access to any personal repositories you create under your account rather than the organization

You can tell who owns a repository by going to the repository's page. In the top left there will be text in the format of Repository Owner / Repository Name. This is reflected in the URL for the repository as well (https://github.com/RepositoryOwner/RepositoryName). If the owner is SUNYGeneseo, then the repository is owned by the organization. If the owner is your GitHub username, then the repository is owned by you.

Steps to gain access to the SUNY Geneseo organization in GitHub

  1. Sign up for a free personal account at GitHub, if you do not already have one

  2. Add your Geneseo email as a verified email by following GitHub's documentation for adding another email to your account

  3. Gain access to the SUNY Geneseo organization by performing the following steps:

    1. Navigate to My Apps

    2. Click Add apps then Request new apps in the dropdown that appears

      The apps screen with the add apps button and request new apps button.
    3. On the Suggested apps page, click on GitHub - SUNYGeneseo

      The add apps page with the GitHub - SUNY Geneseo app.
    4. Click Add

    5. In the Add app confirmation window that appears, click Add

      The add app confirmation window
    6. Once the confirmation message appears, you have begun the process of gaining access, but you may need to wait up to 40 minutes for it to be granted by the system

      The successfully added app message on the app screen.
  4. Once access is granted, you will receive an email from GitHub informing you that you have been invited to join the @SUNYGeneseo organization by @gsusystems

    The email message that comes from GitHub in Gmail.
  5. Clicking on the Join @SUNYGeneseo button or the invite link at the bottom of the email will take you to a sign in page where you will enter the credentials for your personal GitHub account or the ability to create an account if you do not already have one

    1. If you receive an error message about your account lacking a verified email address, make sure you are signing into the account you want to use for Geneseo and that you have added and verified your Geneseo email address on the account using the instructions linked in step 2

  6. You will be presented with a prompt to authenticate by logging into SUNY Geneseo's single sign-on provider, click Continue

    The single-sign on prompt on GitHub.
    1. If you see a slightly different window with the option to create an account, do not create an account there if you did not create an account in step 1, as you will be required to use your Geneseo email which is not recommended

      The account creation window on the invitation screen.
  7. You will be redirected to the Microsoft sign in page

  8. Enter your Geneseo email, password, and complete the MFA prompt if required

  9. Your account is now associated to your Geneseo single sign-on identity, and you will be taken back to GitHub

  10. Your account now has access to the SUNY Geneseo organization

    1. At this point, you may create your own repository within the organization

    2. Any private repositories you are supposed to have access to may take up to 40 minutes for the access to be granted as that is the sync interval between GitHub and our single sign-on provider

GitHub PATs and SSH Keys

GitHub allows for the use of Personal Access Tokens (PATs) and Secure Shell Protocol (SSH) keys to access and write data to repositories. PATs can be used with the GitHub CLI as well as to access the GitHub API. Both PATs and SSH keys can be used to pull code from a GitHub repository to a local repository on your computer as well as push code from a local repository to a GitHub repository by using Git. The below examples show the different addresses used for communicating to a repository via PAT versus via SSH:

PAT example

# This is an example of the URL for a GitHub repository that you would be connecting to using a Personal Access Token git remote set-url origin https://github.com/<repository-owner>/<repository-name>.git

SSH example