Getting current folder name

2001-07-26 Thread Kai Weber

Hi,

I am searching for a way to get the current selected folder for
scripting. I want something like this:

folder-hook .  source $MATCHED_FOLDER.rc

Depending on what folder I entered, I want to know what folder that
was. Maybe storing the wohle path in a shell variable, something like
that.

Kai.
-- 
k a i  w e b e r  | mailto:[EMAIL PROTECTED]
   w w w  | http://www.glorybox.de/



MTA trying to deliver to all options

2001-07-26 Thread Erika Pacholleck

I did not change my mutt(.5i) version and compiled it like
I did before. Suddenly I am having problems with mutts passing
the deliver command to my MTA.
I have this problem with masqmail and with postfix

Both say the same thing, the MTA is trying to deliver mail
to all options passed by mutt when sending a local mail
from/to testusers erika@localhost/albert@localhost:

maqmail daemon-notify:
Delivery to the following recipients failed
 <[EMAIL PROTECTED]>
 <[EMAIL PROTECTED]>
 <[EMAIL PROTECTED]>
 <[EMAIL PROTECTED]>
 <[EMAIL PROTECTED]>
 <[EMAIL PROTECTED]>
 <[EMAIL PROTECTED]>
 <[EMAIL PROTECTED]>
 <[EMAIL PROTECTED]>

postfix-log lines:
qmgr[]: 9236422F44: from=<[EMAIL PROTECTED]>, size=455, nrcpt=11 (queue active)
qmgr[]: 9236422F44: to=<[EMAIL PROTECTED]>, relay=none, delay=0, 
status=bounced (invalid recipient syntax: "[EMAIL PROTECTED]")
qmgr[]: 9236422F44: to=<[EMAIL PROTECTED]>, accordingly
qmgr[]: 9236422F44: to=<[EMAIL PROTECTED]>, accordingly
qmgr[]: 9236422F44: to=<[EMAIL PROTECTED]>, accordingly
qmgr[]: 9236422F44: to=<[EMAIL PROTECTED]>, accordingly
qmgr[]: 9236422F44: to=<[EMAIL PROTECTED]>, accordingly

What am I missing in my muttrc to make that work correctly?
Thanks

Erika



Re: MTA trying to deliver to all options

2001-07-26 Thread Suresh Ramasubramanian

Erika Pacholleck [mutt-users] <26/07/01 13:43 +0200>: 
> Both say the same thing, the MTA is trying to deliver mail
> to all options passed by mutt when sending a local mail
> from/to testusers erika@localhost/albert@localhost:
 
 Masqmail seems to hate the dsn_notify and dsn_return lines in your muttrc

> qmgr[]: 9236422F44: to=<[EMAIL PROTECTED]>, accordingly
> qmgr[]: 9236422F44: to=<[EMAIL PROTECTED]>, accordingly

 Or the sendmail-command might be misconfigured.

-- 
Suresh Ramasubramanian + Wallopus Malletus Indigenensis
mallet @ cluestick.org + Lumber Cartel of India, tinlcI
EMail Sturmbannfuhrer, Lower Middle Class Unix Sysadmin



Re: Getting current folder name

2001-07-26 Thread Greg Matheson

On Thu, 26 Jul 2001, Kai Weber wrote:

> Hi,

> I am searching for a way to get the current selected folder for
> scripting. I want something like this:

> folder-hook .  source $MATCHED_FOLDER.rc

> Depending on what folder I entered, I want to know what folder that
> was. 

While you're doing that, find out what the name of the
currently-edited (or last edited) message is ;-)

That is to say, I don't think you can do that. These would have
to be environmental variables set by mutt, and I don't think mutt
sets any of these. 

However, you can use "-" to return to the previous folder on the
 command, so perhaps you could use that in .muttrc,
like you can use "!" to set mailboxes.


-- 
Greg MathesonThere is nothing as good as a 
Chinmin College, practical theory.
Taiwan   --Kurt Lewin's practicality maxim corollary



Re: Copy command

2001-07-26 Thread Michael Tatge

Chris Fuchs muttered:
> Actually all I wanted to do was to save a message as a file
> with a filename that I would get prompted for and not into
> a directory.  I'm using the MH style mailboxes.

So set mbox_type=mbox before you save.
Since you can't make this into a single macro I splitted it up to two:

# toggle mbox_type
macro generic  'set mbox_type="mbox"\
  echo "mbox_type now mbox"' "save to mbox"
macro generic  'set mbox_type="Maildir"\
  echo "mbox_type now Maildir"' "save to Maildir"

s/Maildir/MH/g for your purpose.

HTH,

Michael
-- 
"Are [Linux users] lemmings collectively jumping off of the cliff of
reliable, well-engineered commercial software?"
(By Matt Welsh)

PGP-Key: http://www-stud.ims.uni-stuttgart.de/~tatgeml/public.key



Browser.c

2001-07-26 Thread Nelson D. Guerrero

Good (morning/afternoon/everning),

 I've been wanting, for a long time now, to view in my browser only the
 folders I have specified in my muttrc like when you run mutt with -y or
 like when you press . I was looking into browser.c and started
 editting (without having any knowledge whatsoever in c) to see if I
 could in fact put it that way. Well, the only thing I managed was
 putting 'Mut Mailboxes [2]' permanentlly. I was wondering if someone
 that has done it before could help me out with this, or at least point
 me in some direction. Maybe this should go in mutt-dev instead of
 mutt-users. Well, that's a shot. 

Thanks in advanced.

---
Nelson D. Guerrero Email: [EMAIL PROTECTED]
Soporte TecnicoWWW  : http://www.tcn.com.do  
Telecable Nacional Tel  : (809) 542 - 6612 ext. 4018
División de Internet




Re: Setting xterm title according to mbox name

2001-07-26 Thread Peter Kovacs

On Wed, Jul 18, 2001 at 03:14:28PM +0200, Gregor Hoffleit wrote:
> echo -ne "\033]2;MUTT - $MBOX\007" 1>&2
> 
> I started with a "folder-hook . source ~/bin/mutt-xtitle" where
> mutt-xtitle was a shell script with a command like the one above. That
> somehow worked, but I haven't found any way to detect the name of the
> mbox that's currently opened, and to pass this name to the shell script.

I think I may have found a solution for this idea.  I patched mx.c to
set the current folder in the environment (attached).  Then I created a
script which does something similar:

#!/bin/sh
echo -ne  "\033]2;MUTT - $MUTTMAILBOX\007"

However, I couldn't get a folder-hook like the one you suggest to work.
Instead I had to do:

folder-hook . 'push !~/bin/mutt-xterm-title\n'

Is there a better way to do that?  Unfortunately that interferes with
the typing of my imap password.  I don't like storing the password in
the configuration file, but at least it works.

- Peter

-- 
Peter D. Kovacs <[EMAIL PROTECTED]>
Software Developer
Webmachines, Inc. http://webmachines.com


--- mx.c~   Thu Jul 26 10:37:37 2001
+++ mx.cThu Jul 26 10:40:19 2001
@@ -727,6 +727,9 @@
   }
 
   unset_option (OPTFORCEREFRESH);
+
+  setenv("MUTTMAILBOX", path, 1 );
+
   return (ctx);
 }
 

 PGP signature


Re: Browser.c

2001-07-26 Thread Greg Matheson

On Thu, 26 Jul 2001, Nelson D. Guerrero wrote:

>  I've been wanting, for a long time now, to view in my browser
>  only the folders I have specified in my muttrc like when you
>  run mutt with -y or like when you press . 

That's the function of the mailbox screen, which is already
there. Do you want to tear out the browser? 

>  I was looking into browser.c and started editting (without
>  having any knowledge whatsoever in c) to see if I could in
>  fact put it that way. 

While you are hacking away, try to make the mailbox screen
hierarchical like the Unix directory structure is. That is, can
you make it so you have one set of mailboxes in one screen and
another set in another screen? ;-) If these mailboxes have to be in
different directories that is OK.  

I have 125 students and I have one mailbox for each of their
individual lists of their mail their penpals, and another for the
error messages from each of these lists. I think there are more I
can't remember at the moment. They are also in class groups with
different maillists. That makes more than 300 mailboxes. I don't
want to work with limits in the index screen. But there are too
many mailboxes for the mailbox screen! 

At the moment I have wrappers around mutt that rewrite the .muttrc
mailboxes line for each of these three groups of mailbox, as well
as writing macros to work through the mailbox screen. And I open
three separate instances of mutt.

But the amount of perl I learned doing this was phenomenal. And
they are still difficult to use. What I want is to have a key
like change folders in the index screen. You can use this to
change from one mailfolder to another. But instead what I want to
do is change mailbox screens. I then can move around in a
separate set of mailboxes.

Think what it would be like without directories in Unix.
Everything would be all messed up. Or think about having all of
your mail in one folder. The single mailbox screen has the same
problem. The 3-deep hierarchy of mutt is too limiting. 
Three levels of Unix directories would not be enough. The
3-level mailbox-index-pager classification also needs to be
extended at the top end.


-- 
Greg Matheson   Learn a third language and 
Chinmin College,be born again, again.
Taiwan 



Re: Setting xterm title according to mbox name

2001-07-26 Thread Peter Kovacs

On Thu, Jul 26, 2001 at 10:44:21AM -0400, Peter Kovacs wrote:
> On Wed, Jul 18, 2001 at 03:14:28PM +0200, Gregor Hoffleit wrote:
> > ... but I haven't found any way to detect the name of the
> > mbox that's currently opened, and to pass this name to the shell script.
> 
> I think I may have found a solution for this idea.  I patched mx.c to
> set the current folder in the environment (attached).  

Attached is a (slightly) better patch that only sets the environment
when folder_hook is called.

-Peter

-- 
Peter D. Kovacs <[EMAIL PROTECTED]>
Software Developer
Webmachines, Inc. http://webmachines.com


--- hook.c~ Thu Jul 26 11:48:09 2001
+++ hook.c  Thu Jul 26 11:47:08 2001
@@ -274,6 +274,8 @@
   BUFFER err, token;
   char buf[STRING];
 
+  setenv( "MUTTMAILBOX", path, 1 );
+
   current_hook_type = M_FOLDERHOOK;
   
   err.data = buf;

 PGP signature


Re: Getting current folder name

2001-07-26 Thread Louis LeBlanc

You might get what you are looking for from Gregor Hoffleit's patch in
a message posted earlier today.  I will attach it at the end.

L
On 07/26/01 11:44 AM, Kai Weber sat at the `puter and typed:
> Hi,
> 
> I am searching for a way to get the current selected folder for
> scripting. I want something like this:
> 
> folder-hook .  source $MATCHED_FOLDER.rc
> 
> Depending on what folder I entered, I want to know what folder that
> was. Maybe storing the wohle path in a shell variable, something like
> that.
> 
> Kai.
> -- 
> k a i  w e b e r  | mailto:[EMAIL PROTECTED]
>w w w  | http://www.glorybox.de/
> 

-- 
Louis LeBlanc   [EMAIL PROTECTED]
Fully Funded Hobbyist, KeySlapper Extrordinaire :)
http://acadia.ne.mediaone.net ԿԬ

QOTD:
  "Sure, I turned down a drink once.  Didn't understand the question."




On Wed, Jul 18, 2001 at 03:14:28PM +0200, Gregor Hoffleit wrote:
> echo -ne "\033]2;MUTT - $MBOX\007" 1>&2
> 
> I started with a "folder-hook . source ~/bin/mutt-xtitle" where
> mutt-xtitle was a shell script with a command like the one above. That
> somehow worked, but I haven't found any way to detect the name of the
> mbox that's currently opened, and to pass this name to the shell script.

I think I may have found a solution for this idea.  I patched mx.c to
set the current folder in the environment (attached).  Then I created a
script which does something similar:

#!/bin/sh
echo -ne  "\033]2;MUTT - $MUTTMAILBOX\007"

However, I couldn't get a folder-hook like the one you suggest to work.
Instead I had to do:

folder-hook . 'push !~/bin/mutt-xterm-title\n'

Is there a better way to do that?  Unfortunately that interferes with
the typing of my imap password.  I don't like storing the password in
the configuration file, but at least it works.

- Peter

-- 
Peter D. Kovacs <[EMAIL PROTECTED]>
Software Developer
Webmachines, Inc. http://webmachines.com


--- mx.c~   Thu Jul 26 10:37:37 2001
+++ mx.cThu Jul 26 10:40:19 2001
@@ -727,6 +727,9 @@
   }
 
   unset_option (OPTFORCEREFRESH);
+
+  setenv("MUTTMAILBOX", path, 1 );
+
   return (ctx);
 }
 

 PGP signature



~ trying to Install Mutt-1.3.20 from tar.gz downloaded

2001-07-26 Thread tabanna


Dear Mutt-Users,

 After doing ./configure  I am getting the message that


 ~ have already Installed 

If  is, indeed, the correct version, then,
What, please, do I need to do ?

Thanks

--


best wishes



sent on Linux





new 'to_chars' flag? (talking to oneself)

2001-07-26 Thread Chris Fuchs

Hi,

I used to mixed text files amongst my email messages prior to
using mutt and still do so, although I wonder whether there is a
better way.  Basically I use this as a means of storing notes and
other tidbits related to mail received around the same general time.
Obviously this is using mutt in a manner for which it wasn't
designed and there are arguments for and against it - which I
would like to solicit (being new to mutt and not familiar with
the relevant RFCs):

1) Right now I send myself a blank email.  This ends up in my spool
mailbox after which I edit it, leaving the header intact except for
the Subject:, and then save it in the appropriate mailbox/maildir; ie,
the From: and To: fields both have my address.  This works but is
ugly.  I would rather not have to bother the mail server.

2) An alternative, which I haven't yet gotten to work yet would be
to create a template text file with a header which has my address
in both the From: and To: fields and then get it into mutt by using
"cat textfile | procmail".  I could make a macro out of this - but
it is still butt ugly.  Right now when I save to something other
than the spool mailbox the resultant time displayed for the message
in the index menu is 'Jan 1'.

3) An extension to the 'alternates' configuration variable in which
'to_chars' would have another flag say 'M' which can stand for memo,
message, etc.  The flag turns on when mutt detects that the From: and
the To: field contain your address but all other fields are blank
(ie Cc:, Bcc:, Fcc: etc). In response mutt would go to a new
configuration variable which would contain a string that it would
display as the receipient - if not set it would just show the default
"To ".  Was this already considered when
'to_chars' was set up?  If so what's the background?

Adding this feature would require more than meets the eye - I'm not
up enough on mutt to know precisely what... has anyone's bloat
detector gone off yet?  Does anyone else do something like this?

Chris

--
   "To ask the hard question is simple. -W. H. Auden




my_hdr and fcc-hook

2001-07-26 Thread Thomas Huemmler

Hi mutt users,

I´ve got a problem with "my_hdr From:" and "fcc-hook". If "my_hdr From:"
is set, Mutt doesn´t produce a Fcc-Line. Is this a bug? 
I´ve consulted google and the mutt-user-archive on mutt.org, but
didn´t find an answer. 
I am using "Mutt 1.2.5i (2000-07-28)" on Debian potato.

Is there any workaround?

tia
thomas

-- 
Thomas Hümmler * mailto:[EMAIL PROTECTED] * http://www.huemmler.de
REDAKTIONSBÜRO T.O.M. * Gsprait 1 * D-85560 Ebersberg
Phone: +49 (0 80 92) 8 38 33 Fax: +49 (0 80 92) 8 38 34
* am Kiosk: CHIP Linux-Spezial: KDE 2.1.1 für SuSE, Red HAT, Debian *



Re: my_hdr and fcc-hook

2001-07-26 Thread Cedric Duval

* Thomas Huemmler <[EMAIL PROTECTED]> [07/27/01 00:23]:
> I´ve got a problem with "my_hdr From:" and "fcc-hook". If "my_hdr From:"
> is set, Mutt doesn´t produce a Fcc-Line. Is this a bug?

Looks like no fcc-hook is matching your mail.
What are your fcc-hooks like? If they just use a simple regexp (i.e.
without '~'), then they are evaluated according to the 'default-hook'
variable.

The default for default-hook is
  "~f %s !~P | (~P ~C %s)"
^^^

As it uses ~P, perhaps you haven't correctly set your 'alternates'
variable?

HTH,
Cedric.



Re: About quoting text, about emacs.

2001-07-26 Thread Jens Paulus

On Wed, Jul 25, 2001 at 11:40:11PM -0400, Walt Mankowski wrote:
> ;; Automatically go into mail-mode if filename starts with /tmp/mutt
> (setq auto-mode-alist (append (list (cons "^\/tmp\/mutt" 'mail-mode))
>   auto-mode-alist))
[...]
> (add-hook 'mail-mode-hook 'my-mail-mode-hook)
> 
> (defun my-mail-mode-hook ()
>   (auto-fill-mode)
> )

What you suggest is quite okay. Thank you.

-Jens






Re: About quoting text, about emacs.

2001-07-26 Thread Jens Paulus

On Thu, Jul 26, 2001 at 12:12:11AM -0500, David Champion wrote:
> What if there were a merge-components function in the compose menu,
> such that you could tag 2 or more components ("attachments"), call this
> function, and have those tagged components merged as one?
> 
> Would this (a) solve the immediate problem, and (b) be more generally
> useful?

I think there is usually no need to merge components/attachments. Just
because I sometimes want to quote from another message I don't think
it's worth adding such a function to mutt for me. Maybe it's good enough
to save the other message to a file, read it into vim using :r and
delete it again later when finished.

-Jens





Re: About quoting text, about emacs.

2001-07-26 Thread Walt Mankowski

On Fri, Jul 27, 2001 at 12:20:53AM +0200, Jens Paulus wrote:
> What you suggest is quite okay. Thank you.

I'm glad I could be of help.

Walt

 PGP signature