[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Mail (smtp) config at different locations. Script or ..?



On Mon, Mar 10, 2003 at 03:16:10AM +0000, Joao Pedro Clemente wrote:
> So I'm seeking for advice here...
[snip]

1 compound word: offlineimap

IMAP server on home machine. (preferably courier)
offlineimap on laptop to fetch/send(using courier)

mutt to send with:

mjb@toolbox:~> cat bin/mailout                                        
#!/bin/sh
safecat /home/mjb/Mail/Outbox/tmp /home/mjb/Mail/Outbox/new
mjb@toolbox:~>

(the trick, is that courier is configured to send anything saved to that
box.. must be in 822 format, which mutt does.)

set up offlineimap to use localhost:1143, and run:

mjb@toolbox:~> cat bin/mailtunnel 
#!/bin/sh

remotehost=your.mail.server

if [ -n "$DISPLAY" ]; then
   exec rxvt -T Mailtunnel -ls +sb -rv -fn nil2 -geometry 5x5+1010+720 \
     -e zsh -c "ssh -t -L 1143:${remotehost}:143 $host 'echo -e WWWWWWWWWWWWWWW;cat'" &
else
   (exec ssh -L 1143:${remotehost}:143 $host 'sleep 1800') &
fi
mjb@toolbox:~>

(the W's make a nice little white square in the rxvt when the tunnel is up
and opened (I have a 1024x768 TFT))

mutt config:

macro pager <esc>f  "!offlineimap\n"  "Sync IMAP with local mail"
macro index <esc>f  "!offlineimap\n"  "Sync IMAP with local mail"
macro index <esc>F  "!mailtunnel\n"  "Start mail tunnel for offlineimap"

set sendmail="/home/mjb/bin/mailout"  # how to deliver mail
set folder=~/Mail               # where I keep my mailboxes
set spoolfile='+INBOX'                # where my new mail is located

Thats it. Works for me(tm)

Mike.
-- 
Mike Beattie <mike@ethernal.org>                      ZL4TXK, IRLP Node 6184

            yip yip yip yip yip yip yap yap yip *BANG* NO TERRIER



Reply to: