Closed mgeisler closed 5 years ago
Nice idea! I think some of the Go diff libraries support this. chezmoi
currently uses github.com/pmezard/go-difflib
, but I now see that this is no longer maintained. So, we should switch to a diff lib that supports color.
PRs welcome :) The code to change is in lib/chezmoi/logging_mutator.go
.
Someone actually made a PR to add coloring to the library, but the original creator wasn't interested in merging it. That's unfortunate.
That's OK. People's priorities change over time. With open source, we can build on others' work even when the original author is busy,
It would be nice to have
chezmoi diff
use color for the output.As a work around, I currently use