version 1.13, 2005/04/12 14:58:40 |
version 1.14, 2005/05/24 04:12:25 |
|
|
|
|
#define CVS_HF_EXCL (CVS_HF_C|CVS_HF_E|CVS_HF_M|CVS_HF_O|CVS_HF_T|CVS_HF_X) |
#define CVS_HF_EXCL (CVS_HF_C|CVS_HF_E|CVS_HF_M|CVS_HF_O|CVS_HF_T|CVS_HF_X) |
|
|
static void cvs_history_print (struct cvs_hent *); |
static int cvs_history_init (struct cvs_cmd *, int, char **, int *); |
int cvs_history_options(char *, int, char **, int *); |
static void cvs_history_print (struct cvs_hent *); |
int cvs_history_sendflags(struct cvsroot *); |
static int cvs_history_pre_exec (struct cvsroot *); |
|
|
extern char *__progname; |
extern char *__progname; |
|
|
struct cvs_cmd_info cvs_history = { |
struct cvs_cmd cvs_cmd_history = { |
cvs_history_options, |
CVS_OP_HISTORY, CVS_REQ_HISTORY, "history", |
cvs_history_sendflags, |
{ "hi", "his" }, |
|
"Show repository access history", |
|
"", |
|
"acelm:oTt:u:wx:z:", |
NULL, |
NULL, |
|
0, |
|
cvs_history_init, |
|
cvs_history_pre_exec, |
NULL, |
NULL, |
NULL, |
NULL, |
0, |
NULL, |
CVS_REQ_HISTORY, |
NULL, |
CVS_CMD_SENDDIR |
CVS_CMD_SENDDIR |
}; |
}; |
|
|
|
|
static u_int rep = 0; |
static u_int rep = 0; |
static char *modules[CVS_HISTORY_MAXMOD]; |
static char *modules[CVS_HISTORY_MAXMOD]; |
|
|
int |
static int |
cvs_history_options(char *opt, int argc, char **argv, int *arg) |
cvs_history_init(struct cvs_cmd *cmd, int argc, char **argv, int *arg) |
{ |
{ |
int ch; |
int ch; |
|
|
while ((ch = getopt(argc, argv, opt)) != -1) { |
while ((ch = getopt(argc, argv, cmd->cmd_opts)) != -1) { |
switch (ch) { |
switch (ch) { |
case 'a': |
case 'a': |
flags |= CVS_HF_A; |
flags |= CVS_HF_A; |
|
|
return (0); |
return (0); |
} |
} |
|
|
int |
static int |
cvs_history_sendflags(struct cvsroot *root) |
cvs_history_pre_exec(struct cvsroot *root) |
{ |
{ |
|
|
if ((flags & CVS_HF_C) && (cvs_sendarg(root, "-c", 0) < 0)) |
if ((flags & CVS_HF_C) && (cvs_sendarg(root, "-c", 0) < 0)) |