Git and GitHub for Teams
Save your work with Git, undo mistakes safely, and work with a team on GitHub: branches, merges, pull requests, code review, releases and CI.
- 0 students
- 92 lessons
- 6 h 48 min
Created by Ayim Nelson
What you will learn
- Explain what version control is and how Git and GitHub differ
- Set up Git, create a repository and make clear, small commits
- Read the history and changes with git status, log, diff and show
- Keep secrets and clutter out of a repository with .gitignore
- Undo mistakes with restore, amend, reset --soft and revert, and know which is safe when
- Create branches, merge them and resolve merge conflicts
- Clone, push, pull and fetch, and work through pull requests and code review
- Rebase safely, tag releases and read a simple GitHub Actions workflow
About this course
Git keeps the history of your code, and GitHub is where teams share it. In this course you follow Ama, Kofi and Esi, three classmates in Kumasi, as they build their school's results website: from the first commit, through branches, merge conflicts and a rejected push, to pull requests, code review, a protected main branch, a tagged release and an automatic test run. Every Git command was really run, and you see its real output. Each section ends with a short Python exercise that practises the idea.
For: beginners who write some code (in any language) and want to keep it safe and work with others. You only need to know how to use a computer; the exercises use simple Python.
By the end: you'll use Git every day with confidence: commit with good messages, read diffs and logs, ignore the right files, undo mistakes the safe way, branch and merge, resolve conflicts, and take part in a team's GitHub workflow with pull requests, reviews, issues, forks, tags and CI.
Course content
11 sections · 92 lessons
Why version control6 lessons
- What version control isPreviewReading · 3 min
- Git and GitHub are not the samePreviewReading · 3 min
- Meet the team and the projectPreviewReading · 3 min
- Snapshots and historyReading · 3 min
- The terminal you'll type inReading · 4 min
- A history of snapshotsExercise · 10 min
Installing and setting up Git5 lessons
- Installing GitReading · 4 min
- Telling Git who you areReading · 3 min
- A few useful settingsReading · 4 min
- Checking your settingsReading · 3 min
- Is this computer ready to commit?Exercise · 10 min
Repositories and commits8 lessons
- Creating a repositoryReading · 4 min
- Three places your work livesReading · 4 min
- Checking with git statusReading · 3 min
- Staging files with git addReading · 3 min
- Making a commitReading · 3 min
- Writing good commit messagesReading · 4 min
- Small commits that do one thingReading · 3 min
- A commit message checkerExercise · 12 min
History and changes7 lessons
- Reading the history with git logReading · 3 min
- One line per commitReading · 3 min
- Seeing changes with git diffReading · 4 min
- Staged changes: git diff --stagedReading · 3 min
- Looking at one commit with git showReading · 3 min
- Filtering the logReading · 3 min
- Reading a one-line logExercise · 12 min
Ignoring files6 lessons
- Files that don't belong in GitReading · 4 min
- Writing a .gitignore fileReading · 4 min
- Pattern rulesReading · 4 min
- Why is this file ignored?Reading · 3 min
- Stopping Git from tracking a fileReading · 4 min
- A tiny .gitignore matcherExercise · 12 min
Undoing things8 lessons
- Throwing away changes with git restoreReading · 3 min
- Unstaging with git restore --stagedReading · 3 min
- Fixing the last commit with --amendReading · 3 min
- Undoing commits with git reset --softReading · 4 min
- Undoing a shared commit with git revertReading · 4 min
- Finding lost work with git reflogReading · 3 min
- Which undo to useReading · 3 min
- Pick the right undoExercise · 10 min
Branches9 lessons
- What a branch isReading · 3 min
- Creating a branchReading · 3 min
- Switching branchesReading · 3 min
- Switching changes your filesReading · 3 min
- HEAD: where you areReading · 3 min
- Creating and switching in one stepReading · 3 min
- Branches as a graphReading · 3 min
- Deleting a branchReading · 3 min
- Branches are just labelsExercise · 12 min
Merging and conflicts8 lessons
- Merging a branchReading · 3 min
- Merge commitsReading · 4 min
- When two changes collideReading · 3 min
- Reading conflict markersReading · 4 min
- Backing out with git merge --abortReading · 3 min
- Resolving a conflictReading · 4 min
- Tidying up after mergingReading · 3 min
- Resolving a conflict in PythonExercise · 12 min
Remotes and GitHub12 lessons
- Remotes and GitHubReading · 4 min
- Connecting with git remote addReading · 3 min
- Pushing with git pushReading · 3 min
- A README for visitorsReading · 3 min
- Cloning a repositoryReading · 3 min
- Sharing your first commitReading · 3 min
- Fetching: seeing what changedReading · 3 min
- Pulling changes inReading · 3 min
- When your push is rejectedReading · 4 min
- Pulling when both sides changedReading · 4 min
- Signing in to GitHubReading · 3 min
- Ahead or behind?Exercise · 12 min
Working as a team on GitHub11 lessons
- The feature branch workflowReading · 4 min
- Pushing a feature branchReading · 3 min
- Opening a pull requestReading · 4 min
- Code review etiquetteReading · 4 min
- Updating a pull requestReading · 3 min
- Merging a pull requestReading · 4 min
- Protecting mainReading · 4 min
- Tracking work with issuesReading · 4 min
- Forks for open sourceReading · 4 min
- Keeping a fork up to dateReading · 4 min
- Which issues will close?Exercise · 12 min
Rebase, releases and CI12 lessons
- What rebase doesReading · 4 min
- Rebasing your branch onto mainReading · 4 min
- Force-pushing your own branchReading · 4 min
- Never rewrite shared historyReading · 3 min
- Tagging a versionReading · 3 min
- Pushing tags and releasesReading · 3 min
- Publishing with GitHub PagesReading · 3 min
- Semantic versioningReading · 3 min
- What continuous integration isReading · 4 min
- A first GitHub Actions workflowReading · 4 min
- What's the next version?Exercise · 12 min
- Final quizQuiz · 10 min
Reviews
No reviews yet.
Comments
Log in to join the conversation.
Loading comments...