-
Notifications
You must be signed in to change notification settings - Fork 405
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
🐛 Custom git log coloring is overwritten #163
Comments
Hi @0xC0FFEE, thanks for this. I'd like to support this, but it might require a bit of thought/effort. Any thoughts/ideas are welcome! From the beginning, delta has immediately stripped out all ANSI escape sequences as soon as it receives a line of input. I think I was thinking that it would be difficult to parse the input correctly with them present. We have requests #72 and #144 for Perhaps there could be a solution where delta continues to strip them out, and then reapplies them before emitting the line. |
Hi @dandavison, what do you think about storing the original lines as well? The parsing could be done on the stripped line and if delta wants to output the original line it can do so at any point in time. AFAICT |
Thanks for those thoughts @0xC0FFEE. I've done exactly as you suggest for this case. If you feel like building on the master branch, it should be working for your toy example. If that string starts with a
I'm curious what your non-toy examples are. |
Thanks for resolving this so quickly 👍 The non-toy example is my custom git log format ( Before: After: It seems like I'm using these color patterns to identify the next commit. Without these colors it is quite hard for me to spot the next commit. Maybe there is a feature request hidden inside: visually separate the individual commits somehow. Edit: I've noticed a similar edge case behavior when using the When looking at the raw output: 3f0b0d2b1 0xC0FFEE bar---
README.md | 2 ++
1 file changed, 2 insertions(+)
diff --git a/README.md b/README.md
index 92ab1377b..d263ae307 100644
--- a/README.md
+++ b/README.md
@@ -28,6 +28,8 @@ Neovim is a project that seeks to aggressively refactor Vim in order to:
See the [Introduction](https://github.com/neovim/neovim/wiki/Introduction) wiki page and [Roadmap]
for more information.
+bar
+
Features
--------
5b1ce00a8 0xC0FFEE foo---
README.md | 2 ++
1 file changed, 2 insertions(+)
diff --git a/README.md b/README.md
index f9a9a7fe8..92ab1377b 100644
--- a/README.md
+++ b/README.md
@@ -1,5 +1,7 @@
[![Neovim](https://raw.githubusercontent.com/neovim/neovim.github.io/master/logos/neovim-logo-300x87.png)](https://neovim.io)
+foo
+
[Documentation](https://neovim.io/doc) |
[Chat](https://gitter.im/neovim/neovim) |
[Twitter](https://twitter.com/Neovim)
f9055c585 Ghjuvan Lacambre LSP: enable using different highlighting rules for LSP signs (#12176)---
runtime/doc/lsp.txt | 16 ++++++++++++----
runtime/lua/vim/lsp.lua | 8 ++++----
runtime/lua/vim/lsp/util.lua | 1 +
test/functional/plugin/lsp_spec.lua | 4 ++++
4 files changed, 21 insertions(+), 8 deletions(-)
diff --git a/runtime/doc/lsp.txt b/runtime/doc/lsp.txt
index 2d0bba0ff..8140b6a15 100644
--- a/runtime/doc/lsp.txt
+++ b/runtime/doc/lsp.txt
@@ -163,13 +163,21 @@ name: >
LSP HIGHLIGHT *lsp-highlight* It seems like a good starting point for lines to parse are all lines after a line starts with [1] diff --git a/README.md b/README.md
index 92ab1377b..d263ae307 100644
--- a/README.md
+++ b/README.md
@@ -28,6 +28,8 @@ Neovim is a project that seeks to aggressively refactor Vim in order to: |
Cool! That's helpful -- I'm trying to get straight in my mind the different sorts of
Have you experimented with |
Thanks for pointing me towards Currently I'm not sure if there is a feature request at all, as Thanks again for tackling this so quickly. If you would like me to open another report for the |
When specifying a custom git log format which includes colors (e.g. via
git log --patch --pretty=format:'%C(red)I SHOULD BE RED'
) delta overwrites these custom colors starting from the seconds log message.The text was updated successfully, but these errors were encountered: