[lwatch-cvs] files/src lwatch.conf,1.23,1.24 settings.c,1.27,1.28 settings.h,1.10,1.11 yparse.l,1.24
Brought to you by:
arturcz
|
From: Artur R. C. <ar...@us...> - 2004-08-10 09:02:20
|
Update of /cvsroot/lwatch/files/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv27813/src Modified Files: lwatch.conf settings.c settings.h yparse.l Log Message: Code cleaning: - removed all references to create_fifo - fixed output of lwatch -h when compiled with terminal resizing support - stub for show_configure_options Index: settings.c =================================================================== RCS file: /cvsroot/lwatch/files/src/settings.c,v retrieving revision 1.27 retrieving revision 1.28 diff -C2 -d -r1.27 -r1.28 *** settings.c 12 Jan 2004 21:23:18 -0000 1.27 --- settings.c 10 Aug 2004 09:02:10 -0000 1.28 *************** *** 86,89 **** --- 86,93 ---- } + void show_configure_options() { + printf("\nCompiled with some weird ./configure options\n"); + } + void show_usage() { int i; *************** *** 98,112 **** " -o, --output filename", "\twrite colored logs into filename instead of " DEF_OUT_FILE ",", - /* - " -c, --create-fifo", - "\tcreate fifo if does not exist", - */ " -s, --show-unparsed", ! "\tshows unparsed lines (like `last message repeated X times')", ! " -O, --omit-rc", #ifdef RESIZE " -t, --term-cut", ! "\tCut lines to terminal width", #endif "\tdo not read values from config file", " -h, --help", --- 102,112 ---- " -o, --output filename", "\twrite colored logs into filename instead of " DEF_OUT_FILE ",", " -s, --show-unparsed", ! "\tshow unparsed lines (like `last message repeated X times')", #ifdef RESIZE " -t, --term-cut", ! "\tcut lines to terminal width", #endif + " -O, --omit-rc", "\tdo not read values from config file", " -h, --help", *************** *** 128,132 **** {"input",1,0,'i'}, {"output",1,0,'o'}, - {"create-fifo",0,0,'c'}, {"show-unparsed",0,0,'s'}, {"omit-rc",0,0,'O'}, --- 128,131 ---- *************** *** 138,141 **** --- 137,141 ---- }; int idx,c; + int version=0; /* char *pc; //what I needed it for? */ *************** *** 147,151 **** #endif memset(&lw_conf,0,sizeof(lw_conf)); ! while((c=getopt_long(argc,argv,"vC:f:i:co:Osht",opt,&idx))!=EOF) { switch(c) { case 'C': --- 147,151 ---- #endif memset(&lw_conf,0,sizeof(lw_conf)); ! while((c=getopt_long(argc,argv,"vC:f:i:o:Osht",opt,&idx))!=EOF) { switch(c) { case 'C': *************** *** 183,192 **** } break; - case 'c': - lw_conf.create_fifo=1; - #ifdef DEBUG - fprintf(stderr,"Create fifo if doesn't exist\n"); - #endif - break; case 's': lw_conf.show_unparsed=1; --- 183,186 ---- Index: lwatch.conf =================================================================== RCS file: /cvsroot/lwatch/files/src/lwatch.conf,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -d -r1.23 -r1.24 *** lwatch.conf 10 Aug 2004 08:32:17 -0000 1.23 --- lwatch.conf 10 Aug 2004 09:02:10 -0000 1.24 *************** *** 28,35 **** output_file=/dev/tty11 - # NOT SUPPORTED IN THIS RELEASE! - # create_fifo=no - # NOT SUPPORTED IN THIS RELEASE! - # What to do with unparsed lines like: # Mar 21 15:45:06 musashi -- MARK -- --- 28,31 ---- Index: settings.h =================================================================== RCS file: /cvsroot/lwatch/files/src/settings.h,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** settings.h 11 Jan 2004 23:22:11 -0000 1.10 --- settings.h 10 Aug 2004 09:02:10 -0000 1.11 *************** *** 38,44 **** char in_file[MAXPATHLEN+1]; char out_file[MAXPATHLEN+1]; - int create_fifo; int show_unparsed; int term_cut; }; --- 38,45 ---- char in_file[MAXPATHLEN+1]; char out_file[MAXPATHLEN+1]; int show_unparsed; + #ifdef RESIZE int term_cut; + #endif }; Index: yparse.l =================================================================== RCS file: /cvsroot/lwatch/files/src/yparse.l,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -d -r1.24 -r1.25 *** yparse.l 20 Jan 2004 20:55:34 -0000 1.24 --- yparse.l 10 Aug 2004 09:02:10 -0000 1.25 *************** *** 72,76 **** %option noyywrap nounput ! M_KEYWORD input_fifo|input_file|output_file|create_fifo|show_unparsed R_KEYCOLOR date_color|host_color|serv_color|mesg_color|color|highlight R_KEYWORD match_service|match_host|ignore|exit --- 72,76 ---- %option noyywrap nounput ! M_KEYWORD input_fifo|input_file|output_file|show_unparsed R_KEYCOLOR date_color|host_color|serv_color|mesg_color|color|highlight R_KEYWORD match_service|match_host|ignore|exit *************** *** 120,130 **** PUSH(TEXT); } - <INITIAL>create_fifo= { - yyip=&lw_conf.create_fifo; - #ifdef DEBUG - strcpy(mymsg,"create_fifo"); - #endif - PUSH(BOOLEAN); - } <INITIAL>show_unparsed= { yyip=&lw_conf.show_unparsed; --- 120,123 ---- |