Does --theme=ansi improve performance? #2451
-
Does --theme=ansi improve bat performance? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
I personally wouldn't expect it to make much difference, the same syntax highlighting engine is used, the same color scheme processing rules, just presumably with less colors. You can always benchmark it though. |
Beta Was this translation helpful? Give feedback.
-
Well. Let's measure it: hyperfine \
--parameter-list theme default,ansi \
--export-markdown=theme.md \
'bat -f --theme={theme} jquery.js' (I'm using the file Yes.
That might come down to having less output to write(?). Because the ANSI escape sequences for a 24bit-color-theme are much longer. I also ran a benchmark using |
Beta Was this translation helpful? Give feedback.
I personally wouldn't expect it to make much difference, the same syntax highlighting engine is used, the same color scheme processing rules, just presumably with less colors. You can always benchmark it though.