3 . "$_EXEC/cgilite/cgilite.sh"
8 page_abs="$(page_abs "$page")"
10 if ! acl_read "$page_abs"; then
12 elif [ ! "$(which git)" ]; then
13 printf '<div class="macro revisions error">GIT is not available to handle revisioning.</div>'
16 printf '<ul class="macro revisions">'
18 git -C "$_DATA" log --date=format:"%a, %x %H:%M" \
19 --pretty=format:"%h %cd %s%n" \
20 -- "pages${page_abs}#page.md" \
21 | while read hash date message; do
22 user="${message% @*}"; user="${user##*@ }"
23 printf '<a href="%s"><span class="hash">%s</span><span="date">%s</span><span class="user">%s</span></a>' \
24 "$(HTML "${page%/}/[revisions]/$hash")" "$(HTML "$hash")" "$(HTML "$date")" "$(HTML "$user")"