139 points · by todsacerdoti · 5y ago · 39 comments
Now, that I finally feel good enough, that I can rely on what I know and finally in position to mentor others, I made what I feel was missing, a set of sandbox git repository challenges, with only real life examples [1] I met in professional repos.
I hope the dark age of git education passes soon (and is already fading).
I have a git training I developed for work that focuses not on telling everyone what the solutions to their problems are, but walking them into those problems, getting into detached head, getting into branching and rebasing problems, and then explaining how to get back out of them. I've gotten generally positive feedback from this.
If nothing else, at the very least it convinces them that when they see the "detached head" message, they can come get help and I'll be very sympathetic to what is going on, because I told them up front that I expect this sort of thing to happen and it doesn't mean they're bad people for getting into this state, and we can at least have a sane conversation about what they did to get there and what they want to happen.
It's probably particularly hard to try to tell people the solutions to problems they've never had when they also don't even know what's going on around them and what a problem even is.
There are lots of other programs like that, GDB for example, each with it's own challenge of sythesizing case studies. I hope this kind of learning continues, not only with git, but across other programs as well.
[1] https://svnbook.red-bean.com/en/1.6/svn.ref.svn.c.checkout.h...
Go for it!
The quality of the introductory documentation has gotten better over the years, thank goodness. I know a great many developers who are terrified of git, and stick to the couple of commands they get taught by the team lead.
https://medium.com/girl-writes-code/git-is-a-directed-acycli...
While reading the Medium post, it may be helpful to bear in mind that arcs shown in the drawings — called “pointers” in the text — are exactly hashes to git.
Explains nearly everything you need concisely and effectively, in about 20 minutes (the rest of it is primarily demonstration).
For example, where I work (https://graphite.dev) we use some of these plumbing commands to extend git to store additional information about pull requests. My teammate did a writeup of this here: https://dev.to/foster/how-to-use-native-git-as-a-key-value-s...
Is there something like ls, but for possible programs on your PATH? Or is there a way to just get a dump of all executables on the current PATH?
Even still, it seems like you’d have to decide which of those programs to show first in the documentation. And to get a short description of each of them, you’d have to invoke them.
I guess the solution is “use manpages,” but it’s kind of unsatisfying — I’d like to build something like git, but using CLI --help.
EDIT: Seems ... strange.
- https://github.com/git/git/blob/master/help.c#L260-L294
- https://github.com/git/git/blob/master/command-list.txt
- https://github.com/git/git/blob/master/generate-cmdlist.sh
I'm not sure `git help` supports the concept of adding third-party `git` commands as first-class citizens, but I'm still reading.
I was hoping there was a way to attach a short help descriptor to each of the third-party commands. But the help descriptors seem to be hardcoded for the builtin commands, with no support for third party commands. Darn.
Tech Talk: Linus Torvalds on git (2007)
"Linus Torvalds visits Google to share his thoughts on git, the source control management system he created two years ago."
However, this is not the tutorial I would send anyone towards, as a user of git. The programming design logic is not enough to get better at the workflows. Mercifully, branching patterns in team projects are omitted entirely.
enjoyable and glad to read this for a second or third layer to understanding git