ref: 9383dc56718d09e7e92d5ff4347205d0767bf600
parent: 2eaed78b6ee38baba3d10dbef784a8642062d8aa
author: phil9 <[email protected]>
date: Sun Oct 24 10:29:37 EDT 2021
display committer when different from commit author git9 now makes a distinction between the author and the committer. Commit logs now reflect this by adding the committer name when it is different from the author.
--- a/common.rc
+++ b/common.rc
@@ -46,12 +46,15 @@
phash=$3
message=`{htcat $gitfs/object/$phash/msg | sed 1q}
- date=`{date -t `{mtime $gitfs/object/$phash/msg | awk '{print $1}'}}
+ date=`{date -f 'YYYY/MM/DD hh:mm' `{mtime $gitfs/object/$phash/msg | awk '{print $1}'}}
author=`"{htcat $gitfs/object/$phash/author | awk '{print $1}'}
shorthash=`{echo $phash | awk '{print substr($0, 0, 8)}'}
+ if (test -f $gitfs/object/$phash/committer) committer=`"{htcat $gitfs/object/$phash/committer | awk '{print $1}'}
echo ' <div id="commit">
<a href=/'$puser/$prepo/$phash'/commit.html>'$shorthash'</a>
- – '$author' – '$"date'
+ – '$author' authored'
+ if (! ~ $#committer 0 && ! ~ $committer $author) echo ' and '^$committer^' committed'
+ echo ' - '$"date'
<pre>'$"message'</pre>
</div>'
}