First steps in Version Control with GitHub

Author
Affiliation

Alexia Cardona

University of Cambridge

Course overview

Description
Version control helps you to write code for your research more sustainably and collaboratively, in line with best practices for open research. You might use code for collecting, analysing or visualising your data, or something else. Everyone who codes in some way can benefit from learning about version control for their daily workflow.
This workshop will cover the importance of version control when developing code and foster a culture of best practices in FAIR (Findable, Accessible, Interoperable, Reproducible) code development. We will take you through the basic use of GitHub to help you store, manage, and track changes to your code and develop code collaboratively with others.

Prerequisites
While prior knowledge of a programming language (e.g., R or Python) would be beneficial, it is not a prerequisite.

Learning Outcomes
  1. explain what version control systems and identify their advantages and importance in open research
  2. create repositories on GitHub
  3. commit changes to files in repositories on GitHub
  4. open issues on GitHub
  5. create branches on GitHub
  6. open pull requests and merge changes into the main branch
  7. describe the GitHub flow and be able to execute it

Target Audience
Designed with beginners in mind, this workshop caters to those who have not yet delved into Git or GitHub.

Level: Beginner

Exercises levels

Exercises in this course are labelled with the level of difficulty of the respective exercise. These levels are designed to provide a gradual progression in difficulty, allowing learners to build on their skills and understanding as they move from one level to the next.

Level Description
Level 1: Exercises in Level 1 are simple exercises designed to get you familiar with a concept or syntax.
Level 2: Exercises in Level 2 build upon the concepts introduced.
Level 3: Exercises in Level 3 are more complex and build upon concepts introduced.

Citing this course

Please cite as: Alexia Cardona. (2024, February 25). First steps in version control with GitHub. Zenodo. https://doi.org/10.5281/zenodo.10703130

Acknowledgements

  • Thanks to Mary Chester-Kadwell for guidance.
  • This course was created as part of the CDH RSE Fellowship.
  • Some of the content of this course was adapted from the Reproducible Research in R course (Cardona, Alexia 2019)