cgit

commit e9a7042b5b44c6af2c7dc91eabed732d92278218

Author: Lars Hjemli <hjemli@gmail.com>

Make a few more columns in repolist and log view clickable

Less mouse movement is nice.

Signed-off-by: Lars Hjemli <hjemli@gmail.com>

 ui-log.c | 5 +++++
 ui-repolist.c | 2 ++


diff --git a/ui-log.c b/ui-log.c
index 9b2ffb68d8b088b3f396d1d12f741a626af495b8..746f40bbaf8a5bd2d3f2c07abd0290b971ae452b 100644
--- a/ui-log.c
+++ b/ui-log.c
@@ -34,10 +34,15 @@
 void print_commit(struct commit *commit)
 {
 	struct commitinfo *info;
+	char *tmp;
 
 	info = cgit_parse_commit(commit);
 	html("<tr><td>");
+	tmp = fmt("id=%s", sha1_to_hex(commit->object.sha1));
+	tmp = cgit_pageurl(ctx.repo->url, "commit", tmp);
+	html_link_open(tmp, NULL, NULL);
 	cgit_print_age(commit->date, TM_WEEK * 2, FMT_SHORTDATE);
+	html_link_close();
 	html("</td><td>");
 	cgit_commit_link(info->subject, NULL, NULL, ctx.qry.head,
 			 sha1_to_hex(commit->object.sha1));




diff --git a/ui-repolist.c b/ui-repolist.c
index 7a7e95aa6f0e34ff1294eeaeeb8daa7035ded865..98009c019b497d4c4b5d4ec58dc5186fa03cac5c 100644
--- a/ui-repolist.c
+++ b/ui-repolist.c
@@ -114,7 +114,9 @@ 		html_link_open(cgit_repourl(ctx.repo->url), NULL, NULL);
 		html_txt(ctx.repo->name);
 		html_link_close();
 		html("</td><td>");
+		html_link_open(cgit_repourl(ctx.repo->url), NULL, NULL);
 		html_ntxt(ctx.cfg.max_repodesc_len, ctx.repo->desc);
+		html_link_close();
 		html("</td><td>");
 		html_txt(ctx.repo->owner);
 		html("</td><td>");