1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-02-09 13:47:11 +02:00
This commit is contained in:
Cokile 2021-12-11 11:24:38 +08:00 committed by Jesse Duffield
parent 3771f9c98b
commit 76e6745526
2 changed files with 5 additions and 5 deletions

View File

@ -376,22 +376,22 @@ If you're still having trouble please raise an issue.
## Custom Author Color ## Custom Author Color
Lazygit will assgin a random color for every commit author in the commits pane by default. Lazygit will assign a random color for every commit author in the commits pane by default.
You can customize the color in case you're not happy with the randomly assigned one: You can customize the color in case you're not happy with the randomly assigned one:
```yaml ```yaml
gui: gui:
authorColors: authorColors:
'John Smith': '#ff0000 # use red for John Smith 'John Smith': '#ff0000' # use red for John Smith
``` ```
You can use wildcard to set a unified color in case your are lazy to customize the color for every author or you are just want a single color for all/other authors: You can use wildcard to set a unified color in case your are lazy to customize the color for every author or you just want a single color for all/other authors:
```yaml ```yaml
gui: gui:
authorColors: authorColors:
# use red for John Smith # use red for John Smith
'John Smith': '#ff0000 'John Smith': '#ff0000'
# use blue for other authors # use blue for other authors
'*': '#0000ff' '*': '#0000ff'
``` ```

View File

@ -55,7 +55,7 @@ func AuthorStyle(authorName string) style.TextStyle {
return value return value
} }
// use the unified style whatever the autor name is // use the unified style whatever the author name is
if value, ok := authorStyleCache[authorNameWildcard]; ok { if value, ok := authorStyleCache[authorNameWildcard]; ok {
return value return value
} }