[imapfilter-devel] Re: More detailed control of output.
rnyman_imapfilter at afterburner.net
rnyman_imapfilter at afterburner.net
Sat Nov 6 05:20:27 EET 2004
Don't ask me how this message sat in a folder for so long, but I meant
to write you back and thank you for the information. As it turned out,
I needed to keep the output enabled to support another trick I
discovered, but it was good to see the trick.
I keep pretty large archive folders where I store old messages for a
period of time, but having the expiration be date based did not work for
me (I want it to be first in first out, even if the message is 2 months
old when it goes in. Also, my email is cyclical, while my archiving is
limited by storage space, so I want it to manage the mailbox to a set
number of messages).
x,y,z=check(an,'00archive')
if (x>9999) then
first={1,2,3,4,5,6,7,8,9,10}
delete(an,'00archive',first)
end
If the folder hits 10000 messages, the script will take the first 10
messages out of the folder and delete them. This assumes that the
script runs often enough that taking 10 messages at a time is enough to
manage the volume (if you have it run hourly, that's 240 messages per
day).
Alternatively, you can make the script loop by making it a while loop:
x,y,z=check(an,'00archive')
while (x>9999) do
first={1,2,3,4,5,6,7,8,9,10}
delete(an,'00archive',first)
x,y,z=check(an,'00archive')
end
Hope this helps others,
Rick
On Tue, 29 Jun 2004 11:55:01 -0500, "David DeSimone" <fox at verio.net>
said:
> Rick Nyman <rnyman_imapfilter at afterburner.net> wrote:
> >
> > On every poll cycle, I see this line in the log:
> > 906 messages, 0 recent, 0 unseen, in
> > harry.homeowner at hechingers.com/00archive.
> >
> > Is there any way to supress this output when I am setting a variable?
>
> I believe there is an options.info flag, which you can set to false, to
> avoid getting these reports.
>
> --
> David DeSimone || "It took me fifteen years to discover that I had no
> Network Admin || talent for writing, but I couldn't give it up because
> fox at verio.net || by that time I was too famous. -- Robert Benchley
>
More information about the Imapfilter-devel
mailing list