filters: fix colorize urls in signatures
When a signature contains a line that starts with an url, the url is not
highlighted properly:
--
Foobar
[38;2;255;255;175mmhttps://foobar.org
The trailing m of the signature color start \x1b[38;2;175;135;255m is
considered as part of the URL scheme (i.e. mhttps:// instead of
https://). Colorize the URLs first before wrapping with the signature
color.
Fixes: df8c129235
("filters: port colorize to awk")
Signed-off-by: Robin Jarry <robin@jarry.cc>
This commit is contained in:
parent
c77a1c5d9d
commit
d2c239292e
1 changed files with 1 additions and 1 deletions
|
@ -77,8 +77,8 @@ function color_quote(line) {
|
|||
$0 = diff_del $0 reset
|
||||
}
|
||||
} else if (in_signature) {
|
||||
$0 = signature $0 reset
|
||||
gsub(url_pattern, url "&" signature)
|
||||
$0 = signature $0 reset
|
||||
} else if (in_headers) {
|
||||
if ($0 ~ /^$/) {
|
||||
in_signature = 0
|
||||
|
|
Loading…
Reference in a new issue