Upgrade to PRO for Only $50/Year—Limited-Time Offer! 🔥
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Git Rebase
Search
Arturas Smorgun
August 29, 2013
Programming
2
230
Git Rebase
Introduction to Git Rebase by me at Inviqa Enlighening Lunch
Arturas Smorgun
August 29, 2013
Tweet
Share
More Decks by Arturas Smorgun
See All by Arturas Smorgun
Solve Complex Problems with DDD
asarturas
0
130
Review of Graph Databases
asarturas
0
80
Profiling in PHP
asarturas
5
920
Design Patterns in PHP Applications
asarturas
5
210
Application Quality
asarturas
6
320
Vagrant 1.2.2 and AWS
asarturas
0
62
Let's automate!
asarturas
0
270
AngularJS
asarturas
13
1.3k
Other Decks in Programming
See All in Programming
0→1 フロントエンド開発 Tips🚀 #レバテックMeetup
bengo4com
0
400
TestingOsaka6_Ozono
o3
0
180
GoLab2025 Recap
kuro_kurorrr
0
780
Flutter On-device AI로 완성하는 오프라인 앱, 박제창 @DevFest INCHEON 2025
itsmedreamwalker
1
150
從冷知識到漏洞,你不懂的 Web,駭客懂 - Huli @ WebConf Taiwan 2025
aszx87410
2
3.1k
フルサイクルエンジニアリングをAI Agentで全自動化したい 〜構想と現在地〜
kamina_zzz
0
300
tsgolintはいかにしてtypescript-goの非公開APIを呼び出しているのか
syumai
7
2.4k
re:Invent 2025 トレンドからみる製品開発への AI Agent 活用
yoskoh
0
430
AtCoder Conference 2025「LLM時代のAHC」
imjk
2
590
公共交通オープンデータ × モバイルUX 複雑な運行情報を 『直感』に変換する技術
tinykitten
PRO
0
160
クラウドに依存しないS3を使った開発術
simesaba80
0
170
Canon EOS R50 V と R5 Mark II 購入でみえてきた最近のデジイチ VR180 事情、そして VR180 静止画に活路を見出すまで
karad
0
140
Featured
See All Featured
Visualization
eitanlees
150
16k
Reflections from 52 weeks, 52 projects
jeffersonlam
355
21k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
26
3.3k
Automating Front-end Workflow
addyosmani
1371
200k
Heart Work Chapter 1 - Part 1
lfama
PRO
3
35k
We Are The Robots
honzajavorek
0
120
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
162
16k
Balancing Empowerment & Direction
lara
5
820
Statistics for Hackers
jakevdp
799
230k
Kristin Tynski - Automating Marketing Tasks With AI
techseoconnect
PRO
0
110
How to Talk to Developers About Accessibility
jct
1
85
Paper Plane (Part 1)
katiecoart
PRO
0
2.1k
Transcript
git rebase by Arturas Smorgun, Inviqa Enlightening Lunch
• Git Internal Data Structures; • Interactive Rebase; • Basic
Rebase; • Less Basic Rebase; • Use Case. Contents
Git Internals Data structures
• Content-addressable filesystem; • Insert content -- get key back;
• You can add to graph, but not edit or remove. Git
• blob -- file contents • tree -- directory layouts
and filenames • commit -- forms git commit graph • tag -- annotated tag Objects
References • Pointer to an object: • branch • remote
branch • lightweight tag
Symbolic references • Pointer to another pointer: • HEAD
Interactive Rebase
$ git rebase -i HEAD~3
Interactive • Remove or rearrange commits; • Edit commit messages;
• Amend commits; • Squash several commits; • Run shell commands.
--autosquash • Used in interactive rebase; • Commits starting with
“squash! “ will be automatically marked to squash.
Basic Rebase
$ git rebase <newbase> <newbase> - branch, to which rebasing;
git rebase • Forward-port local commits to the updated upstream
head (from manual); • One of the ways to integrate changes from one branch to another (from the internets).
How it works? • Go to common ancestor; • get
diff by each commit of current branch; • save diffs to temporary files; • reset current branch to same commit as branch you rebasing onto; • apply each change in turn.
^ say we have this
^ $ git rebase master
Less Basic Rebase
$ git rebase --onto <newbase> <base> <tip> <newbase> -- branch,
to which rebasing; <next> -- ancestor of rebase branch; <topic> -- tip of rebase branch;
^ say we have this
^ after rebase --onto
Final Note (instead of conclusion)
Do not rebase commits that you have pushed to a
public repository.
Questions?
Thank you! See Inviqa Training “Git Beyond the Basics” by
Alistair Stead and “Pro Git” ebook at http://git-scm.com/book by Scot Chacon