SARG ChangeLog
-Nov-20-2010 Version 2.3.2-pre1
+Nov-21-2010 Version 2.3.2-pre1
- Add support for sorttable.js (http://www.kryogenix.org/code/browser/sorttable/) to dynamically sort some tables (thanks to Éric).
+ - Add the two command line options --lastlog and --keeplogs to set the number of reports to keep or to keep all the reports respectively (thanks to Emmanuel Lacour for the suggestion).
Sep-18-2010 Version 2.3.1
- Remove the distinct printf for the alpha architecture as it doesn't work anymore and is not necessary anyway.
int maxdate=0;
int iarq=0;
int isa_ncols=0,isa_cols[ISACOL_Last];
+ int lastlog=-1;
bool from_stdin;
bool from_pipe;
int blen;
{
{"convert",no_argument,&convert,1},
{"css",no_argument,&output_css,1},
+ {"lastlog",required_argument,NULL,2},
+ {"keeplogs",no_argument,NULL,3},
{"split",no_argument,&split,1},
{0,0,0,0}
};
{
case 0:
break;
+ case 2:
+ lastlog=atoi(optarg);
+ break;
+ case 3:
+ lastlog=0;
+ break;
case 'a':
strcpy(addr,optarg);
break;
if(dns) Ip2Name=true;
+ if (lastlog>=0) LastLog=lastlog;
+
if(realt) {
realtime();
exit(EXIT_SUCCESS);
debuga(_(" Temporary dir (-w) = %s\n"),tmp);
debuga(_(" Debug messages (-x) = %s\n"),(debug) ? _("Yes") : _("No"));
debuga(_(" Process messages (-z) = %s\n"),(debugz) ? _("Yes") : _("No"));
+ debuga(_(" Previous reports to keep (--lastlog) = %d\n"),LastLog);
debuga("\n");
}
printf(_(" Temporary dir (-w) = %s\n"),tmp);
printf(_(" Debug messages (-x) = %s\n"),(debug) ? _("Yes") : _("No"));
printf(_(" Process messages (-z) = %s\n"),(debugz) ? _("Yes") : _("No"));
+ printf(_(" Previous reports to keep (--lastlog) = %d\n"),LastLog);
printf(_("sarg version: %s\n"),VERSION);
}
.RE
.RE
.PP
+\fB\-\-keeplogs\fR
+.RS 4
+Don\'t delete any old report\&. It is equivalent to setting
+\fB\-\-lastlog 0\fR
+but is provided for convenience\&.
+.RE
+.PP
\fB\-l \fR\fB\fIfilename\fR\fR
.RS 4
Uses
option\&. It allows the use of wildcards on the command line\&. Make sure you don\'t exceed the limit of 255 files\&.
.RE
.PP
+\fB\-\-lastlog \fR\fB\fIn\fR\fR
+.RS 4
+Limit the number of logs kept in the output directory to
+\fIn\fR\&. Any supernumerary report is deleted starting with the oldest report\&. The value of
+\fIn\fR
+must be positive or zero\&. A value of zero means no report should be deleted\&.
+.RE
+.PP
\fB\-L \fR\fB\fIfilename\fR\fR
.RS 4
Reads a proxy redirector log file such as one created by
</listitem>
</varlistentry>
+<varlistentry><term><option>--keeplogs</option></term>
+<listitem>
+<para>
+Don't delete any old report. It is equivalent to setting <option>--lastlog 0</option> but is
+provided for convenience.
+</para>
+</listitem>
+</varlistentry>
+
<varlistentry><term><option>-l <replaceable>filename</replaceable></option></term>
<listitem>
<para>
</listitem>
</varlistentry>
+<varlistentry><term><option>--lastlog <replaceable>n</replaceable></option></term>
+<listitem>
+<para>
+Limit the number of logs kept in the output directory to <replaceable>n</replaceable>. Any supernumerary report
+is deleted starting with the oldest report. The value of <replaceable>n</replaceable> must be positive or zero.
+A value of zero means no report should be deleted.
+</para>
+</listitem>
+</varlistentry>
+
<varlistentry><term><option>-L <replaceable>filename</replaceable></option></term>
<listitem>
<para>