What is Decoding Git?
Decoding Git discusses the very first version of the Git codebase written by Linus Torvalds (the creator of Linux) in 2005. Git's original version is written in the C programming language and consists of about 1,000 lines of code and a total of 7 commands, and they actually work.
The simplicity and 'smallness' of the code make Git's initial commit the perfect codebase for you to study to learn how the code works. The fact that one of the most popular and useful tools in software development history is so simple to understand directly from its initial code is an amazing thing.
This guidebook makes the learning experience even easier, by diving into Git's original C code in detail to help you learn what makes Git tick.
Who is this book for?
- Junior Devs
- Senior Devs, Team Leads, CTOs
- Curious Git users
- Open-source contributors
- Anyone interested in learning more about Git!
Chapters
1
Introduction to Git's Code
2
An Overview of Git's Original Version
3
Installing Git's Original Version
4
Git Original Command Tutorial
5
The C Header File cache.h
6
Read the Index with read-cache.c
7
Initialize Git with init-db.c
8
Stage Files with update-cache.c
9
Create Trees with write-tree.c
10
Commit Changes with commit-tree.c
11
Read from the Repo with read-tree.c
12
View File Contents with cat-file.c
13
Calculate Diffs with show-diff.c
14
Conclusion
Testimonials
"I bought this Decoding Git book and excitedly read through the first few chapters in a few hours. Fantastic, fantastic, fantastic! It gives me a good intuitive grasp of Git. Much better than other tutorials I have read that don't start from the fundamentals. Jacob explains everything from the ground up, rather than assuming too much prior information. His logic and flow in the book are superb - the best I have seen from a coding book. Highly recommended!" -Jerry C.
"This book takes a brilliant approach of teaching git by going through the code of its initial commit. In this early version of git we see how and why git was built as it was, before it became more complex and harder to understand. Even in this initial commit there abstractions such as content addressable filesystem, but they are manageable and it helps us learn the overall organization and big picture. Seeing the actual files and code that git uses makes it make much more sense and this book is an ideal way to actually learn and understand git." -Neal C.