diff --git a/CHANGELOG.md b/CHANGELOG.md index 75e5c63a7..b28c2fffe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -63,6 +63,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 * New diff option `jj diff --name-only` allows for easier shell scripting. +* In color-words diffs, hunks are now highlighted with underline. See [diff + colors and styles](docs/config.md#diff-colors-and-styles) for customization. + * `jj git push -c ` can now accept revsets that resolve to multiple revisions. This means that `jj git push -c xyz -c abc` is now equivalent to `jj git push -c 'all:(xyz | abc)'`. diff --git a/docs/config.md b/docs/config.md index d75a5de94..72411f0d0 100644 --- a/docs/config.md +++ b/docs/config.md @@ -166,6 +166,18 @@ useful reminder to fill in things like BUG=, TESTED= etc. ui.default-description = "\n\nTESTED=TODO" ``` +### Diff colors and styles + +In color-words diffs, hunks are rendered with underline. You can override the +default style with the following keys: + +```toml +[colors] +# Highlight hunks with background +"diff removed token" = { bg = "#221111", underline = false } +"diff added token" = { bg = "#002200", underline = false } +``` + ### Diff format ```toml