Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Color output for chezmoi diff #216

Open
mgeisler opened this Issue Feb 15, 2019 · 1 comment

Comments

Projects
None yet
2 participants
@mgeisler
Copy link
Contributor

mgeisler commented Feb 15, 2019

It would be nice to have chezmoi diff use color for the output.

As a work around, I currently use

chezmoi diff | colordiff

@twpayne twpayne added the enhancement label Feb 15, 2019

@twpayne

This comment has been minimized.

Copy link
Owner

twpayne commented Feb 15, 2019

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.