summary refs log tree commit diff stats
path: root/gemlog.h
blob: 841e914e387e8b007292e1642b377b5bd578c46d (plain) (blame)
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
#define GEMLOG_TITLE_FILENAME "title"
#define GEMLOG_CONTENT_FILENAME "content.gmi"
#define GEMLOG_CONTENT_HTML_FILENAME "content.html"

struct gemlog_entry {
	char *title;
	struct tm date;
	struct gemtext **content;
};

/* strlcpy.c/strlcat.c */
#undef strlcpy
#undef strlcat
size_t strlcpy(char *, const char *, size_t);
size_t strlcat(char *, const char *, size_t);

/* gemlog.c */
struct gemlog_entry **gemlog_readdir(const char *);

/* html.c */
int gemlog_write_html(struct gemlog_entry **, const char *);

/* index_gmi.c */
int gemlog_write_index(struct gemlog_entry **, const char *);

/* index_html.c */
int gemlog_write_html_index(struct gemlog_entry **, const char *);

/* atom.c */
int gemlog_write_atom(struct gemlog_entry **, const char *);

/* free.c */
void gemlog_entry_free(struct gemlog_entry *);
void gemlog_entry_list_free(struct gemlog_entry **);