1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
#include "cgit.h"
#include "html.h"
#include "ui-empty.h"
#include "ui-shared.h"
static void print_clone_url(const char *url)
{
html("<tr><td class='clone-url'><a rel='vcs-git' href='");
html_url_path(url);
html("' title='");
html_attr(ctx.repo->name);
html(" Git repository'>");
html_txt(url);
html("</a></td></tr>\n");
}
void cgit_print_empty_repo(void)
{
cgit_print_error("Repository seems to be empty");
if (!ctx.repo->clone_url && !ctx.cfg.clone_prefix)
return;
html("<table class='list'>\n");
html("<tr class='nohover'><th class='left'>Clone</th></tr>\n");
cgit_add_clone_urls(print_clone_url);
html("</table>\n");
}
|