[PATCH 6/6] filters/syntax-highlighting.sh: Use highlight version 3 invocation
Sven Göthel
sgothel at jausoft.com
Tue Jul 21 11:33:32 UTC 2026
On 7/20/26 6:22 AM, Aiden Woodruff wrote:
> Sure highlight >= 3 is readily available in most distributions, why break
> compatibility now?
Just a proposal, you are probably right here.
> We could instead extract and check the version before
> highlighting:
>
> ```
> highlight_version=$(highlight --version | \
> sed 's/^ highlight version //;t m;d;b;:m;s/\.[0-9]*$//')
> if [ $highlight_version -lt 3 ]; then
instead of these extra calls and work,
we could also add a
filters/syntax-highlighting3.sh file
to be picked up by the cgitrc or not.
~Sven
More information about the CGit
mailing list