Project Overview
In this final project, you'll practice a complete Git collaboration workflow — from creating a repository to merging pull requests.
- Create a repository on GitHub
- Set up .gitignore and branch protection
- Create feature branches for different tasks
- Make commits with good messages
- Open and review pull requests
- Resolve merge conflicts
- Tag a release
Step-by-Step Workflow
Follow this workflow to practice everything you've learned.
Example
# 1. Create repo and initial commit
git init my-collab-project
cd my-collab-project
echo '# Collaboration Project' > README.md
git add .
git commit -m 'Initial commit'
# 2. Push to GitHub
gh repo create my-collab-project --public --push
# 3. Create feature branches
git switch -c feature/add-homepage
# ... create index.html ...
git add . && git commit -m 'Add homepage'
git push -u origin feature/add-homepage
# 4. Create PR and merge
gh pr create --title 'Add homepage'
gh pr merge
# 5. Tag a release
git switch main && git pull
git tag -a v1.0.0 -m 'First release'
git push origin v1.0.0 Challenge Tasks
Try these additional challenges to solidify your Git skills.
- Create two branches that edit the same file, then resolve the merge conflict
- Use git stash to save work in progress while switching branches
- Practice interactive rebase to clean up commit history
- Set up a GitHub Actions workflow that runs on pull requests
- Use git bisect to find which commit introduced a bug
