From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/84931 Path: news.gmane.org!not-for-mail From: Sharon Kimble Newsgroups: gmane.emacs.gnus.general Subject: Re: separate smtps for my accounts Date: Sat, 13 Sep 2014 23:03:03 +0100 Message-ID: <87k357qiug.fsf@skimble.plus.com> References: <87tx4dodsj.fsf@skimble.plus.com> <87egvhsi8y.fsf@ericabrahamsen.net> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Trace: ger.gmane.org 1410645855 21652 80.91.229.3 (13 Sep 2014 22:04:15 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 13 Sep 2014 22:04:15 +0000 (UTC) To: ding@gnus.org Original-X-From: ding-owner+M33175@lists.math.uh.edu Sun Sep 14 00:04:10 2014 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from util0.math.uh.edu ([129.7.128.18]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1XSvQN-0002PZ-E4 for ding-account@gmane.org; Sun, 14 Sep 2014 00:04:09 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by util0.math.uh.edu with smtp (Exim 4.63) (envelope-from ) id 1XSvPk-0001ZC-DL; Sat, 13 Sep 2014 17:03:28 -0500 Original-Received: from mx1.math.uh.edu ([129.7.128.32]) by util0.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63) (envelope-from ) id 1XSvPi-0001Yz-Vt for ding@lists.math.uh.edu; Sat, 13 Sep 2014 17:03:26 -0500 Original-Received: from quimby.gnus.org ([80.91.231.51]) by mx1.math.uh.edu with esmtps (TLSv1:AES128-SHA:128) (Exim 4.76) (envelope-from ) id 1XSvPe-0000Cj-56 for ding@lists.math.uh.edu; Sat, 13 Sep 2014 17:03:26 -0500 Original-Received: from plane.gmane.org ([80.91.229.3]) by quimby.gnus.org with esmtp (Exim 4.80) (envelope-from ) id 1XSvPc-0008S5-7T for ding@gnus.org; Sun, 14 Sep 2014 00:03:20 +0200 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1XSvPb-0002Dt-7E for ding@gnus.org; Sun, 14 Sep 2014 00:03:19 +0200 Original-Received: from 87.114.21.185 ([87.114.21.185]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 14 Sep 2014 00:03:19 +0200 Original-Received: from boudiccas by 87.114.21.185 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 14 Sep 2014 00:03:19 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 73 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 87.114.21.185 User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.93 (gnu/linux) Cancel-Lock: sha1:LsZ6R1ztYhVZtcBV2B6smAPJH4M= X-Spam-Score: -4.2 (----) List-ID: Precedence: bulk Xref: news.gmane.org gmane.emacs.gnus.general:84931 Archived-At: --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Eric Abrahamsen writes: > Sharon Kimble writes: > >> In my gnus setup I have 1 pop3 account, and 3 imap accounts, but only >> one smtp address. How can I have a separate smtp settings so that I am >> able to reply via the address of the email that I've just received? >> >> Thanks >> Sharon. > > The details depend a little bit on the exact program you're using for > sending mail, but generally the rigmarole looks like this (I use > msmtp): I'm using whatever the default is with Debian testing, sorry! Exim4? I don't know what it is, but reportbug is able to send through it. Sharon. > > (defun cg-feed-msmtp () > (if (message-mail-p) > (save-excursion > (let* ((from > (save-restriction > (message-narrow-to-headers) > (message-fetch-field "from"))) > (account > (cond > ;; I use email address as account label in ~/.msmtprc > ((string-match "eric@ericabrahamsen.net" from) "ea") > ((string-match "account_two@gmail.com" from) "acc2") > ((string-match "more_accounts@domain.org" from) "more")))) > (setq message-sendmail-extra-arguments (list '"-a" account)))))) > > (setq message-sendmail-envelope-from 'header) > (add-hook 'message-send-mail-hook 'cg-feed-msmtp) > > > =2D-=20 A taste of linux =3D http://www.sharons.org.uk my git repo =3D https://bitbucket.org/boudiccas/dots TGmeds =3D http://www.tgmeds.org.uk Debian testing, fluxbox 1.3.5, emacs 24.3.93.1 --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBCgAGBQJUFL8XAAoJEDaBgBkK+INbK90QAMjXqCRUpDapxPZ049bo0Ela eup1GZSnQ8gdpp9IGeop64XmYxiZFodYYuiotyTtf859SuPwA1INeX+mR2gZuF7h /t/bSxZGI1e2w15Hf5ghVM/dPX2eHl1bkAKuxDsHjZD7le9oqFyLgx9ZnrCt9esc 4m8BswmKbtgKRG4jJ8Xf6Ed+A0Pe3Jn2Viq8QhXx7KvqKeIPr0TnefSlZyOEnE5r ESCZmscSatpBOFp4xaUv8Gg+2cI/kGWgXGMJKAkbIHhI0OMw2kFAKD3VlHmVFqmK +TWCen0zUKjGOH8y4zNjic+jXHZwRUG14cBO2ZBDxKn+wG901C9t7vn9zS1j00h4 2NvWoh+fVPFWKm1LHwEzPcK/LTQgb1AG0l9qfiwZFrjmGtMPFfIhXn+ZLDuX1r4q fr33adWP0l+KjUc+r+BwIqetez5RK7yNt00ejnstIDIKVzYwcoSNkDj2OXheg+rU C1s8KUbjmvfPzjsPz8Sw2GkLgrzvekRixvD5bTXYDfEYuaXYNuvBswXtMRZRSXhn wLzRjYYZGtPv4ATClNvcmn7sbnfTy7TCqhOR8KxUXhQEk2EtTMg1tOOzJ/hb/JW5 s2nnpWEdCxtTT7HDrUXGlT7R9lIFmEGhBUrZBamK83GzM4GLX2NYHyGZql1asBvl ovfV6ZZHojGwaMe9tA+r =xDQg -----END PGP SIGNATURE----- --=-=-=--