delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2002/10/17/02:06:16

Date: Thu, 17 Oct 2002 08:06:14 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: Martin Steuer <martinSteuer AT gmx DOT de>
cc: djgpp AT delorie DOT com
Subject: Re: Dos-Emacs and default shell
In-Reply-To: <5.1.1.6.2.20021016125819.009ea3c0@pop.gmx.net>
Message-ID: <Pine.SUN.3.91.1021017075952.3848E-100000@is>
MIME-Version: 1.0
Reply-To: djgpp AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Wed, 16 Oct 2002, Martin Steuer wrote:

> Ok, this works but I knew it won't be that easy. I think feedmail now 
> executes /bin/mail (which I dont have). I want to set up this to another 
> commandline-mailer.

Which mailer?  I have a version of feedmail.el that supports Blat, a PD 
command-line mailer for Windows.  If that's what you want, I can just 
send you the code (which I'm using for quite some time).

> The problem is I know nothing about ELisp (shame on 
> me). What do I have to do in this section:
> 
> (defun feedmail-buffer-to-binmail (prepped errors-to addr-listoid)
>   "Function which actually calls /bin/mail as a subprocess.
>   Feeds the buffer to it."
>   (set-buffer prepped)
>   (apply
>   'call-process-region
>   (append (list (point-min) (point-max) shell-file-name nil errors-to nil 
> shell-      command-switch
> 		(format feedmail-binmail-template
> 			(mapconcat 'identity addr-listoid " "))))))

You need to customize the variable feedmail-binmail-template so that it 
names your command-line mailer and any optional arguments it needs to 
receive from Emacs.  The doc string of feedmail-binmail-template should 
explain the details.

Note that in general it's not a good idea to invoke subprograms via the 
shell, since COMMAND.COM has too many limitations (such as too short 
command-line length limit) that will bite you further down the road.  For 
starters, typical lists of addressees can easily overflow the 126 
characters COMMAND.COM allows you. That's why I needed to hack 
feedmail.el rather than simply customize feedmail-binmail-template.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019