From 2e7c3ac45bff0ea85843faef6dbc2038509b5e7b Mon Sep 17 00:00:00 2001 From: Xiao Pan Date: Mon, 26 Feb 2024 08:56:44 +0000 Subject: feat: pacman hook upgrade highlight.css for cgit syntax highlighting --- etc/pacman.d/hooks/highlight-css.hook | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 etc/pacman.d/hooks/highlight-css.hook (limited to 'etc') diff --git a/etc/pacman.d/hooks/highlight-css.hook b/etc/pacman.d/hooks/highlight-css.hook new file mode 100644 index 00000000..e3411b7b --- /dev/null +++ b/etc/pacman.d/hooks/highlight-css.hook @@ -0,0 +1,14 @@ +[Trigger] +Type = Package +Operation = Install +Operation = Upgrade +Target = highlight + +[Action] +Description = Upgrade highlight.css for cgit syntax highlighting... +When = PostTransaction +# mycgit.css import this highlight.css and cgit.css, for syntax-highlighting-edited.sh +# because cgit.css is not pacman backup file and will be overwritten when upgrade cgit +Exec = /usr/bin/highlight -O xhtml --print-style -o /usr/share/webapps/cgit/highlight.css +Depends = highlight +Depends = cgit -- cgit v1.2.3-70-g09d2