Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Low Level Git
Search
Hiroyuki Morita
December 05, 2013
Technology
0
87
Low Level Git
Hiroyuki Morita
December 05, 2013
Tweet
Share
More Decks by Hiroyuki Morita
See All by Hiroyuki Morita
Rubyistなら知っておきたい継承の話 / The inheritance for Rubyist
chiastolite
4
1.3k
esaを使って暗黙知を減らす取り組み
chiastolite
2
4k
git-inside
chiastolite
0
240
vagrant-itamae
chiastolite
1
1.5k
sushi for common people
chiastolite
0
320
Social Coding with GitHub
chiastolite
0
130
about Immutable Infrastructure
chiastolite
0
86
Other Decks in Technology
See All in Technology
開発者の定量・定性データを組み合わせて開発者体験を把握するための取り組み
ham0215
1
170
エムスリーエビデンス創出プロダクトチーム紹介資料 / Introduction of M3 Create Evidence Team
m3_engineering
0
100
PdMはどのように全てのスピードを上げられるか ~ 非連続進化のための具体的な取り組み ~
sansantech
PRO
4
1.4k
より快適なエラーログ監視を目指して
leveragestech
4
1.5k
やってやろうじゃないかメカアジャイル! / Let's do it, mechanical agile!
psj59129
1
700
『GRANBLUE FANTASY Relink』ソフトウェアラスタライザによる実践的なオクルージョンカリング
cygames
0
180
Analytics-Backed App Widget Development - Served with Jetpack Glance
miyabigouji
0
630
OSTという文化を組織に根付かせてみた
sansantech
PRO
2
430
フルカイテン株式会社 採用資料
fullkaiten
0
32k
プログラム検証入門
riru
6
880
eBPFのこれまでとこれから
yutarohayakawa
10
3.3k
Segment Anything Model 2
tenten0727
3
720
Featured
See All Featured
Atom: Resistance is Futile
akmur
261
25k
Unsuck your backbone
ammeep
667
57k
Visualization
eitanlees
142
15k
Writing Fast Ruby
sferik
623
60k
The Power of CSS Pseudo Elements
geoffreycrofte
71
5.3k
The Pragmatic Product Professional
lauravandoore
31
6.2k
Thoughts on Productivity
jonyablonski
66
4.2k
How GitHub (no longer) Works
holman
310
140k
Practical Orchestrator
shlominoach
185
10k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
23
1.7k
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
24
610
Designing for Performance
lara
604
68k
Transcript
Low-level Git
Why Low-level Git • GitͷίΞͷ΄͏ͷ • ͳΜͱͳ͘Ͱ͍ͬͯͨίϚϯυ͕ Θ͔͖ͬͯͨ • ௐͯͨΒ͍Ζ͍Ζ͓͠Ζ͔ͬͨ
Start!!
Git Objects
> git init
> ls .git
> find .git/objects
create first commit
> ls .git/objects
3 Objects...? • Commit (f7a253e) • .git/objects/f7/a253ed90a5bb56d6cd8b3580485a7ae23acc88 • ??? (05934ea)
• .git/objects/05/934ea69782016b0fbaa7bf46d574cefb039958 • ??? (802992c) • .git/objects/80/2992c4220de19a90767f3000a79a31b98d0df7
> git cat-file -t {sha1}
Commit/Tree/Blob • Commit (f7a253e) • .git/objects/f7/a253ed90a5bb56d6cd8b3580485a7ae23acc88 • Tree (05934ea) •
.git/objects/05/934ea69782016b0fbaa7bf46d574cefb039958 • Blob (802992c) • .git/objects/80/2992c4220de19a90767f3000a79a31b98d0df7
Commit? Tree? Blob?
> git cat-file commit
Commit has... • Reference to ‘a’ Tree Object • Author
& Committer • Commit Message ! • (Reference(s) to parent)
> git ls-tree
Tree has... • Reference to Blob Objects • & File
name • & File Permission ! • (Reference to Tree Objects)
> git cat-file blob
Blob is... • commited file • don’t have a file
name
None
merge commit
commit has a parent
merge commit has parents
None
Question?
Reference
• alias to commits • ex) • HEAD • master
• some_branch • origin/master Reference?
Where is Branchs?
Where is the HEAD?
HEAD -> ref -> commit
None
Question?
Reference • ࣮ફ Git - ϨϕϧʹΔ Git • http://www.slideshare.net/youhei/ git-12695573
• ʲ༁ʳGitΛϘτϜΞοϓ͔Βཧղ͢ Δ • http://keijinsonyaban.blogspot.jp/2011/05/
appendix
example: rename
blob is not change