The Git Parable
The following parable will take you on a journey through the creation of a Git-like system from the ground up. Understanding the concepts presented here will be the most valuable thing you can do to prepare yourself to harness the full power of Git. The concepts themselves are quite simple, but allow for an amazing wealth of functionality to spring into existence.
- Original text by Tom Preston-Werner: https://tom.preston-werner.com/2009/05/19/the-git-parable.html Only text, no visuals.
- Live talk by Johan Herland: https://www.youtube.com/watch?v=jm7QsI-nNjk&ab_channel=NDCConferences 90 Minutes. Same story, but enhanced with slides and visuals.
- Slides from the talk: https://github.com/jherland/git_parable/blob/master/git_parable.pdf
- Shorter video with text-to-speech audio of the original text and the slides of Johan Herland: https://www.youtube.com/watch?v=GyHdoGZY69E&ab_channel=JayneTheGrateful
Learning (Git) by Doing
- Hands-on step-by-step guide from the basics to advanced stuff: https://gitimmersion.com/index.html This guide is creating a small project in the ruby programming language, but it seems like you don't need to know ruby in order to follow the guide.
- Program for a playful introduction to the most important git commands: https://ohmygit.org/
- Website for learning branching and modifying history in git: https://learngitbranching.js.org/ This tutorial only teaches some parts of git! Some parts are not covered at all, but the other parts are covered beyond the basics.
Git Cheat Sheets
- Interactive Cheat Sheet: https://ndpsoftware.com/git-cheatsheet.html
- Github Education Cheat Sheet: https://education.github.com/git-cheat-sheet-education.pdf
- Git Cheat Sheet listing the most important basic commands: https://github.com/nerdgirl/git-cheatsheet-visual/blob/master/gitcheatsheet.pdf
- Escape a git mess, step-by-step: http://justinhileman.info/article/git-pretty/git-pretty.png
Basics
- Extensive Guide by Atlassian about many git commands (what they do, how to use them, and how they work): https://www.atlassian.com/git/tutorials/setting-up-a-repository
- Git for the lazy: https://wiki.spheredev.org/index.php/Git_for_the_lazy A very quick and shallow guide on how to get started with git.
- Talk “Introduction to Git” by Scott Chacon: https://www.youtube.com/watch?v=ZDR433b0HJY&ab_channel=InfoQ This talk seems to cover the basics on how to get started, but also with a few internals mixed in.
Intermediate
- Blog-Series about more advanced topics about the usage and the environment of git.
- Creating the perfect commit: https://css-tricks.com/creating-the-perfect-commit-in-git/
- Branching strategies: https://css-tricks.com/branching-strategies-in-git/
- Better collaboration with pull requests: https://css-tricks.com/better-collaboration-with-pull-requests/
- Merge conflicts: https://css-tricks.com/merge-conflicts-what-they-are-and-how-to-deal-with-them/
- Rebase vs Merge: https://css-tricks.com/rebase-vs-merge-integrating-changes-in-git/
- Interactive Rebase: Clean up your Commit History https://css-tricks.com/interactive-rebase-clean-up-your-commit-history/
- Cherry-Picking Commits in Git https://css-tricks.com/cherry-picking-commits-in-git/
- Using the Reflog to Restore Lost Commits https://css-tricks.com/using-the-reflog-to-restore-lost-commits/
- Visual Git Reference: http://marklodato.github.io/visual-git-guide/index-en.html Visualizations about how common git commands work.
Advanced
- Git Internals PDF: https://raw.githubusercontent.com/pluralsight/git-internals-pdf/master/drafts/peepcode-git.pdf A document explaining the internals of git (but also giving an introduction for beginners)
- Think Like (a) Git: http://think-like-a-git.net/ Guide for people that know how to use git, but want to learn something about the internals of git.
- Advanced Git topics by Atlassian: https://www.atlassian.com/git/tutorials/advanced-overview
Specific commands
git log --all --color --graph --pretty=format:'%Cred%h%Creset -%C(bold blue)%d%Creset %s %Cgreen(%cr) %C(yellow)<%an>%Creset' --abbrev-commit-
git stash: https://www.atlassian.com/git/tutorials/saving-changes/git-stash -
git revert: https://www.atlassian.com/git/tutorials/undoing-changes/git-revert -
git bisect: https://git-scm.com/docs/git-bisect -
git cherry-pick: https://www.atlassian.com/git/tutorials/cherry-pick -
git reflog: https://www.atlassian.com/git/tutorials/rewriting-history/git-reflog -
git commit --amend: https://www.atlassian.com/git/tutorials/rewriting-history -
git reset: https://www.atlassian.com/git/tutorials/undoing-changes/git-reset -
git rebase (-i): https://www.atlassian.com/git/tutorials/rewriting-history/git-rebase git config credential.helper store