Using Git - POINT-VR/POINT-VR-Chapter-1 GitHub Wiki

What is Git?

  • Git is a version control manager. Git allows you to have multiple development versions at a time. It is also meant to be utilized to help manage parallel software developments.
  • The most common way of interfacing with Git is via a command line interface, however for this project we will discuss different interface methods.
  • Git utilizes different types of repositories (repos): local vs remote
  • This is a basic structure of git commands and workflow used.

GitHub and Git

  • GitHub is a cloud-based service for storing projects that utilizes Git.

Making a GitHub Account

GitHub Desktop

While the most common way to interface with Git is via terminal i.e. some command line interface, GitHub offers an alternative for most simple use cases. GitHub Desktop is a visual GUI that allows you to pull, push, commit, and switch branches with a click. However for more complicated commands, it might be required to still have to use a command line interface (so it wouldn't hurt to learn to how to interface with Git via command line).

Connecting GitHub Desktop to our repository

1.) First you want to clone the repository to your GitHub Desktop. You should be already logged into GitHub account in GitHub Desktop.

2.) If you are logged in and a member of our organization you will see a section for POINT-VR. If you do not see that section, you might not be a member of our organization, in which case you should contact Sonali preferably via Discord. You can then select where in your local path you want the cloned repository to exist.

3.) On the side bar of GitHub Desktop, this repository should now be available.

4.) Once you are in the repository you can select which branch to check out.

Our Workflow

Make sure to contact Sonali on our discord with your GitHub username to be added to the POINT GitHub team.

  • Branches
    • develop : Our main development work
    • feature-branch : Work on specific features that will be merged into develop at some point
  • Pull Requests : A request to me that a feature-branch is ready to merged into develop and so should be reviewed for any potential file conflicts
  • Merging : Merging the file changes from one branch to another branch.
  • Pulling and Pushing: Interaction with the remote server version. Always fetch origin and pull before starting work, this ensures you are working on the most up to date version of files (you are unlikely to be working on the same branch with other people, but it is a good habit to have). push refers to pushing your latest changes to the GitHub for the team to see.
  • Authoring commits: Commits should be a good, but concise description of the changes you made and why they were implemented. This allows long term tracking of who has made changes to the project.
  • (Advanced) Stashing: Stashing allows you to store changes on your local system until later. They are not permanently saved and you can only keep one stash at a time. Particularly useful when you need to switch branches but you want to keep your changes that are not in a commit.