forked from mirrors/jj
docs: add customization example of color-words diff style
The default style is compatible with various terminal emulators, but I suspect that many people wouldn't like underlines. Let's add an example to override it.
This commit is contained in:
parent
3bca159b1a
commit
5a85254bde
2 changed files with 15 additions and 0 deletions
|
@ -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 <arg>` 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)'`.
|
||||
|
|
|
@ -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
|
||||
|
|
Loading…
Reference in a new issue