Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Git Rebase
Search
Arturas Smorgun
August 29, 2013
Programming
260
2
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Git Rebase
Introduction to Git Rebase by me at Inviqa Enlighening Lunch
Arturas Smorgun
August 29, 2013
More Decks by Arturas Smorgun
See All by Arturas Smorgun
Solve Complex Problems with DDD
asarturas
0
170
Review of Graph Databases
asarturas
0
110
Profiling in PHP
asarturas
5
970
Design Patterns in PHP Applications
asarturas
5
230
Application Quality
asarturas
6
350
Vagrant 1.2.2 and AWS
asarturas
0
110
Let's automate!
asarturas
0
290
AngularJS
asarturas
13
1.3k
Other Decks in Programming
See All in Programming
phperだってパンチカードでコーディングしたい
o0h
PRO
0
460
Lambda durable functionsでHuman in the Loopを楽に…楽に……
har1101
1
200
Compiling a real-world CLI tool to native with Static Hermes
tmikov2023
0
130
続・コーディングルールの鮮度を保ちたい / keep-fresh-go-internal-conventions-again
handlename
0
120
Vue.jsで作る空間解析アプリとCapacitorプラグインのData Bridge
hal_spidernight
1
110
コーディング自動化の次へ。人の介入をゼロにするファクトリーとサポートAIによる実践
timakin
5
4.7k
Groovy as a human and AI friendly programming language
paulk
0
110
Vue Fes Japan の “作る側”に関わってみて
naokihaba
1
190
Jetpack Compose Mechanisms
skydoves
3
870
GraphQL の onError と Nullability のこれから
quramy
0
180
JIS keyboard support in Omarchy
lef237
0
160
自作Discord音声botをLambda MicroVMsに移行した話 / Migrating My Discord Voice Bot to Lambda MicroVMs
akihisaikeda
0
150
Featured
See All Featured
SEO Brein meetup: CTRL+C is not how to scale international SEO
lindahogenes
2
2.9k
Ecommerce SEO: The Keys for Success Now & Beyond - #SERPConf2024
aleyda
1
2.2k
The Curse of the Amulet
leimatthew05
3
16k
Leo the Paperboy
mayatellez
10
2.4k
Navigating Algorithm Shifts & AI Overviews - #SMXNext
aleyda
1
1.7k
Skip the Path - Find Your Career Trail
mkilby
1
260
Code Reviewing Like a Champion
maltzj
529
40k
職位にかかわらず全員がリーダーシップを発揮するチーム作り / Building a team where everyone can demonstrate leadership regardless of position
madoxten
70
67k
Large-scale JavaScript Application Architecture
addyosmani
516
110k
Tips & Tricks on How to Get Your First Job In Tech
honzajavorek
1
810
Documentation Writing (for coders)
carmenintech
77
5.6k
What Being in a Rock Band Can Teach Us About Real World SEO
427marketing
0
1.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