mirror of
https://github.com/sharkdp/bat.git
synced 2026-10-26 20:16:33 +00:00
fix(syntax): avoid repeated log level scans
This commit is contained in:
1 parent
2ba8db9c14
commit
db69aab106
1 file changed
+5
-4
+5
-4
@@ -38,19 +38,20 @@ contexts:
|
||||
scope: markup.underline.link.scheme.log
|
||||
push: url-host
|
||||
log_level_lines:
|
||||
- match: (?=.*{{error}})
|
||||
# Prevent retrying each lookahead at every position.
|
||||
- match: \G(?=.*{{error}})
|
||||
push:
|
||||
- error_line_meta
|
||||
- main_pop_at_eol
|
||||
- match: (?=.*{{warning}})
|
||||
- match: \G(?=.*{{warning}})
|
||||
push:
|
||||
- warning_line_meta
|
||||
- main_pop_at_eol
|
||||
- match: (?=.*{{info}})
|
||||
- match: \G(?=.*{{info}})
|
||||
push:
|
||||
- info_line_meta
|
||||
- main_pop_at_eol
|
||||
- match: (?=.*{{debug}})
|
||||
- match: \G(?=.*{{debug}})
|
||||
push:
|
||||
- debug_line_meta
|
||||
- main_pop_at_eol
|
||||
|
||||
Reference in new issue
Block a user