Re: Procmail

2007-10-12 Thread Rem P Roberti
On 2007.10.13 05:33:27 +, Chris Bannister wrote:
> On Tue, Oct 09, 2007 at 10:23:58AM -0700, Rem P Roberti wrote:
> > index.  Otherwise, how would one get the chance to reply?  Also, is it
> > possible to have the filtered messages placed in their respective
> > folders without all of the headers?
> 
> Maybe you want something like this in your .muttrc:
> 
> # What headers are displayed
> ignore *
> unignore From Date Subject To Cc User-agent
> 
> # What order the headers are displayed
> unhdr_order *
> hdr_order User-agent From Date To Cc Subject
> 
> All this is in the manual. If you press  from within mutt do you get
> the manual?
> 
> -- 
> Chris.
> ==

I have that hdr info in my .muttrc, and everything seems to be working
quite well right now.  I've been plugging away trying to learn all this
stuff, and it's slowly paying off.  Thanks for your help.  And, yes, 
does produce the manual.

Rem


Re: Procmail

2007-10-12 Thread Chris Bannister
On Tue, Oct 09, 2007 at 10:23:58AM -0700, Rem P Roberti wrote:
> index.  Otherwise, how would one get the chance to reply?  Also, is it
> possible to have the filtered messages placed in their respective
> folders without all of the headers?

Maybe you want something like this in your .muttrc:

# What headers are displayed
ignore *
unignore From Date Subject To Cc User-agent

# What order the headers are displayed
unhdr_order *
hdr_order User-agent From Date To Cc Subject

All this is in the manual. If you press  from within mutt do you get
the manual?

-- 
Chris.
==


Re: Procmail

2007-10-12 Thread Chris Bannister
On Tue, Oct 09, 2007 at 05:15:22PM -0600, Joseph wrote:
> If you have mbox it should be:
> :0:
> * ^From:[EMAIL PROTECTED]
> $HOME/Mail/user
> 
> If maildir:
> :0:
> * ^From:[EMAIL PROTECTED]
> $HOME/Mail/user/

For maildir, locking isn't needed, so the colon isn't needed after the
0, so:

:0
* ^From:[EMAIL PROTECTED]
$HOME/Mail/user/

would be correct.

-- 
Chris.
==


Re: Eporting from alias folder

2007-10-12 Thread Chris Bannister
On Mon, Oct 08, 2007 at 07:38:30AM -0700, Rem P Roberti wrote:
> On 2007.10.08 08:52:11 +, Chris Bannister wrote:
> > Of course you have:
> > 
> > macro index,pager A "abook --add-email" 
> > 
> > for new mail.
> > 
> > Consider using lbdb, set it up, then add:
> > 
> > set query_command = "lbdbq %s"
> > 
> > to your .muttrc
> > 
> > -- 
> > Chris.
> 
> Thanks for the info, Chris.  Abook is working for me, so I think that I
> will stay there.  But I have incorporated the macro you sent into my
> .muttrc.  Thanks again.

lbdb doesn't replace abook. :-)

(This is from an old Debian Sarge system.)

Package: lbdb
Priority: optional
Section: mail
Installed-Size: 384
Maintainer: Roland Rosenfeld <[EMAIL PROTECTED]>
Architecture: i386
Version: 0.29
Depends: libc6 (>= 2.3.2.ds1-4), perl
Suggests: mutt | mutt-ja, procmail, finger, abook, libpalm-perl, 
libnet-ldap-perl
Filename: pool/main/l/lbdb/lbdb_0.29_i386.deb
Size: 70622
MD5sum: 1cb9a7362fc6df15b69e7d920e8737cc
SHA1: 7dcd64fe41712bd2db5d6bfda0721ff345ba6486
SHA256: 5339f437cf8030c8e0f1723dcccbd6376cafc924496a48320d7f37234af5a6b9
Description: The little brother's database for the mutt mail reader
 This package consists of a set of small tools, which collect mail
 addresses from several sources and offer these addresses to the mutt
 external query feature. At the moment the following modules are
 supported:
  - m_finger (uses the finger(1) command)
  - m_inmail (scans incoming mail for addresses)
  - m_passwd (searches /etc/passwd)
  - m_yppasswd (searches the YP password database)
  - m_nispasswd (searches the NIS password database)
  - m_getent (searches the configured password database)
  - m_pgp2, m_pgp5, m_gpg (searches your PGP or GnuPG keyrings)
  - m_fido (searches the Fidonet nodelist)
  - m_abook (uses the address book application abook(1))
  - m_addr_email (uses addr-email from the addressbook Tk program)
  - m_muttalias (searches your Mutt mail aliases)
  - m_pine (searches your Pine addressbook files)
  - m_wanderlust (search the WanderLust alias database)
  - m_palm (uses your Palm database; needs libpalm-perl package)
  - m_gnomecard (uses GnomeCard database files)
  - m_bbdb (search your BBDB (big brother database))
  - m_ldap (query some LDAP server)
  - m_evolution (search in the Evolution addressbook)
 .
  Homepage: http://www.spinnaker.de/lbdb/

-- 
Chris.
==


Re: How to send a return receipt

2007-10-12 Thread Kyle Wheeler
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Friday, October 12 at 08:00 PM, quoth David Champion:
>>> The patch certainly provides better functionality than hooks, 
>>> macros, and scripts do, given the usual constraints.
>> 
>> I don't see what that missing functionality might be. Maybe I'm 
>> missing something.
>
> I didn't say "missing", I said "better".  I haven't said there's 
> anything fundamentally wrong with your approach; it's just not as -- as 
> you said -- convenient.
>
> But why is this an argument?

I guess I don't view convenience as "better functionality", but rather 
equal functionality. If I can bend mutt to do exactly the same thing 
two different ways, it's equal functionality, even if one requires 
more keystrokes. "Better" functionality implies that one performs 
faster/more-thoroughly/more-accurately/etc. than the other. But you're 
right, at this point, it doesn't matter: the OP has a multitude of 
ways of doing it. All that remains is to quibble about whether mutt's  
source should include code for functions that can be performed via 
hooks.

~Kyle
- -- 
To announce that there must be no criticism of the President, or that 
we are to stand by the President, right or wrong, is not only 
unpatriotic and servile, but is morally treasonable to the American 
public.
-- Theodore Roosevelt, 1912
-BEGIN PGP SIGNATURE-
Comment: Thank you for using encryption!

iD8DBQFHEEsrBkIOoMqOI14RApu7AJ9mhtGAXbGRGloWxOHFhjM9+VzjLwCeKzOw
HHNl7/+TONTk7HtdmHwOVts=
=wgVc
-END PGP SIGNATURE-


Re: hook \\.

2007-10-12 Thread David Ellement
On 2007-10-12, Joseph wrote
> I'm reading mutt manual and it has an example:
> 
> save-hook me@(turing\\.)?cs\\.hmc\\.edu$ +elkins
> save-hook aol\\.com$ +spam
> 
> Why there is a "\\."?
> I know singe backslash "\" turn off special meaning for "." 
> double backslash would indicate that it is a "\" character. 

The the muttrc file is read, the first backslash is removed, so the
send-hook then gets stored with the pattern having a single backslash.

-- 
David Ellement


Re: hook \\.

2007-10-12 Thread David Ellement
On 2007-10-12, I wrote
> On 2007-10-12, Joseph wrote
> > Why there is a "\\."?
> 
> The the muttrc file is read, the first backslash is removed, ...

My apologies to the list for posting this after Mr. Wheeler had posted a
much more informative reply.  Messages are getting delayed in a queue
here today, and it appeared to me that no one had yet replied after
several hours.

-- 
David Ellement


Re: How to send a return receipt

2007-10-12 Thread David Champion
> > The difficulty with this approach is that you don't want to send an MDN 
> > response any time you read the message, so you need to track whether the 
> > message has ever been read and MDN-replied to.  You can do this with 
> 
> What? Poppycock. If the New flag is insufficient (and I would argue it 
> *ought* to be sufficient), you can simply add a header to mark 
> messages by manipulating the $editor variable. For example:

So in other words, you're tracking whether the message has ever been
read.  I just named one way to do it; each has its merits.


> > The patch certainly provides better functionality than hooks, 
> > macros, and scripts do, given the usual constraints.
> 
> I don't see what that missing functionality might be. Maybe I'm 
> missing something.

I didn't say "missing", I said "better".  I haven't said there's
anything fundamentally wrong with your approach; it's just not as -- as
you said -- convenient.

But why is this an argument?

-- 
 -D.[EMAIL PROTECTED]NSITUniversity of Chicago
 "Polka music needs to prevail."   John Ziobrowski, Polka America Corporation


Re: hook \\.

2007-10-12 Thread Kyle Wheeler
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Friday, October 12 at 05:53 PM, quoth Joseph:
>I'm reading mutt manual and it has an example:
>
>save-hook me@(turing\\.)?cs\\.hmc\\.edu$ +elkins
>save-hook aol\\.com$ +spam
>
>Why there is a "\\."?
>I know singe backslash "\" turn off special meaning for "." 
>double backslash would indicate that it is a "\" character. 

It's because of mutt's sometimes inscrutable escaping rules. When mutt 
is reading something that isn't quoted, it strips off a level of 
escapes. So the following two lines are equivalent:

 save-hook [EMAIL PROTECTED] +elkins
 save-hook '[EMAIL PROTECTED]'  +elkins

The following two lines are ALSO equivalent:

 save-hook .  foo
 save-hook \. foo

The way mutt's parser works, first it extracts strings to match the 
pattern:

 save-hook string1 string2

Then, string1 is saved as the regular expression that triggers the 
hook, and string2 is saved as the command to run. Mutt un-escapes 
things when interpreting the rc file to extract string1, but the 
backslash has to survive and be present in the regular expression. 
Thus, unless you quote it, you have to use two backslashes.

Consider that you can also use octal escapes:

 save-hook [EMAIL PROTECTED] +elkins

When mutt interprets that, it will store string1 as "[EMAIL PROTECTED]". That 
way 
you can encode unusual characters into the muttrc (such as your $from 
or $realname) even if your muttrc can only be in us-ascii (for 
whatever reason).

~Kyle
- -- 
I think we ought always to entertain our opinions with some measure of 
doubt. I shouldn't wish people dogmatically to believe any philosophy, 
not even mine.
-- Bertrand Russell
-BEGIN PGP SIGNATURE-
Comment: Thank you for using encryption!

iD8DBQFHEBVABkIOoMqOI14RAqBHAKDTEF8bmiUD4QF/fn6964BmsDT9kwCgnf5y
CGsGDAnpFlAGZyz8hPTxLro=
=VQok
-END PGP SIGNATURE-


Re: How to send a return receipt

2007-10-12 Thread Kyle Wheeler
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Friday, October 12 at 03:06 PM, quoth David Champion:
>> Well, the first thing that springs to my mind is some sort of 
>> message-hook (since that's what triggers when you view a message).
>
> The difficulty with this approach is that you don't want to send an MDN 
> response any time you read the message, so you need to track whether the 
> message has ever been read and MDN-replied to.  You can do this with 
> formail -D, but that involves an external Message-ID cache, separate 
> from the message store, wherever that might be.

What? Poppycock. If the New flag is insufficient (and I would argue it 
*ought* to be sufficient), you can simply add a header to mark 
messages by manipulating the $editor variable. For example:

message-hook '~h Disposition-Notification-To: !~h X-Disposition-Sent:' 
'set my_pdecode=$pipe_decode; set my_editor=$editor; set 
editor="formail -a 'X-Disposition-Sent: yes'"; push 
"send-mdn.shset 
pipe_decode=$my_pdecodeset 
editor=$my_editor";'

Thus, any message that does not have an X-Disposition-Sent header is a 
message that you haven't sent a response to, and messages that DO have 
such a header won't trigger the macro.

The only thing that might muck with that hook is if using formail as 
the editor doesn't work (because it runs so quickly), in which case 
you'd have to wrap it in a one-line script.

> I suppose that's one reason that Werner chose to implement this as a 
> patch instead of as a set of macros/script(s).  But it might not be 
> compelling for everyone.

I think the reason he did it was because of convenience.

> The patch certainly provides better functionality than hooks, 
> macros, and scripts do, given the usual constraints.

I don't see what that missing functionality might be. Maybe I'm 
missing something.

~Kyle
- -- 
Nonsense. Space is blue and birds fly through it.
  -- Heisenberg
-BEGIN PGP SIGNATURE-
Comment: Thank you for using encryption!

iD8DBQFHEBK2BkIOoMqOI14RAlAaAJ9mOsCYoQSKb4jtzMGtMPfDMnKLngCg5i4U
ooTY65Ks0t46vCic/us4au8=
=O7++
-END PGP SIGNATURE-


hook \\.

2007-10-12 Thread Joseph
I'm reading mutt manual and it has an example:

save-hook me@(turing\\.)?cs\\.hmc\\.edu$ +elkins
save-hook aol\\.com$ +spam

Why there is a "\\."?
I know singe backslash "\" turn off special meaning for "." 
double backslash would indicate that it is a "\" character. 

-- 
#Joseph
GPG KeyID: ED0E1FB7


Re: How to send a return receipt

2007-10-12 Thread David Champion
> Well, the first thing that springs to my mind is some sort of 
> message-hook (since that's what triggers when you view a message).

The difficulty with this approach is that you don't want to send an MDN
response any time you read the message, so you need to track whether the
message has ever been read and MDN-replied to.  You can do this with
formail -D, but that involves an external Message-ID cache, separate
from the message store, wherever that might be.

I suppose that's one reason that Werner chose to implement this as a
patch instead of as a set of macros/script(s).  But it might not be
compelling for everyone.

The patch certainly provides better functionality than hooks, macros,
and scripts do, given the usual constraints.  Whether the better
functionality is necessary functionalty is debatable, but I'm not sure
it's worthwhile to debate it unless committers are wavering about
committing the patch.  Otherwise it's clear what you should do: patch
mutt if you're comfortable patching, or settle for scripts if they're
sufficient.

-- 
 -D.[EMAIL PROTECTED]NSITUniversity of Chicago
 "Polka music needs to prevail."   John Ziobrowski, Polka America Corporation


Re: How to send a return receipt

2007-10-12 Thread Joseph
On 10/12/07 20:22, Patrick Schoenfeld wrote:
[snip]

> Well, mutt can a lot but as I figured it does not support mail notificiation 
> as
> usual, but yes possibly there are ways to reach the goal of mail notifications
> anyway -- at least somewhat like that. The problem is that I actually don't 
> see
> a definitive way to do it, thats why I am asking it here.
> 
> > > E.g. is it possible somehow with macros to send out a specific
> > > template as the reply to a customer?
> >
> > Yes.
> 
> How? Any hint on appropriate docs would suffice.

Have a look at point 8.12 on this link:
http://www.animalgenome.org/SmartList/FAQ.html#Section_8.12

8.12: How to send an auto-reply back when someone posts?

-- 
#Joseph
GPG KeyID: ED0E1FB7


Re: How to send a return receipt

2007-10-12 Thread Kyle Wheeler
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Friday, October 12 at 02:03 PM, quoth Kyle Wheeler:
> message-hook '~h Disposition-Notification-To:' \
> 'send-mdn.sh'

On considering, I think this would actually be better written:

 message-hook '~N ~h Disposition-Notification-To:' \
 'set my_pdecode=$pipe_decode; set pipe_decode=no;
 push "send-mdn.shset 
pipe_decode=$my_pdecode";'

~Kyle
- -- 
Backups are for wimps. Real men upload their data to an FTP site and 
have everyone else mirror it.
  -- Linus Torvalds
-BEGIN PGP SIGNATURE-
Comment: Thank you for using encryption!

iD8DBQFHD8byBkIOoMqOI14RAhKuAJ9M1dYLXZl8jkeEwMRrZzNqK1ZpAgCfRTQz
02bmtcgKX5df/fnUEqfpkGs=
=o25u
-END PGP SIGNATURE-


Re: How to send a return receipt

2007-10-12 Thread Kyle Wheeler
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Friday, October 12 at 08:22 PM, quoth Patrick Schoenfeld:
>>> E.g. is it possible somehow with macros to send out a specific 
>>> template as the reply to a customer?
>>
>> Yes.
>
> How? Any hint on appropriate docs would suffice.

Oh, come on, the "appropriate docs" would be the *mutt* documentation, 
of course! Can we possibly ask a more vague or open-ended question?

Check out the -H and -i flags that can be passed to mutt. They allow 
you to make mutt send a specific file... or you can pipe a file into 
mutt's stdin, and that should work as well (kinda like /bin/mail).

~Kyle
- -- 
It is dangerous to be right when the government is wrong.
-- Voltaire
-BEGIN PGP SIGNATURE-
Comment: Thank you for using encryption!

iD8DBQFHD8XEBkIOoMqOI14RAiCqAKC7uJ1uDvOSTW64FA/rdbjR6kHuqgCeNWGa
5ZxxwQ1aAz0jlee+gAy8gKs=
=duil
-END PGP SIGNATURE-


Re: How to send a return receipt

2007-10-12 Thread Kyle Wheeler
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Friday, October 12 at 08:22 PM, quoth Patrick Schoenfeld:
> Well, mutt can a lot but as I figured it does not support mail 
> notificiation as usual, but yes possibly there are ways to reach the 
> goal of mail notifications anyway -- at least somewhat like that. 
> The problem is that I actually don't see a definitive way to do it, 
> thats why I am asking it here.

Well, the first thing that springs to my mind is some sort of 
message-hook (since that's what triggers when you view a message).

 message-hook '~h Disposition-Notification-To:' 'do-something'

The question then becomes: what should "do-something" be in that hook? 
Well, it can easily be a script of some sort, and that script could 
ask the user "do you want to send a disposition notification?" and act 
on the response. The only tricky part is getting that script to know 
who the notification should be sent to, and any other details of the 
message that it needs to know to generate the notification (I haven't 
read RFC 2298 thoroughly, so I don't know what all needs to be sent). 
It seems to me that you'd need a full copy of the message... so what 
the message-hook would need to do is something like this:

 message-hook '~h Disposition-Notification-To:' \
 'send-mdn.sh'

Then, of course, you'd need to write send-mdn.sh to parse the message, 
pull out the required headers and other data, generate a response, and 
send it (possibly calling mutt to do so).

I've never played with MDNs before, so I don't know what you'd need, 
but my guess is that in that script you can simply use formail (or 
DJB's 822field utility) to extract all the relevant headers, prompt 
the user as necessary, and so forth.

Is that helpful?

~Kyle
- -- 
Unthinking respect for authority is the greatest enemy of truth.
 -- Albert Einstein
-BEGIN PGP SIGNATURE-
Comment: Thank you for using encryption!

iD8DBQFHD8UABkIOoMqOI14RAqx/AKCqasd3+vHxsUwoYEUP4/zmNVORhgCfXWTM
fhnxBPqNilUyJFY2pf9DFX8=
=K8wC
-END PGP SIGNATURE-


Re: How to send a return receipt

2007-10-12 Thread Rado S
=- Patrick Schoenfeld wrote on Fri 12.Oct'07 at 20:22:41 +0200 -=

> On Fri, Oct 12, 2007 at 05:04:22PM +0200, Rado S wrote:
> > Why not?
> > What is it different from what you're looking for?
> 
> a lot of extra effort is the difference. You cannot really compare
> sending a return receipt with sending a mail, where a r->"got it"
> really isn't enough.
> {...}
> possibly there are ways to reach the goal of mail notifications
> anyway -- at least somewhat like that.

Why isn't it enough? Technically it's the same as a simple reply, no?!
For the "extra effort" you have macros.
"Technically possible" and "easy to get by or use" are 2 different
things.

> > > E.g. is it possible somehow with macros to send out a specific
> > > template as the reply to a customer?
> 
> How? Any hint on appropriate docs would suffice.

You could first picture the process of sending a mail with mutt,
then you might find some spots to hook in.
Tweaking $editor and/or $sendmail can help, either a script or macro
in your editor to setup the auto-response.

-- 
© Rado S. -- You must provide YOUR effort for your goal!
EVERY effort counts: at least to show your attitude.
You're responsible for ALL you do: you get what you give.


Re: How to send a return receipt

2007-10-12 Thread Patrick Schoenfeld
Hi,

On Fri, Oct 12, 2007 at 05:04:22PM +0200, Rado S wrote:
> Why not?
> What is it different from what you're looking for?

a lot of extra effort is the difference. You cannot really compare sending  a
return receipt with sending a mail, where a r->"got it" really isn't enough.

> Mutt can do that to, since you can configure much inside and around
> it to to achieve almost anything you need. You just have to do it
> yourself.  And I don't mean source code hacks.

Well, mutt can a lot but as I figured it does not support mail notificiation as
usual, but yes possibly there are ways to reach the goal of mail notifications
anyway -- at least somewhat like that. The problem is that I actually don't see
a definitive way to do it, thats why I am asking it here.

> > E.g. is it possible somehow with macros to send out a specific
> > template as the reply to a customer?
>
> Yes.

How? Any hint on appropriate docs would suffice.

Regards,

Patrick


Re: How to send a return receipt

2007-10-12 Thread Rado S
=- Patrick Schoenfeld wrote on Thu 11.Oct'07 at 20:53:41 +0200 -=

> > Simply send a regular reply: "Seen and will do it."
> 
> Thanks for the "advice", but this ain't a solution.

Why not?
What is it different from what you're looking for?

=- Patrick Schoenfeld wrote on Fri 12.Oct'07 at 12:33:00 +0200 -=

> All the mail clients I know (besides mutt) support it.

Mutt can do that to, since you can configure much inside and around
it to to achieve almost anything you need. You just have to do it
yourself.  And I don't mean source code hacks.

> E.g. is it possible somehow with macros to send out a specific
> template as the reply to a customer?

Yes.

-- 
© Rado S. -- You must provide YOUR effort for your goal!
EVERY effort counts: at least to show your attitude.
You're responsible for ALL you do: you get what you give.


Re: pattern aliases

2007-10-12 Thread Michael Hendricks
On Thu, Oct 11, 2007 at 11:29:17PM -0400, [EMAIL PROTECTED] wrote:
> Thus spake Michael Hendricks [10/11/07 @ 21.19.15 -0600]:
> > I'd like to put something like this in my .muttrc
> > 
> > pattern_alias foo (~f example.org | ~f sample.com) ~s foo !~s
> > PATCH
> > 
> > and then just limit my messages to the pattern "foo".  Is something
> > similar possible?
> 
> I just tried this:
> 
> macro editor *foo "some stuff here"
> 
> and it expanded after I hit 'l' for limit.  Maybe that's not so
> elegant, but it seems to work just fine.

That works great.  Thank you for the suggestion.

-- 
Michael


Re: How to send a return receipt

2007-10-12 Thread Patrick Schoenfeld
Hi,

On Thu, Oct 11, 2007 at 01:23:13PM -0600, Charles Cazabon wrote:
> The concept of mail receipts is poorly designed; there is no way to implement

I agree, if you look at whats given by the aspect of a evidence in law terms
but it is practical if it is part of a given process between people. In our
case it is even a big plus to have it. It saves us a lot of time, and helps
defining a clear process between us and some of our customers. So sure it is
not a reliable sign if someone got a mail, but it is enough to be more worth
then just marketing blubb.

> *Many* of the better mail packages therefore do not implement support
> for it -- why have a feature if you *know* it can never work properly?

Whatever you define as *better* mail packages -- I don't know them then. All
the mail clients I know (besides mutt) support it. And its far from beeing
perfect, but in some situations it helps. So this is the reason.

But lets not discuss this anymore, because it is a discussion with no consense
in sight. Maybe its possible to find a solution that helps me anyway. E.g. is
it possible somehow with macros to send out a specific template as the reply to
a customer? I can use colored headers to notify me about the return receipt
question so there is no bigger problem with that, if I could send a
confirmation email by just a key press.

> It's also seen as an invasion of privacy.

Sorry, but I can't take that for serious.

Best Regards,

Patrick