This course introduces intermediate concepts and functionality of the version control system Git and the code repository GitHub. The course is focused on ensuring an effective and healthy collaborative process. When collaborating with others, measures and tooling need to be in place to manage the process in an effective way, keeping track of the sequence of changes, reviewing, and approving what those changes are and undoing them, if needed.
Both Git and GitHub provide powerful features that facilitate this process such as: branching, pull requests, forks, rewriting history with rebase, merge, reset, and releasing new versions of the software with tags to identify milestones in the development process.
Moreover, some tasks ensuring that all contributions follow agreed standards can be automated via a continuous integration system. This course will introduce the basics of GitHub Actions, how to create workflows and run them automatically, when new changes are identified.
Syllabus
- Intermediate Git concepts, commands, and terminology, such as branches, rebase, merge and stash, among others.
- Using GitHub’s Pull Requests to manage contributions from collaborators
- Using GitHub’s Forks to contribute to other people’s code
- Using continuous integration to make sure every collaborator’s contribution meets an agreed standard
- Creating releases and adding tags to communicate effectively to users/collaborators what has changed between versions of the code.
Learning outcomes
After completing this workshop, you will be better able to
- Use advance Git commands to manage the parallel development of multiple features
- Collaborate effectively with others on a code base to achieve larger goals
- Apply continuous integration to automate tasks
- Understand how to access support for research computing via the Research Computing Service at Imperial College
Delivery of the course
Material will be delivered as a lecture with task following the Carpentries teaching style.
- The instructor will walk you through the theoretical material of the course, demonstrating the execution of the relevant code and instructions. You are highly encouraged to code along and execute the instructions at the same time.
- Throughout the lessons, there are yellow boxes highlighting particularly challenging or important concepts.
- There are also exercises in orange boxes. The instructor will give you time to try to do them yourself before going through the solution. This is often available in a folded part of the orange box, so you can check it at any time.
- When doing exercises, put a green sticker in your computer whenever you are done, or a pink/orange one if you need support. A helper will go to you.
- For online sessions, raise your hand if you are done with the exercise and write any questions or problems directly into the chat, so a helper can try to solve it.
Prerequisites
Basic familiarity with Git and GitHub (see our basic course)