Added the "48h" criterion and some clarifications in the man page.
authorFrancois Fleuret <francois@fleuret.org>
Wed, 13 Feb 2013 20:25:12 +0000 (21:25 +0100)
committerFrancois Fleuret <francois@fleuret.org>
Wed, 13 Feb 2013 20:25:12 +0000 (21:25 +0100)
mymail.1
mymail.c

index b6edee0..e0f89f1 100644 (file)
--- a/mymail.1
+++ b/mymail.1
@@ -83,6 +83,9 @@ space and a regexp, which can itself contain spaces. If the condition
 is prefaced by the character "!" it is negated, and has to be false
 for a mail to be selected.
 
 is prefaced by the character "!" it is negated, and has to be false
 for a mail to be selected.
 
+The time-based condition use as reference the time indicated in the
+heading From line, and not in the Date: field.
+
 .TP
 \fBf <regexp>\fR (from)
 selects mails whose leading line From, or fields From:, Sender:,
 .TP
 \fBf <regexp>\fR (from)
 selects mails whose leading line From, or fields From:, Sender:,
@@ -106,9 +109,9 @@ condition requires to read the original mboxes completely, which can
 be slow. However, header conditions are checked first to read the
 bodies only for mails which fulfill them entirely.
 .TP
 be slow. However, header conditions are checked first to read the
 bodies only for mails which fulfill them entirely.
 .TP
-\fB8h\fR, \fBtoday\fR, \fB24h\fR, \fBweek\fR, \fBmonth\fR, and
+\fB8h\fR, \fBtoday\fR, \fB24h\fR, \fB48h\fR, \fBweek\fR, \fBmonth\fR, and
 \fByear\fR
 \fByear\fR
-selects mails received during the last 8, 24, 24, 7 * 24 hours, 31 *
+selects mails received during the last 8, 24, 24, 48, 7 * 24 hours, 31 *
 24 hours, and 365 * 24 hours respectively.
 .TP
 \fByesterday\fR
 24 hours, and 365 * 24 hours respectively.
 .TP
 \fByesterday\fR
index 3718157..6e3f5cc 100644 (file)
--- a/mymail.c
+++ b/mymail.c
@@ -704,6 +704,7 @@ static struct time_criterion time_criteria[] = {
   { "8h",         8,       -1, -1 },
   { "today",     24,       -1, -1 },
   { "24h",       24,       -1, -1 },
   { "8h",         8,       -1, -1 },
   { "today",     24,       -1, -1 },
   { "24h",       24,       -1, -1 },
+  { "48h",       48,       -1, -1 },
   { "week",      24 *   7, -1, -1 },
   { "month",     24 *  31, -1, -1 },
   { "year",      24 * 365, -1, -1 },
   { "week",      24 *   7, -1, -1 },
   { "month",     24 *  31, -1, -1 },
   { "year",      24 * 365, -1, -1 },