|
diff --git a/cgit.h b/cgit.h index d9a15f4..f8f0316 100644 --- a/ cgit.h+++ b/ cgit.h |
|
@@ -143,132 +143,134 @@ extern int cgit_cache_repo_ttl; |
143 | extern int cgit_cache_dynamic_ttl; |
143 | extern int cgit_cache_dynamic_ttl; |
144 | extern int cgit_cache_static_ttl; |
144 | extern int cgit_cache_static_ttl; |
145 | extern int cgit_cache_max_create_time; |
145 | extern int cgit_cache_max_create_time; |
146 | extern int cgit_summary_log; |
146 | extern int cgit_summary_log; |
147 | extern int cgit_summary_tags; |
147 | extern int cgit_summary_tags; |
148 | extern int cgit_summary_branches; |
148 | extern int cgit_summary_branches; |
149 | |
149 | |
150 | extern int cgit_max_msg_len; |
150 | extern int cgit_max_msg_len; |
151 | extern int cgit_max_repodesc_len; |
151 | extern int cgit_max_repodesc_len; |
152 | extern int cgit_max_commit_count; |
152 | extern int cgit_max_commit_count; |
153 | |
153 | |
154 | extern int cgit_query_has_symref; |
154 | extern int cgit_query_has_symref; |
155 | extern int cgit_query_has_sha1; |
155 | extern int cgit_query_has_sha1; |
156 | |
156 | |
157 | extern char *cgit_querystring; |
157 | extern char *cgit_querystring; |
158 | extern char *cgit_query_repo; |
158 | extern char *cgit_query_repo; |
159 | extern char *cgit_query_page; |
159 | extern char *cgit_query_page; |
160 | extern char *cgit_query_search; |
160 | extern char *cgit_query_search; |
161 | extern char *cgit_query_head; |
161 | extern char *cgit_query_head; |
162 | extern char *cgit_query_sha1; |
162 | extern char *cgit_query_sha1; |
163 | extern char *cgit_query_sha2; |
163 | extern char *cgit_query_sha2; |
164 | extern char *cgit_query_path; |
164 | extern char *cgit_query_path; |
165 | extern char *cgit_query_name; |
165 | extern char *cgit_query_name; |
166 | extern int cgit_query_ofs; |
166 | extern int cgit_query_ofs; |
167 | |
167 | |
168 | extern int htmlfd; |
168 | extern int htmlfd; |
169 | |
169 | |
170 | extern int cgit_get_cmd_index(const char *cmd); |
170 | extern int cgit_get_cmd_index(const char *cmd); |
171 | extern struct repoinfo *cgit_get_repoinfo(const char *url); |
171 | extern struct repoinfo *cgit_get_repoinfo(const char *url); |
172 | extern void cgit_global_config_cb(const char *name, const char *value); |
172 | extern void cgit_global_config_cb(const char *name, const char *value); |
173 | extern void cgit_repo_config_cb(const char *name, const char *value); |
173 | extern void cgit_repo_config_cb(const char *name, const char *value); |
174 | extern void cgit_querystring_cb(const char *name, const char *value); |
174 | extern void cgit_querystring_cb(const char *name, const char *value); |
175 | |
175 | |
176 | extern int chk_zero(int result, char *msg); |
176 | extern int chk_zero(int result, char *msg); |
177 | extern int chk_positive(int result, char *msg); |
177 | extern int chk_positive(int result, char *msg); |
178 | extern int chk_non_negative(int result, char *msg); |
178 | extern int chk_non_negative(int result, char *msg); |
179 | |
179 | |
180 | extern int hextoint(char c); |
180 | extern int hextoint(char c); |
181 | extern char *trim_end(const char *str, char c); |
181 | extern char *trim_end(const char *str, char c); |
182 | |
182 | |
183 | extern void cgit_add_ref(struct reflist *list, struct refinfo *ref); |
183 | extern void cgit_add_ref(struct reflist *list, struct refinfo *ref); |
184 | extern int cgit_refs_cb(const char *refname, const unsigned char *sha1, |
184 | extern int cgit_refs_cb(const char *refname, const unsigned char *sha1, |
185 | int flags, void *cb_data); |
185 | int flags, void *cb_data); |
186 | |
186 | |
187 | extern void *cgit_free_commitinfo(struct commitinfo *info); |
187 | extern void *cgit_free_commitinfo(struct commitinfo *info); |
188 | |
188 | |
189 | extern int cgit_diff_files(const unsigned char *old_sha1, |
189 | extern int cgit_diff_files(const unsigned char *old_sha1, |
190 | const unsigned char *new_sha1, |
190 | const unsigned char *new_sha1, |
191 | linediff_fn fn); |
191 | linediff_fn fn); |
192 | |
192 | |
193 | extern void cgit_diff_tree(const unsigned char *old_sha1, |
193 | extern void cgit_diff_tree(const unsigned char *old_sha1, |
194 | const unsigned char *new_sha1, |
194 | const unsigned char *new_sha1, |
195 | filepair_fn fn, const char *prefix); |
195 | filepair_fn fn, const char *prefix); |
196 | |
196 | |
197 | extern void cgit_diff_commit(struct commit *commit, filepair_fn fn); |
197 | extern void cgit_diff_commit(struct commit *commit, filepair_fn fn); |
198 | |
198 | |
199 | extern char *fmt(const char *format,...); |
199 | extern char *fmt(const char *format,...); |
200 | |
200 | |
201 | extern void html(const char *txt); |
201 | extern void html(const char *txt); |
202 | extern void htmlf(const char *format,...); |
202 | extern void htmlf(const char *format,...); |
203 | extern void html_txt(char *txt); |
203 | extern void html_txt(char *txt); |
204 | extern void html_ntxt(int len, char *txt); |
204 | extern void html_ntxt(int len, char *txt); |
205 | extern void html_attr(char *txt); |
205 | extern void html_attr(char *txt); |
206 | extern void html_hidden(char *name, char *value); |
206 | extern void html_hidden(char *name, char *value); |
207 | extern void html_link_open(char *url, char *title, char *class); |
207 | extern void html_link_open(char *url, char *title, char *class); |
208 | extern void html_link_close(void); |
208 | extern void html_link_close(void); |
209 | extern void html_filemode(unsigned short mode); |
209 | extern void html_filemode(unsigned short mode); |
210 | extern int html_include(const char *filename); |
210 | extern int html_include(const char *filename); |
211 | |
211 | |
212 | extern int cgit_read_config(const char *filename, configfn fn); |
212 | extern int cgit_read_config(const char *filename, configfn fn); |
213 | extern int cgit_parse_query(char *txt, configfn fn); |
213 | extern int cgit_parse_query(char *txt, configfn fn); |
214 | extern struct commitinfo *cgit_parse_commit(struct commit *commit); |
214 | extern struct commitinfo *cgit_parse_commit(struct commit *commit); |
215 | extern struct taginfo *cgit_parse_tag(struct tag *tag); |
215 | extern struct taginfo *cgit_parse_tag(struct tag *tag); |
216 | extern void cgit_parse_url(const char *url); |
216 | extern void cgit_parse_url(const char *url); |
217 | |
217 | |
218 | extern char *cache_safe_filename(const char *unsafe); |
218 | extern char *cache_safe_filename(const char *unsafe); |
219 | extern int cache_lock(struct cacheitem *item); |
219 | extern int cache_lock(struct cacheitem *item); |
220 | extern int cache_unlock(struct cacheitem *item); |
220 | extern int cache_unlock(struct cacheitem *item); |
221 | extern int cache_cancel_lock(struct cacheitem *item); |
221 | extern int cache_cancel_lock(struct cacheitem *item); |
222 | extern int cache_exist(struct cacheitem *item); |
222 | extern int cache_exist(struct cacheitem *item); |
223 | extern int cache_expired(struct cacheitem *item); |
223 | extern int cache_expired(struct cacheitem *item); |
224 | |
224 | |
225 | extern char *cgit_repourl(const char *reponame); |
225 | extern char *cgit_repourl(const char *reponame); |
226 | extern char *cgit_fileurl(const char *reponame, const char *pagename, |
226 | extern char *cgit_fileurl(const char *reponame, const char *pagename, |
227 | const char *filename, const char *query); |
227 | const char *filename, const char *query); |
228 | extern char *cgit_pageurl(const char *reponame, const char *pagename, |
228 | extern char *cgit_pageurl(const char *reponame, const char *pagename, |
229 | const char *query); |
229 | const char *query); |
230 | |
230 | |
231 | extern const char *cgit_repobasename(const char *reponame); |
231 | extern const char *cgit_repobasename(const char *reponame); |
232 | |
232 | |
233 | extern void cgit_tree_link(char *name, char *title, char *class, char *head, |
233 | extern void cgit_tree_link(char *name, char *title, char *class, char *head, |
234 | char *rev, char *path); |
234 | char *rev, char *path); |
235 | extern void cgit_log_link(char *name, char *title, char *class, char *head, |
235 | extern void cgit_log_link(char *name, char *title, char *class, char *head, |
236 | char *rev, char *path, int ofs); |
236 | char *rev, char *path, int ofs); |
237 | extern void cgit_commit_link(char *name, char *title, char *class, char *head, |
237 | extern void cgit_commit_link(char *name, char *title, char *class, char *head, |
238 | char *rev); |
238 | char *rev); |
| |
239 | extern void cgit_refs_link(char *name, char *title, char *class, char *head, |
| |
240 | char *rev, char *path); |
239 | extern void cgit_snapshot_link(char *name, char *title, char *class, |
241 | extern void cgit_snapshot_link(char *name, char *title, char *class, |
240 | char *head, char *rev, char *archivename); |
242 | char *head, char *rev, char *archivename); |
241 | extern void cgit_diff_link(char *name, char *title, char *class, char *head, |
243 | extern void cgit_diff_link(char *name, char *title, char *class, char *head, |
242 | char *new_rev, char *old_rev, char *path); |
244 | char *new_rev, char *old_rev, char *path); |
243 | |
245 | |
244 | extern void cgit_object_link(struct object *obj); |
246 | extern void cgit_object_link(struct object *obj); |
245 | |
247 | |
246 | extern void cgit_print_error(char *msg); |
248 | extern void cgit_print_error(char *msg); |
247 | extern void cgit_print_date(time_t secs, char *format); |
249 | extern void cgit_print_date(time_t secs, char *format); |
248 | extern void cgit_print_age(time_t t, time_t max_relative, char *format); |
250 | extern void cgit_print_age(time_t t, time_t max_relative, char *format); |
249 | extern void cgit_print_docstart(char *title, struct cacheitem *item); |
251 | extern void cgit_print_docstart(char *title, struct cacheitem *item); |
250 | extern void cgit_print_docend(); |
252 | extern void cgit_print_docend(); |
251 | extern void cgit_print_pageheader(char *title, int show_search); |
253 | extern void cgit_print_pageheader(char *title, int show_search); |
252 | extern void cgit_print_snapshot_start(const char *mimetype, |
254 | extern void cgit_print_snapshot_start(const char *mimetype, |
253 | const char *filename, |
255 | const char *filename, |
254 | struct cacheitem *item); |
256 | struct cacheitem *item); |
255 | extern void cgit_print_branches(int maxcount); |
257 | extern void cgit_print_branches(int maxcount); |
256 | extern void cgit_print_tags(int maxcount); |
258 | extern void cgit_print_tags(int maxcount); |
257 | |
259 | |
258 | extern void cgit_print_repolist(struct cacheitem *item); |
260 | extern void cgit_print_repolist(struct cacheitem *item); |
259 | extern void cgit_print_summary(); |
261 | extern void cgit_print_summary(); |
260 | extern void cgit_print_log(const char *tip, int ofs, int cnt, char *grep, char *path, int pager); |
262 | extern void cgit_print_log(const char *tip, int ofs, int cnt, char *grep, char *path, int pager); |
261 | extern void cgit_print_blob(struct cacheitem *item, const char *hex, char *path); |
263 | extern void cgit_print_blob(struct cacheitem *item, const char *hex, char *path); |
262 | extern void cgit_print_tree(const char *rev, char *path); |
264 | extern void cgit_print_tree(const char *rev, char *path); |
263 | extern void cgit_print_commit(char *hex); |
265 | extern void cgit_print_commit(char *hex); |
264 | extern void cgit_print_refs(); |
266 | extern void cgit_print_refs(); |
265 | extern void cgit_print_tag(char *revname); |
267 | extern void cgit_print_tag(char *revname); |
266 | extern void cgit_print_diff(const char *new_hex, const char *old_hex, const char *prefix); |
268 | extern void cgit_print_diff(const char *new_hex, const char *old_hex, const char *prefix); |
267 | extern void cgit_print_snapshot(struct cacheitem *item, const char *head, |
269 | extern void cgit_print_snapshot(struct cacheitem *item, const char *head, |
268 | const char *hex, const char *prefix, |
270 | const char *hex, const char *prefix, |
269 | const char *filename, int snapshot); |
271 | const char *filename, int snapshot); |
270 | extern void cgit_print_snapshot_links(const char *repo, const char *head, |
272 | extern void cgit_print_snapshot_links(const char *repo, const char *head, |
271 | const char *hex, int snapshots); |
273 | const char *hex, int snapshots); |
272 | extern int cgit_parse_snapshots_mask(const char *str); |
274 | extern int cgit_parse_snapshots_mask(const char *str); |
273 | |
275 | |
274 | #endif /* CGIT_H */ |
276 | #endif /* CGIT_H */ |
|