blob: b5d4aba79e8d23ed174d6e2424fe4b0c655c2e9a (plain)
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
/*
 * The branch and tag listings of a repository. The two section printers write
 * rows into a table the caller has already opened, which is how the summary
 * page carries a short version of each above its recent log.
 */

#ifndef CGIT_UI_REFS_H
#define CGIT_UI_REFS_H

// The name, the commit message or downloads, the author and the age.
#define REF_COLUMNS 4

/*
 * Rows for the newest branches or tags, at most maxcount of them, where a
 * maxcount of zero means every one. A section that leaves refs out ends in a
 * link to the matching form of the refs page. columns is the width of the
 * table the rows go into, which is at least REF_COLUMNS.
 */
extern void cgit_print_branches(int maxcount, int columns);
extern void cgit_print_tags(int maxcount, int columns);

/*
 * The whole refs page. Without a path it holds a capped section of each kind,
 * and with a path of heads or tags it becomes a page of that one kind alone,
 * walked an offset at a time.
 */
extern void cgit_print_refs(void);

#endif // CGIT_UI_REFS_H