Git & Github
Pull Requests
Even if you're the only person working on a project: It helps keep your main branch clean an...
Git Cheat Sheet
🔧 Setup Set your name and email git config --global user.name "Your Name" git config --globa...
Rebase
What is git rebase (in plain English)? Rebase takes the commits on your current branch and repla...
Merge case (you’re merging main into your branch, and want your branch everywhere)
git checkout --ours $(git diff --name-only --diff-filter=U) && git add -A && git commit -m "Resol...
Handling Pull Requests from Forks (Maintainer Guide)
# Handling Pull Requests from Forks (Maintainer Guide) This guide explains how to safely wor...
Login to Github in terminal
# 1. Install GH CLI sudo apt install -y gh # 2. Login via terminal gh auth login
Merge our branch quickly ignoring conflicts with main
git merge -X ours main \ -m "Merge main (prefer branch changes on conflicts)" \ && git push...