Star

Created With

linkRebasing with Git

As an alternative to merging, git offers another way to (for lack of a better word 😆) merge your branches

Except this is like a special kind of merge. Unlike the previous slide. Where we end up with a merge commit

With rebasing, we finish off with a single trunk. This type of workflow is often called "Trunk based development"

linkWhat merging looks like

merge

linkWhat rebasing looks like

Rebase

linkLet's see it in action!

Screen-Shot-2021-03-13-at-11-33-18-am.png

linkBut why might we want to use rebase instead of merging?

linkSounds good! Then why might we want to use merging?

linkOkay but I really want to use rebase..

Do it interactively then! This can save you a lot of hassle down the track

1link$git rebase -i master

Rebasing with GitWhat merging looks likeWhat rebasing looks likeLet's see it in action!But why might we want to use rebase instead of merging?Sounds good! Then why might we want to use merging?Okay but I really want to use rebase..
Content

Home Backstory Why Git? Setting Up GitHub GitHub CLI Your GitHub Profile GitHub Pages Creating A New Repo Cloning A Repository Your First Commit Ignoring Files In Git Stashing Your Changes Branching With Git Merging Git Branches Rebasing Vs Merging Git Workflows Fork And Pull Flow Your First Pull Request Automated Security Alerts Seeing The Differences Removing/Deleting Files Reverting Your Commits Configuring your Git Commit Templates Creating Shortcuts Dotfile Management Sponsoring Open Source Handy Commands Thank You



Developer Student Clubs

logo2.png