X-Git-Url: https://gitweb.ps.run/ps-cgit/blobdiff_plain/61c3ca978c586c673aec618cb94210657278dda8..5ec6e02bd1cc0c05b7cfd0d53371e7d176daec39:/ui-view.c diff --git a/ui-view.c b/ui-view.c index 9d23c45..dbe4b29 100644 --- a/ui-view.c +++ b/ui-view.c @@ -8,7 +8,7 @@ #include "cgit.h" -void cgit_print_view(const char *hex) +void cgit_print_view(const char *hex, char *path) { unsigned char sha1[20]; enum object_type type; @@ -34,8 +34,20 @@ void cgit_print_view(const char *hex) buf[size] = '\0'; html("
| %s %s, %li bytes |
|---|
| "); + if (path) + htmlf("%s (", path); + htmlf("%s %s, %li bytes", typename(type), hex, size); + if (path) + html(")"); + + html(" download"); + html(" |
| \n"); html_txt(buf); html("\n |