]> git.cameronkatri.com Git - cgit.git/blob - ui-shared.h
cache.c: fix header order
[cgit.git] / ui-shared.h
1 #ifndef UI_SHARED_H
2 #define UI_SHARED_H
3
4 #include <stdbool.h>
5
6 extern const char *cgit_httpscheme();
7 extern const char *cgit_hosturl();
8 extern const char *cgit_rooturl();
9 extern const char *cgit_currenturl();
10 extern const char *cgit_loginurl();
11 extern char *cgit_repourl(const char *reponame);
12 extern char *cgit_fileurl(const char *reponame, const char *pagename,
13 const char *filename, const char *query);
14 extern char *cgit_pageurl(const char *reponame, const char *pagename,
15 const char *query);
16
17 extern void cgit_add_clone_urls(void (*fn)(const char *));
18
19 extern void cgit_index_link(const char *name, const char *title,
20 const char *class, const char *pattern, const char *sort, int ofs, int always_root);
21 extern void cgit_summary_link(const char *name, const char *title,
22 const char *class, const char *head);
23 extern void cgit_tag_link(const char *name, const char *title,
24 const char *class, const char *tag);
25 extern void cgit_tree_link(const char *name, const char *title,
26 const char *class, const char *head,
27 const char *rev, const char *path);
28 extern void cgit_plain_link(const char *name, const char *title,
29 const char *class, const char *head,
30 const char *rev, const char *path);
31 extern void cgit_log_link(const char *name, const char *title,
32 const char *class, const char *head, const char *rev,
33 const char *path, int ofs, const char *grep,
34 const char *pattern, int showmsg, int follow);
35 extern void cgit_commit_link(char *name, const char *title,
36 const char *class, const char *head,
37 const char *rev, const char *path);
38 extern void cgit_patch_link(const char *name, const char *title,
39 const char *class, const char *head,
40 const char *rev, const char *path);
41 extern void cgit_refs_link(const char *name, const char *title,
42 const char *class, const char *head,
43 const char *rev, const char *path);
44 extern void cgit_snapshot_link(const char *name, const char *title,
45 const char *class, const char *head,
46 const char *rev, const char *archivename);
47 extern void cgit_diff_link(const char *name, const char *title,
48 const char *class, const char *head,
49 const char *new_rev, const char *old_rev,
50 const char *path);
51 extern void cgit_stats_link(const char *name, const char *title,
52 const char *class, const char *head,
53 const char *path);
54 extern void cgit_object_link(struct object *obj);
55
56 extern void cgit_submodule_link(const char *class, char *path,
57 const char *rev);
58
59 __attribute__((format (printf,1,2)))
60 extern void cgit_print_error(const char *fmt, ...);
61 __attribute__((format (printf,1,0)))
62 extern void cgit_vprint_error(const char *fmt, va_list ap);
63 extern void cgit_print_date(time_t secs, const char *format, int local_time);
64 extern void cgit_print_age(time_t t, time_t max_relative, const char *format);
65 extern void cgit_print_http_headers(void);
66 extern void cgit_redirect(const char *url, bool permanent);
67 extern void cgit_print_docstart(void);
68 extern void cgit_print_docend();
69 extern void cgit_print_pageheader(void);
70 extern void cgit_print_filemode(unsigned short mode);
71 extern void cgit_print_snapshot_links(const char *repo, const char *head,
72 const char *hex, int snapshots);
73 extern void cgit_add_hidden_formfields(int incl_head, int incl_search,
74 const char *page);
75 #endif /* UI_SHARED_H */