Re: [Exim] .forward question

Etusivu
Poista viesti
Vastaa
Lähettäjä: Philip Hazel
Päiväys:  
Vastaanottaja: Richard Reynolds
Kopio: exim-users
Aihe: Re: [Exim] .forward question
On Fri, 4 May 2001, Richard Reynolds wrote:

> Ive been looking and have not found a place for this yet. so im asking
> is there a way to put into the .forward file a destination folder based on the
> date the email was sent so i can have a folder like this, i would not want it to
> be recieved, unless there is no way around that.


In a filter file, you can use the expansion features such as substr to
extract the date from the Date: header.

>            \weekof 4-30-01


However, the value won't be in that format. If you want to base it on
the current time, you can get that out of several Exim variables, for
example, $tod_log. Use a command something like

save /some/file/${substr_x_y:$tod_log}

where x and y are the offset and length for extracting the part of the
date you want. Use "exim -be" to test your expansion.

-- 
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.