From: Edi Weitz <edi@agharta.de>
Subject: [PATCH] Make feedmail usable for Cygwin
Date: Fri, 08 Oct 2004 23:16:16 +0200 [thread overview]
Message-ID: <ur7o89ahr.fsf@agharta.de> (raw)
[I first posted to gnu.emacs.bug but that doesn't seem to work. Sorry
if you see this twice.]
In the current version of feedmail you can't use its binmail template
facility with Cygwin's bash because "/bin/sh" is hard-coded. This tiny
patch changes that.
Cheers,
Edi.
2004-10-08 Edi Weitz <edi@agharta.de>
* mail/feedmail.el (feedmail-binmail-template)
(feedmail-buffer-to-binmail): Make usable for Cygwin
--- feedmail.el~ 2004-10-08 22:41:10.022078400 +0200
+++ feedmail.el 2004-10-08 22:43:26.958984000 +0200
@@ -1302,17 +1302,18 @@
(defcustom feedmail-binmail-template (if mail-interactive "/bin/mail %s" "/bin/rmail %s")
- "*Command template for the subprocess which will get rid of the mail.
-It can result in any command understandable by /bin/sh. Might not
-work at all in non-Unix environments. The single '%s', if present,
-gets replaced by the space-separated, simplified list of addressees.
-Used in feedmail-buffer-to-binmail to form the shell command which
-will receive the contents of the prepped buffer as stdin. If you'd
-like your errors to come back as mail instead of immediately in a
-buffer, try /bin/rmail instead of /bin/mail (this can be accomplished
-by keeping the default nil setting of `mail-interactive'). You might
-also like to consult local mail experts for any other interesting
-command line possibilities."
+ "*Command template for the subprocess which will get rid of the
+mail. It can result in any command understandable by the shell named
+by `shell-file-name'. Might not work at all in non-Unix
+environments. \(Note that on Cygwin you can use the value \"sh\".) The
+single '%s', if present, gets replaced by the space-separated,
+simplified list of addressees. Used in feedmail-buffer-to-binmail to
+form the shell command which will receive the contents of the prepped
+buffer as stdin. If you'd like your errors to come back as mail
+instead of immediately in a buffer, try /bin/rmail instead of
+/bin/mail (this can be accomplished by keeping the default nil setting
+of `mail-interactive'). You might also like to consult local mail
+experts for any other interesting command line possibilities."
:group 'feedmail-misc
:type 'string
)
@@ -1328,7 +1329,8 @@
(set-buffer prepped)
(apply
'call-process-region
- (append (list (point-min) (point-max) "/bin/sh" nil errors-to nil "-c"
+ (append (list (point-min) (point-max) shell-file-name
+ nil errors-to nil shell-command-switch
(format feedmail-binmail-template
(mapconcat 'identity addr-listoid " "))))))
next reply other threads:[~2004-10-08 21:16 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-10-08 21:16 Edi Weitz [this message]
-- strict thread matches above, loose matches on Subject: below --
2004-10-08 20:54 [PATCH] Make feedmail usable for Cygwin Edi Weitz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ur7o89ahr.fsf@agharta.de \
--to=edi@agharta.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).