Live data from Hacker News

Delta: A syntax-highlighting pager for Git, diff, grep, and blame output

github.com

11–20 of 98 posts

Re: Delta: A syntax-highlighting pager for Git, diff, grep, and blame output

#16
post #5

i knew git could use arbitrary diff filter but never realised it was this simple to use. This looks very nice. The related? project "bat" also looks interesting.

bat is great. I end up doing

curl … | prettier --parser html | bat

to get not-ugly HTML output from curl.

Re: Delta: A syntax-highlighting pager for Git, diff, grep, and blame output

#20

The thing that prevents me from using delta is lack of "system" theme detection. Can't set it up and forget and mismatching theme with shell makes it really difficult to read.

It will use whatever `bat` theme is set. Bat itself doesn't do system theme detection, but it's easy enough to do in a script - I have one that gets called when my system theme changes where I set themes for various programs. Looks like this for dark mode:

    #!/usr/bin/fish
    gsettings set org.gnome.desktop.interface gtk-theme "Adwaita-dark"
    fish_config theme choose "ayu Mirage"
    yes | fish_config theme save
    echo "--theme=OneHalfDark" > ~/.config/bat/config
    kitten themes --reload-in=all "Ayu Mirage"
The bat config change will make delta respect my "system" theme.
Post reply on HN