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
96
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.4k
esaを使って暗黙知を減らす取り組み
chiastolite
2
4.2k
git-inside
chiastolite
0
250
vagrant-itamae
chiastolite
1
1.5k
sushi for common people
chiastolite
0
330
Social Coding with GitHub
chiastolite
0
140
about Immutable Infrastructure
chiastolite
0
87
Other Decks in Technology
See All in Technology
JAWS FESTA 2024「バスロケ」GPS×サーバーレスの開発と運用の舞台裏/jawsfesta2024-bus-gps-serverless
ma2shita
3
280
事業モメンタムを生み出すプロダクト開発
macchiitaka
0
100
IAMのマニアックな話2025
nrinetcom
PRO
6
1.3k
OPENLOGI Company Profile for engineer
hr01
1
20k
アジャイルな開発チームでテスト戦略の話は誰がする? / Who Talks About Test Strategy?
ak1210
1
660
Amazon Q Developerの無料利用枠を使い倒してHello worldを表示させよう!
nrinetcom
PRO
2
120
目標と時間軸 〜ベイビーステップでケイパビリティを高めよう〜
kakehashi
PRO
8
840
2/18 Making Security Scale: メルカリが考えるセキュリティ戦略 - Coincheck x LayerX x Mercari
jsonf
0
240
事業を差別化する技術を生み出す技術
pyama86
2
430
Pwned Labsのすゝめ
ken5scal
2
520
フォーイット_エンジニア向け会社紹介資料_Forit_Company_Profile.pdf
forit_tech
1
1.7k
データモデルYANGの処理系を再発明した話
tjmtrhs
0
170
Featured
See All Featured
Designing on Purpose - Digital PM Summit 2013
jponch
117
7.1k
Build your cross-platform service in a week with App Engine
jlugia
229
18k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
30
4.6k
The MySQL Ecosystem @ GitHub 2015
samlambert
250
12k
The Invisible Side of Design
smashingmag
299
50k
Being A Developer After 40
akosma
89
590k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
233
17k
Designing Experiences People Love
moore
140
23k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
100
18k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
47
5.2k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
330
21k
Become a Pro
speakerdeck
PRO
26
5.2k
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