Version Control with Git

This lesson is a modification of the Version Control with Git lesson developed by Software Carpentry. The official version is longer, covers more concepts, and in more detail, so take a look if you are interested in learning more.

This lesson is being taught as part of the GRAD521 Research Data Management class at Oregon State University, and has been developed by Clara Llebot.

This lesson is licensed as CC BY 4.0

This lesson introduces students to version control to manage their work. Version control is better than mailing files back and forth:

Teams are not the only ones to benefit from version control: lone researchers can benefit immensely. Keeping a record of what was changed, when, and why is extremely useful for all researchers if they ever need to come back to the project later on (e.g., a year later, when memory has faded).

Version control is the lab notebook of the digital world: it’s what professionals use to keep track of what they’ve done and to collaborate with other people. Every large software development project relies on it, and most programmers use it for their small jobs as well. And it isn’t just for software: books, papers, small data sets, and anything that changes over time or needs to be shared can and should be stored in a version control system.

Prerequisites

In this lesson we use Git from the Unix Shell. Some previous experience with the shell is expected, but isn’t mandatory.

Schedule

00:00 Automated Version Control What is version control and why should I use it?
00:05 Create a Repository What is a repository?
How do we create a repository?
00:15 GitHub Pages How to turn a repository into a website?
00:25 Setting Up Git How do I get set up to use Git?
00:30 Creating a Local Repository How do I store a repository locally?
00:40 Tracking Changes How do I record changes in Git?
How do I check the status of my version control repository?
How do I record notes about what changes I made and why?
01:00 Sync local rep and GitHub How do I work with a local and a remote repository?
01:30 Resources to learn more How can I continue learning Git?
01:35 Importing a Repository What is a repository?
How do we create a repository?
01:45 Finish

The actual schedule may vary slightly depending on the topics and exercises chosen by the instructor.