From 741ba20481ae44f53a7e8c61af3d19b6b77f19d4 Mon Sep 17 00:00:00 2001 From: Mike Vink Date: Sun, 6 Jul 2025 14:48:51 +0200 Subject: colors --- libexec/cgit/filters/highlighting.sh | 2 +- libexec/cgit/gruvbox.css | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/libexec/cgit/filters/highlighting.sh b/libexec/cgit/filters/highlighting.sh index 6976695..202641c 100755 --- a/libexec/cgit/filters/highlighting.sh +++ b/libexec/cgit/filters/highlighting.sh @@ -118,4 +118,4 @@ EXTENSION="${BASENAME##*.}" # exec highlight --force -f -I -X -S "$EXTENSION" 2>/dev/null # This is for version 3 -exec /usr/pkg/bin/highlight --force --inline-css -f -I -O xhtml -S "$EXTENSION" 2>/dev/null +exec /usr/pkg/bin/highlight --force -f -I -O xhtml -S "$EXTENSION" 2>/dev/null diff --git a/libexec/cgit/gruvbox.css b/libexec/cgit/gruvbox.css index 652c29f..0e5cf2f 100644 --- a/libexec/cgit/gruvbox.css +++ b/libexec/cgit/gruvbox.css @@ -170,3 +170,23 @@ div#cgit table.diffstat td.graph td.add { div#cgit table.diffstat td.graph td.rem { background: var(--red); } + +/************/ +/*** CODE ***/ +/************/ +body.hl { background-color: #e0eaee; } +pre.hl { color: #000000; background-color: #e0eaee; font-size:10pt; font-family:'Courier New',monospace;} +.hl.num { color: var(--purple); } +.hl.esc { color: var(--blue); } +.hl.str { color: var(--green); } +.hl.pps { color: var(--blue); } +.hl.slc { color: var(--gray); font-style:italic; } +.hl.com { color: var(--gray); font-style:italic; } +.hl.ppc { color: var(--blue-dim); } +.hl.opt { color: var(--fg1); } +.hl.ipl { color: var(--blue); } +.hl.lin { color: var(--gray-dim); } +.hl.kwa { color: var(--yellow); font-weight:bold; } +.hl.kwb { color: var(--blue); } +.hl.kwc { color: var(--blue); font-weight:bold; } +.hl.kwd { color: var(--yellow); } -- cgit v1.2.3