722fa8395dd01afd14f42077ef8a348d40b8bc62
[citadel.git] / ctdlsh / ctdlsh.h
1 /*
2  * main header file for ctdlsh
3  *
4  * Copyright (c) 2009-2013 by the citadel.org team
5  * This program is open source software, cheerfully made available to
6  * you under the terms of the GNU General Public License version 3.
7  */
8
9 #include <stdlib.h>
10 #include <unistd.h>
11 #include <stdio.h>
12 #include <signal.h>
13 #include <sys/types.h>
14 #include <sys/time.h>
15 #include <sys/socket.h>
16 #include <sys/un.h>
17 #include <string.h>
18 #include <pwd.h>
19 #include <time.h>
20 #include <errno.h>
21 #include <stdarg.h>
22 #include <fcntl.h>
23 #include <errno.h>
24 #include <readline/readline.h>
25
26 /*
27  * Set to the location of Citadel
28  * FIXME this needs to be configurable
29  */
30 #ifndef CTDLDIR
31 #define CTDLDIR "/usr/local/citadel"
32 #endif
33
34 typedef int ctdlsh_cmdfunc_t(int, char *);
35
36 enum ctdlsh_cmdfunc_return_values {
37         cmdret_ok,
38         cmdret_exit,
39         cmdret_error
40 };
41
42 int cmd_help(int, char *);
43 int cmd_quit(int, char *);
44 int cmd_datetime(int, char *);
45 int cmd_passwd(int, char *);
46 int cmd_shutdown(int, char *);
47 int cmd_who(int, char *);
48 int cmd_export(int, char *);