Earlier quoted context omitted.
I... did not know that! Yep yep that should do the trick for me. Thanks a lot, actually!
Most tools that do formatted output, if they’re well-behaved, should try to detect if their output is a pipe and if so, disable formatting. Some examples that I can think of off the top of my head (in addition to git) are ripgrep and jq, both of which do the right thing and strip formatting.
How Core Git Developers Configure Git
81–90 of 129 posts
Re: How Core Git Developers Configure Git
#82I discovered that you can have git use the pager you like so I set it to my darling : bat git config --global core.pager bat https://github.com/sharkdp/bat/
Re: How Core Git Developers Configure Git
#83Earlier quoted context omitted.
Shortened aliases come from cvs/svn land, sorting tags by a logical manner, adding some extra archive types for "git archive", making it so git log always shows my local time zone, pull will never do a non-ff merge, make it so Git doesn't complain about repositories in places it doesn't like, turning off an annoying message about a detached HEAD state, and shut git up about the default branch.
Yeah, I didn't do aliases on purpose, because I wanted everything to be fairly global, where I feel like aliases are more personal. But yes, aliases are great.
Re: How Core Git Developers Configure Git
#84Re: How Core Git Developers Configure Git
#85I discovered that you can have git use the pager you like so I set it to my darling : bat git config --global core.pager bat https://github.com/sharkdp/bat/
Re: How Core Git Developers Configure Git
#86Re: How Core Git Developers Configure Git
#87Re: How Core Git Developers Configure Git
#88My favorite alias is `git out`, which just lists all unpushed commits. I use it all the time. [alias] out = "log @{u}.." In my head I always hear it in the voice of The Terminator: https://youtu.be/8cdC1Y5oRFg?t=54
Now I want to do: `git to-da-choppa`
Re: How Core Git Developers Configure Git
#89How much of this is for a noob like me that just uses vscode? I hardly ever see the git command line, and when I do see it, its trouble beyond what anybody can fix...
For instance, I wrote this post last year about how you can use Git as a powerful debugging tool: https://news.ycombinator.com/item?id=39877637
Re: How Core Git Developers Configure Git
#90I discovered that you can have git use the pager you like so I set it to my darling : bat git config --global core.pager bat https://github.com/sharkdp/bat/
(Weirdly, git doesn't seem to honour the PAGER var (which would be even better), although its man page claims it does)