From 6545f22667272df9f4484d5cfe2c2b10380fe9c1 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Paul=20H=C3=A4nsch?= Date: Thu, 27 Jul 2023 09:33:35 +0200 Subject: [PATCH] show diff of original language version on revisions page --- macros/revisions | 60 ++++++++++++++++++++++++++++++++++++++++++---- themes/default.css | 12 ++++++++++ 2 files changed, 67 insertions(+), 5 deletions(-) diff --git a/macros/revisions b/macros/revisions index 4271149..75440d6 100755 --- a/macros/revisions +++ b/macros/revisions @@ -4,16 +4,44 @@ . "$_EXEC/tools.sh" . "$_EXEC/acl.sh" -page="$1" +LIST=true DIFF= +while [ $# -gt 0 ]; do case $1 in + --list) + LIST=true + shift 1 + ;; + --no-list) + LIST= + shift 1 + ;; + --diff) + DIFF=true + shift 1 + ;; + --no-diff) + DIFF= + shift 1 + ;; + *)page="$1" + shift 1 + ;; +esac; done + page_abs="$(page_abs "$page")" +page_default="${page_abs%:*/}" if ! acl_read "$page_abs"; then return 0 -elif [ "$REV_PAGES" != true ]; then - printf '
GIT is not available to handle revisioning.
' fi -printf '