3 ms·
In my opinion, the biggest thing git could do to be easier to learn is make the "git lola" alias what happens by default when you write "git log". Once you see
by adhesive_wombat 3y ago
In my opinion, the biggest thing git could do to be easier to learn is make the "git lola" alias what happens by default when you write "git log".
Once you see the graph change as you move about, it all makes a lot more sense.
http://blog.kfish.org/2010/04/git-lola.html?m=1 http://blog.kfish.org/2010/04/git-lola.html?m=1
- nerdponx 3y agoAgreed, with the caveat that a tangled commit history can be overwhelming to a beginner. Probably the only time I really want to recommend a Git GUI is for visualizing the commit graph. I think GitUp does a really good job of making it navigable and understandable, but is unfortunately Mac-only: https://gitup.co/ https://gitup.co/ If you're interested, here's my version of this: [alias] ## Pretty log graph log-oneline = log --decorate=short --date='format-local:%a %F %H:%M' --pretty='tformat:%C(auto)%h%C(reset) %C(auto,blue)[%ad]%C(reset)%C(auto)%d%C(reset) %aN: %s' log-graph = log-oneline --topo-order --graph reflog-oneline = log-oneline --walk-reflogs lg = log-graph lgl = log-graph --branches --tags lgr = log-graph --branches --tags --remotes lga = log-graph --all For anyone who doesn't want to dig around in the git-log(1) man page, the relevant format placeholder are: %C(col) Change color to "col" %h Abbreviated commit hash %ad Author date (formatted as per --date) %d Ref name (like with --decorate) %aN Author name %s "Subject" (first line of commit message) The difference with the usual `--decorate --pretty=oneline --abbrev-commit` options is that my version includes the date and author name, which can be really helpful when navigating a long commit history and/or a project with multiple contributors. Without it, I often found myself wondering "who did that, and when did they do it?". The --topo-order option also helps here.