Re: run external command when there is new mail

2002-06-24 Thread Matthew D. Fuller

On Mon, Jun 24, 2002 at 09:41:46PM +0200 I heard the voice of
Rocco Rutte, and lo! it spake thus:
> 
> > Have the pros and cons of an external mail notification
> > program already been discussed on the lists?
> 
> Hmm, what about biff and comsat allthough it doesn't catch
> all your folders at once...

FWIW, I've found xbuffy to be a nigh-on perfect solution; especially with
Maildir/'s, as its message-counting then doesn't interfere with mutt's
new message detection.


-- 
Matthew Fuller (MF4839)   |  [EMAIL PROTECTED]
Systems/Network Administrator |  http://www.over-yonder.net/~fullermd/

"The only reason I'm burning my candle at both ends, is because I
  haven't figured out how to light the middle yet"



Re: run external command when there is new mail

2002-06-24 Thread Rocco Rutte

Hi,

* Paul Stoeber [02-06-25 06:56:39 +0200] wrote:

> I meant:  Have the pros and cons of { having mutt call an
> external program when new mail arrives } already been
> discussed?  From Sven's intense reaction I guess it could
> have been.

Not that I know. The only negative thing I can imagine is
that there're already lots of variables.

> My patch may be featurititis.

Not really. You've written it and it works for you
allthough there will be people not using it.

Cheers, Rocco



Re: workarounds for LotusNotes - send_charset

2002-06-24 Thread Sven Guckes

* Velko Hristov <[EMAIL PROTECTED]> [2002-06-24 20:13]:
> in my .muttrc file I have the lines:
> 
> set charset=windows-1251
> set send_charset="us-ascii:windows-1251:iso-8859-1:utf-8"
> 
> and the hook:
> send-hook kristina 'set send_charset="iso-8859-1"'
> 
> which I need for sending windows-1251 encoded mails, pretending
> they are iso-8859-1 encoded (work-around for bug in lotus notes,
> which does not recognize correctly cyrillic encoding).
> 
> This worked fine with mutt 1.2.5i, but mutt 1.4 is "too"
> clever and doesn't allow me to set the wrong encoding.
> Can I persuade mutt 1.4 to do this anyway?

hmm... wild guess:  add some strange windows characters?

> From: Velko Hristov <[EMAIL PROTECTED]>
> Reply-To: Velko Hristov <[EMAIL PROTECTED]>

just where do these redundant Reply-To: header come from?

> Message-ID: <[EMAIL PROTECTED]>

one of these days I'll buy the TLD "localdomain"
and sue the pants off of everyone.  ha!

Sven  [give LN no chance!]

-- 
Sven Guckes [EMAIL PROTECTED] -
who hates mail sent with LotusNotes.
The Official LotusNotes Haters Page:
http://www.back.to/lotusnotes/



Re: mail notification programs -> FAQ!

2002-06-24 Thread Sven Guckes

* Paul Stoeber <[EMAIL PROTECTED]> [2002-06-24 20:39]:
> On Mon, Jun 24, 2002 at 09:41:46PM +0200, Rocco Rutte wrote:
> > * Paul Stoeber [02-06-24 21:27:06 +0200] wrote:
> > > Have the pros and cons of an external mail notification
> > > program already been discussed on the lists?
> >
> > Hmm, what about biff and comsat allthough
> > it doesn't catch all your folders at once...
>
> I meant:  Have the pros and cons of { having mutt call an external
> program when new mail arrives } already been discussed?

I've been maintaining a page on that topic for some years now.  see sig

> From Sven's intense reaction I guess it could have been.

"intense"?  naaa...

> It seems to be useful to be notified of new mail while you
> spend your tube time in some program other that mutt,
> having a permanent mutt in one of your hidden screens.
> The existence of the `beep_new' option admits that.

that reminds me:  this feature *could* be dropped.

> But the method of sending \007 to the terminal
> has some shortcomings: it can't distinguish
> different types of events, and on some terminals
> (mine for example) the beep is disabled.

use /dev/snd instead.  ;-)

> My patch may be featurititis.  Does mutt already
> provide a hook to implement the feature?

no.  use an external command.  you can hook into your MDA.
much better than having a mutt process check all mailboxes.

> Run-foo-command-on-bar-event seems
> to be a common automation task.

although mutt has bells-and-whistles
you should not mistake it for a cow.

Sven

--
Sven Guckes   [EMAIL PROTECTED]
URL: http://www.math.fu-berlin.de/~guckes/mail/notification.html
Mail Notification FAQ - which programs notify you about new mail?
Sample setups welcome!



Re: [a]lias command -> abook bbdb lbdb ldap

2002-06-24 Thread Sven Guckes

* Philip Mak <[EMAIL PROTECTED]> [2002-06-24 21:45]:
> I don't like the user interface for the [a]lias command.
> I'm thinking that some disk-based database
> (e.g. GDBM) would be more appropriate for aliases..
> This would fix the problem of aliases in
> one mutt not showing up in other mutts.

  $ man addressbook
  $ man lbdb
  $ man bbdb

> Furthermore, I run multiple copies of mutt in screen,
> and if I add an alias in one mutt, it doesn't show up
> in the other mutts unless I re-source .mail_aliases.

  $ man ldap

  $ man muttrc
  /query_command

> Pine has a nicer interface.

then use pine.

> .. can I configure mutt to not
> ask what file to save the alias to?

no - there's no prompt option for that.

> Also, if someone has a lot of aliases GDBM
> would be more efficient.  I don't think
> anyone would have hundreds of aliases, though...

  $ grep -c alias ~/.mutt.aliases
  886

> Thoughts?

rtfm

http://www.math.fu-berlin.de/~guckes/mutt/setup#aliases

Sven

-- 
Sven Guckes   [EMAIL PROTECTED]
use "lists address"   when you are *not* subscribed
use "subscribe address"   when you   *are*   subscribed
-> http://www.math.fu-berlin.de/~guckes/mutt/setup.html



[patch 1.5.1] have S/MIME check the from for a keyid

2002-06-24 Thread Omen Wild

I have been looking into the mailing list software sympa and one of its
features is that when you send an S/MIME mail encrypted to the list, it
will re-encrypt for each recipient.  The problem is that the mail shows
as being from me and to the list, so S/MIME was unable to find a key to
use to decrypt it.  I have patched smime.c:smime_getkeys so it checks
if there is a key that matches the From: and tries to use that. I can
now read encrypted emails that are sent to me by sympa.

Omen

-- 
Acid absorbs 47 times it's weight in excess Reality.


--- PATCHES~Tue Nov  6 19:59:33 2001
+++ PATCHES Tue Nov  6 19:59:42 2001
@@ -1,0 +1 @@
+patch-1.5.1.ow.smime_from.1
Index: smime.c
===
RCS file: /home/roessler/cvs/mutt/smime.c,v
retrieving revision 3.23
diff -u -d -b -B -U8 -r3.23 smime.c
--- smime.c 1 May 2002 23:21:10 -   3.23
+++ smime.c 24 Jun 2002 21:21:08 -
@@ -781,16 +781,22 @@
 
   for (t = env->to; !found && t; t = t->next)
 if (mutt_addr_is_user (t))
 {
   found = 1;
   _smime_getkeys (t->mailbox);
 }
   for (t = env->cc; !found && t; t = t->next)
+if (mutt_addr_is_user (t))
+{
+  found = 1;
+  _smime_getkeys (t->mailbox);
+}
+  for (t = env->from; !found && t; t = t->next)
 if (mutt_addr_is_user (t))
 {
   found = 1;
   _smime_getkeys (t->mailbox);
 }
   if (!found && (t = mutt_default_from()))
   {
 _smime_getkeys (t->mailbox);



[a]lias command

2002-06-24 Thread Philip Mak

I don't like the user interface for the [a]lias command.

When I add an alias, it prompts me through a series of one-line
prompts in the status bar. If I make a mistake, I have to press Ctrl+G
and start the whole series of prompts over. And, it asks me at the end
where I want to save the alias (I'd rather it not ask me, and always
save to .mail_aliases). Furthermore, I run multiple copies of mutt in
screen, and if I add an alias in one mutt, it doesn't show up in the
other mutts unless I re-source .mail_aliases.

Pine has a nicer interface. When I press "a" in Pine, it opens a full
screen where I can fill out a form (and move between the fields I'm
filling out), and then when I save it it doesn't ask me what file to
save it to; it just saves it to the default aliases file.

Anyway:

1. At least, can I configure mutt to not ask what file to save the
alias to?

2. I'm thinking that some disk-based database (e.g. GDBM) would be
more appropriate for aliases, rather than a text file that is sourced
when mutt starts. This would fix the problem of aliases in one mutt
not showing up in other mutts. (Also, if someone has a lot of aliases
GDBM would be more efficient. I don't think anyone would have hundreds
of aliases, though...)

Thoughts?



Re: No prompt for listing of mailboxes

2002-06-24 Thread Bob Phan

* On Jun 24, 2002, Shawn D. McPeek <[EMAIL PROTECTED]> said:
> Previously, Bob Phan wrote:
> % I've checked the docs, yet still am unable to discover a way to bypass
> % the prompt to list folders when hitting 'c'.  I'd much rather it jumped
> % right into the browser.  Is there any way this could be accomplished
> % short of a patch?
> 
> macro index c ""
> 
> Works fine for me.  Does it do what you want?

Yes, it worked great, thank you.

-- 
/*
 * Bob Phan <[EMAIL PROTECTED],[EMAIL PROTECTED]>
 * Computational Chemistry Informatics
 * Neurogen Corporation
 * (203)488-8201 x4645
 *
 * To understand recursion, you must first understand recursion.
 */



Re: No prompt for listing of mailboxes

2002-06-24 Thread Shawn D. McPeek

Previously, Bob Phan wrote:
% I've checked the docs, yet still am unable to discover a way to bypass
% the prompt to list folders when hitting 'c'.  I'd much rather it jumped
% right into the browser.  Is there any way this could be accomplished
% short of a patch?

macro index c ""

Works fine for me.  Does it do what you want?

Shawn

-- 
It now costs more to amuse a child than it once did to educate his father.



No prompt for listing of mailboxes

2002-06-24 Thread Bob Phan

I've checked the docs, yet still am unable to discover a way to bypass
the prompt to list folders when hitting 'c'.  I'd much rather it jumped
right into the browser.  Is there any way this could be accomplished
short of a patch?

-- 
/*
 * Bob Phan <[EMAIL PROTECTED],[EMAIL PROTECTED]>
 * Computational Chemistry Informatics
 * Neurogen Corporation
 * (203)488-8201 x4645
 *
 * To understand recursion, you must first understand recursion.
 */



Re: run external command when there is new mail

2002-06-24 Thread Paul Stoeber

On Mon, Jun 24, 2002 at 09:41:46PM +0200, Rocco Rutte wrote:
> * Paul Stoeber [02-06-24 21:27:06 +0200] wrote:
> > Have the pros and cons of an external mail notification
> > program already been discussed on the lists?
> 
> Hmm, what about biff and comsat allthough it doesn't catch
> all your folders at once...

I meant:  Have the pros and cons of { having mutt call an external
program when new mail arrives } already been discussed?  From Sven's
intense reaction I guess it could have been.

It seems to be useful to be notified of new mail while you spend your tube
time in some program other that mutt, having a permanent mutt in one of
your hidden screens.  The existence of the `beep_new' option admits that.

But the method of sending \007 to the terminal has some shortcomings:
it can't distinguish different types of events, and on some terminals
(mine for example) the beep is disabled.

My patch may be featurititis.  Does mutt already provide a hook to
implement the feature?  Run-foo-command-on-bar-event seems to be
a common automation task.



old encoding settings doesn't work with 1.4

2002-06-24 Thread Velko Hristov

Hello,

in my .muttrc file I have the lines:

set charset=windows-1251
set send_charset="us-ascii:windows-1251:iso-8859-1:utf-8"

and the hook:
send-hook kristina 'set send_charset="iso-8859-1"'

which I need for sending windows-1251 encoded mails, pretending
they are iso-8859-1 encoded (work-around for bug in lotus notes, which
does not recognize correctly cyrillic encoding).

This worked fine with mutt 1.2.5i, but mutt 1.4 is "too" clever and
doesn't allow me to set the wrong encoding.

Can I persuade mutt 1.4 to do this anyway?

Thanks - Velko



Re: run external command when there is new mail

2002-06-24 Thread Rocco Rutte

Hi,

* Paul Stoeber [02-06-24 21:27:06 +0200] wrote:

> Have the pros and cons of an external mail notification
> program already been discussed on the lists?

Hmm, what about biff and comsat allthough it doesn't catch
all your folders at once...

Cheers, Rocco



Re: Display problems with non-7bit text

2002-06-24 Thread Mark J. Reed

On Fri, Jun 14, 2002 at 10:58:34AM -0400, Thomas Dickey wrote:
> you really need the post-5.2 patches, since ncursesw was only tentative at
> that point.  The rollup patch should be sufficient -
> 
> ftp://invisible-island.net/ncurses/5.2
Well, I installed this patch, and rebuilt mutt, to no avail.
Mutt built with -lncursesw, but still displays Unicode characters
outside of the Latin-1 range with octal escapes, even though those 
characters display fine if I just cat the mbox file in the same terminal.  
I've tried setting LC_CTYPE to "en_US" and "en_US.utf-8"; I've also tried
leaving it and all other locale environment variables unset.  No luck.

I noticed that even though mutt built with -lncursesw, it used an include
path of -I/usr/include/ncurses; I manually changed that to
-I/usr/include/ncursesw in all the Makefiles and rebuilt, but that didn't
seem to make any difference.

Any other suggestions?

-- 
Mark REED| CNN Internet Technology
1 CNN Center Rm SW0831G  | [EMAIL PROTECTED]
Atlanta, GA 30348  USA   | +1 404 827 4754 
--
It is best not to swap horses while crossing the river.
-- Abraham Lincoln



Re: Autoconfiguration of subject

2002-06-24 Thread Gary Johnson

On Sun, Jun 23, 2002 at 10:06:02PM +0200, [EMAIL PROTECTED] wrote:
> One thing I do by mail is play some games at www.gamerz.net/pbmserv
> and their you set your game commando in the subject. Is there someway
> I could adjust the subject before I get the question by mutt what the
> subject should be so I don't have to repeat the same procedur every
> time.
> 
> The commando always look like this:
> 
> Subject:  
> 
> But when doing a standard reply it looks like this :
> 
> Subject: Re:   
> 
> So I am looking for something to get me from the last subject to the
> first so I only have to enter the  and only when replying to a
> specific mailaddress with a specific first word in the subject.

You _could_ use a macro and the line-editing commands to edit the
Subject.  I played with it a little bit, but I don't know if can do
everything you need.  For example, with the following macro,

macro index \cP 'r^M^M^W^B^B^B^B'

typing Ctrl-P will start a reply to the current message (r), follow the
To: and Cc: prompts with an Enter (^M^M), delete the last word of the
Subject (^W), and move the cursor four columns to the left (^B^B^B^B).
Note that each of the control characters on the right side of the macro
is entered as a carat (^) followed by a letter, e.g., ^W is entered as ^
followed by W, not as Ctrl-W.

So maybe you could use a macro to edit the Subject line the way you
want, leaving cursor in the proper location for entering your move.

HTH,
Gary

-- 
Gary Johnson   | Agilent Technologies
[EMAIL PROTECTED]   | Spokane, Washington, USA
http://www.spocom.com/users/gjohnson/mutt/ |



Re: run external command when there is new mail

2002-06-24 Thread Paul Stoeber

On Mon, Jun 24, 2002 at 03:00:12PM -0400, Dan Boger wrote:
> On Mon, Jun 24, 2002 at 06:54:55PM +, Paul Stoeber wrote:
> > > I actually said it can't be modified by someone else, unless you made it
> > > so.
> > 
> > True.  I guess Sven's comments have upset my logic unit.
> > 
> > Now seriously, how is my patch making mutt more insecure
> > than it is already?
> 
> it doesn't.  as far as I can tell (without reading the patch, of course)

So then what's all the commotion?  

Have the pros and cons of an external mail notification program
already been discussed on the lists?  Can you give me subject lines?


(Sven, I'm sorry for having misspelled your surname.)



Re: creating weird encrypted mails (like pgp_create_traditional)

2002-06-24 Thread Michael Tatge

Raoul Bönisch ([EMAIL PROTECTED]) muttered:
> "How can I send really broken encrypted email with mutt?"

Dale Woolridge created a patch which does what you need.
Surf over to http://www.woolridge.org/mutt/

HTH,

Michael
-- 
"All language designers are arrogant.  Goes with the territory..."
(By Larry Wall)

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



Re: creating weird encrypted mails (like pgp_create_traditional)

2002-06-24 Thread Peter T. Abplanalp

On Mon, Jun 24, 2002 at 08:42:15PM +0200, Raoul B?nisch wrote:
> Hello!

hi.

> "How can I send really broken encrypted email with mutt?"

interestingly enough, it is possible to break mutt in such a way as to
do this.  from memory, you can use the 1.5 dev version of mutt which
does this automagically or you can use the pct patch or maybe it is
the poc patch.  it is in the archives, look for outlook compatibility
or pct or poc.

-- 
Peter Abplanalp

Email:   [EMAIL PROTECTED]
PGP: pgp.mit.edu



msg29198/pgp0.pgp
Description: PGP signature


creating weird encrypted mails (like pgp_create_traditional)

2002-06-24 Thread Raoul Bönisch

Hello!

I found the option "pgp_create_traditional" and it nearly does what
people need. It simply forgets about rfc2015 and puts gpg encryption
output in the mail body. But it does one more thing which confuses
people's mail user agents. It adds

  Content-Type: application/pgp; x-action=encrypt; format=text

to my mail and people need

  Content-Type: text/plain; charset=us-ascii

Is there an easy way to change this?

I can send rfc-conforming mail and mail encrypted in deprecated
ways. I'm afraid in short my question is:

"How can I send really broken encrypted email with mutt?"

Raoul




Re: changing the subject with edit_headers and vi

2002-06-24 Thread Sven Guckes

* [EMAIL PROTECTED] <[EMAIL PROTECTED]> [2002-06-24 05:29]:
> > skip to the prompts - and use header editing:
> >  set autoedit
> >  set edit_headers
> Ok, I will check these in the manual.

try them, too!

> ..I always have to reenter the subject line and because it has a
> static formation it would be nice to speed things up a bit and have
> mutt rearrange the subject so I only have to enter the last part of
> the subject line.

let me point it out to you again:
mutt does not touch messages and
it does not change them, either.

use your *editor* to make the change.

> > so let your $EDITOR help you there.  which one do you use, btw?
> I use a standard configured mutt so my editor is vi.

ok then.  "set edit_headers" and reply to the mail.
place the cursor onto the Subject line (anywhere)
and type 'S' to substitute the current line.
type in the new Subject line.

that's not perfect - I know.

now place the cursor onto the Subject line but this
time onto the first non-space after the colon:

  Subject: Re: foo bar baz
   ^

now use 'C' to change the rest of the line.
some keystrokes save there as you do not
need to enter the "Subject:" again.

you can map ",cs" (change subject) thus:

   map ,cs   1G/^Subject: /e+1C

this is much faster, of course.
and you can bind it to, say, F10, too:

   map  1G/^Subject: /e+1C

i prefer to preserve a copy of the
old subject in the header, though:

   map  1G/^Subject: yypIX-Old--W

another method is to substitute the Subject line
using "!!" (two exclamation marks) and thereby
filtering to through a program, eg "awk".

more on this after you've upgrade to mutt-1.4
and set up your From: line to show your name.

Sven



Re: How can I edit the alias file from inside mutt? suspend and use $EDITOR

2002-06-24 Thread Sven Guckes

* Rahul Rekapalli <[EMAIL PROTECTED]> [2002-06-24 14:13]:
> I would like to know how i can edit the alias file from inside mutt.

you don't.  you cannot.  mutt is not an editor.
and mutt is not an address database, either.

the command create-alias appends an alias
definition to your $alias_file - but that's it.

everything else you can do with your editor.
just suspend mutt (with CTRL-Z) and use your editor.
after that, put mutt back into the foreground ("fg") and
read in the changed $alias_file with ":source filename".

it's the unix way.  works for me.  :-)

and then there are addresses databases
which you can query from within mutt,
eg with the $query_command.

anyway, if you need this inside of your mailer
then you had better use some other mailer, eg pine.

> also, is there any way to select and take all the email
> addresses that appear in a mail and add it to my
> alias one by one rather than adding only the sender.

no - there is no "import-all-addresses" in mutt.

just pipe the message to a script which does that.
something like this might suffice:

  egrep -i '^(to|cc): ' >> $HOME/.mutt.aliases

the rest is up to you.  you will have to
come up with the alias names yourself, anyway.

> I have prevented gpg from retrieving the public key
> of a user automatically. can i manually retrieve
> the key using some shortcut from inside mutt.

no - i dont think there is such a command.
after all this functionality
is given with gpg and pgp.

you can bind any key to a shell-escape
which then calls some shell script:

macro index #X  "script\n"

the rest is up to you.

Sven

-- 
Sven Guckes   [EMAIL PROTECTED]
use "lists address"   when you are *not* subscribed
use "subscribe address"   when you   *are*   subscribed
-> http://www.math.fu-berlin.de/~guckes/mutt/setup.html



Re: save-message to scp

2002-06-24 Thread David T-G

Sven, et al --

...and then Sven Guckes said...
% 
% * Eric Smith <[EMAIL PROTECTED]> [2002-06-24 08:09]:
% > How do I create a macro that will instead of
% > saving a file scp it to another machine?
% 
...
% but i'm not sure whether "scp"
% accepts data from stdin.
% hmm... pipe the message to
%   scp - user@host:dir/file ?

I tried that first :-(  Bummer.


% 
% Sven  [usually tests suggestions first
%but no time for this right now]


HTH & HAND

:-D
-- 
David T-G  * It's easier to fight for one's principles
(play) [EMAIL PROTECTED] * than to live up to them. -- fortune cookie
(work) [EMAIL PROTECTED]
http://www.justpickone.org/davidtg/Shpx gur Pbzzhavpngvbaf Qrprapl Npg!




msg29194/pgp0.pgp
Description: PGP signature


Re: save-message to scp

2002-06-24 Thread Sven Guckes

* Eric Smith <[EMAIL PROTECTED]> [2002-06-24 08:09]:
> How do I create a macro that will instead of
> saving a file scp it to another machine?

I'd save the message to a file
and then transfer it with "scp"
and delete it afterwards.

you could use an external script
to create a temporary filename
and have it delete after transfer
with "scp", of course.

but i'm not sure whether "scp"
accepts data from stdin.
hmm... pipe the message to
  scp - user@host:dir/file ?

Sven  [usually tests suggestions first
   but no time for this right now]



Re: Autoconfiguration of subject

2002-06-24 Thread darren chamberlain

* [EMAIL PROTECTED] <[EMAIL PROTECTED]> [2002-06-23 16:04]:
> One thing I do by mail is play some games at www.gamerz.net/pbmserv
> and their you set your game commando in the subject. Is there someway
> I could adjust the subject before I get the question by mutt what the
> subject should be so I don't have to repeat the same procedur every
> time.

Has anyone set up a procmail recipe to play the game?  Sounds like it
might be a fun time...

(darren)

-- 
To you I'm an atheist; to God, I'm the Loyal Opposition.
-- Woody Allen



Re: random header script?

2002-06-24 Thread darren chamberlain

* Thomas Hurst <[EMAIL PROTECTED]> [2002-06-23 08:00]:
> If you still want to use a script but don't want to eat
>  *  and IO every invocation, you'll want
> to seek to somewhere random in the file and read until you get a
> complete line, ala (in Ruby):
> 
> begin
> File.open(file) do |f|
> f.seek(rand(File.size(file)))
> f.gets
> puts f.gets
> end
> rescue EOFError
> retry
> end
> 
> This will, however, guarantee the first line will never be read, and
> choose longer lines over shorter ones.

I have a fortune file (standard strfile format) that I use, and
occasionally my vi modeline (line 1) comes up as a fortune.  This is an
ideal solution... ;)

(darren)

-- 
Most rock journalism is people who can't write interviewing people
who can't talk for people who can't read.
-- Frank Zappa



How can I edit the alias file from inside mutt.

2002-06-24 Thread Rahul Rekapalli

Hi,
I would like to know how i can edit the alias file from inside mutt.
also, is there any way to select and take all the email addresses that
appear in a mail and add it to my alias one by one rather than adding
only the sender. I have prevented gpg from retrieving the public key of
a user automatically. can i manually retrieve the key using some
shortcut from inside mutt.

Rgds
Rahul
-- 
---
the bug stops here
---



msg29190/pgp0.pgp
Description: PGP signature


Re: save-message to scp

2002-06-24 Thread Jeremy Blosser

On Jun 24, Rocco Rutte [[EMAIL PROTECTED]] wrote:
> Hi,
> 
> * Sascha Huedepohl [02-06-24 12:12:38 +0200] wrote:
> 
>  > I think it should be possible to write a little shell script
>  > which takes the mail per STDIN, then saves it to a .tmp file
>  > and scp that file to the other machine.
> 
>  ~/bin/dieter.sh:
>  
>  #!/bin/sh
>  tee > /tmp/to-be-scped && scp /tmp/to-be-scped ...
>  rm -f /tmp/to-be-scped
> 
>  ~/.muttrc:
>  
>  macro pager ,s '|~/bin/dieter.sh'
> 
> (just as a starting point)

You can also just cat the message directly through ssh:

macro pager ,s '|ssh remote_host "cat > remote_file"'



msg29189/pgp0.pgp
Description: PGP signature


Re: save-message to scp

2002-06-24 Thread Rocco Rutte

Hi,

* Sascha Huedepohl [02-06-24 12:12:38 +0200] wrote:

 > I think it should be possible to write a little shell script
 > which takes the mail per STDIN, then saves it to a .tmp file
 > and scp that file to the other machine.

 ~/bin/dieter.sh:
 
 #!/bin/sh
 tee > /tmp/to-be-scped && scp /tmp/to-be-scped ...
 rm -f /tmp/to-be-scped

 ~/.muttrc:
 
 macro pager ,s '|~/bin/dieter.sh'

(just as a starting point)

 > The Command to Pipe the message to an external prog is '|' !?

Yes.

HTH,
Cheers, Rocco



Re: save-message to scp

2002-06-24 Thread Sascha Huedepohl

Hi,

* Eric Smith ([EMAIL PROTECTED]) wrote:
> According to Rocco Rutte on Mon, Jun 24, 2002 at 11:31:43AM +0200:
> > Hi,
> > 
> > * Eric Smith [02-06-24 11:22:58 +0200] wrote:
> >  > How do I create a macro that will instead of saving a file scp it
> >  > to another machine?

I think it should be possible to write a little shell script
which takes the mail per STDIN, then saves it to a .tmp file
and scp that file to the other machine.

The Command to Pipe the message to an external prog is '|' !?

HTH
sascha



msg29187/pgp0.pgp
Description: PGP signature


Re: save-message to scp

2002-06-24 Thread Eric Smith

According to Rocco Rutte on Mon, Jun 24, 2002 at 11:31:43AM +0200:
> Hi,
> 
> * Eric Smith [02-06-24 11:22:58 +0200] wrote:
>  > How do I create a macro that will instead of saving a file scp it
>  > to another machine?
> 
> How about saving it to a local file and scp that one?

Yes that is fine, but I do not know how to reference this
filename in a macro -
I do not want to do anything interactively - just execute the
macro, then the file must be copied to the remote machine.

Is there some documentation on writing macros?

-- 
Eric Smith



Re: save-message to scp

2002-06-24 Thread Rocco Rutte

Hi,

* Eric Smith [02-06-24 11:22:58 +0200] wrote:
 > How do I create a macro that will instead of saving a file scp it
 > to another machine?

How about saving it to a local file and scp that one?

Cheers, Rocco



Re: Finding flagged messages -> macro homework

2002-06-24 Thread Rocco Rutte

Hi,

* Sven Guckes [02-06-24 11:22:48 +0200] wrote:
 > * Rocco Rutte <[EMAIL PROTECTED]> [2002-06-23 15:19]:
 > > > Sven  [hoping for an either-or operator for the patterns]
 
 > > Mind to give an example?

 >   ~b rocco  !@#$  ~b rutte

 > ..where the !@#$  means "either.. or"

XOR. I don't really need it yet, but I'm sure I can
construct situations where I couldn't live without... ;-)

Cheers, Rocco



Re: how to filter in procmail

2002-06-24 Thread David Clarke

On Sun, 23 Jun 2002, John Smith wrote:
> subscribed to are using X-Mailing-List in the headers.  I examined the headers
> coming in here, and I can't find something that would help me :-)
> 

There's always the List-Unsubscribe header

David

-- 
I have found that there ain't no surer way to find out whether you like 
people than to travel with them -- Tom Sawyer Abroad



save-message to scp

2002-06-24 Thread Eric Smith

How do I create a macro that will instead of saving a file scp it
to another machine?

-- 
Eric Smith