git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] fix some doc typos and grammar

From
Jakub Narebski <jnareb@gmail.com>
Date
Feb 2, 2007, 11:28 UTC
Message-ID
<epv761$gc1$1@sea.gmane.org>
In-Reply-To
<3c6c07c20702012326h551b9f32gb3d8238361105741@mail.gmail.com>
Mike Coleman wrote:
> On 2/2/07, Junio C Hamano <junkio@cox.net> wrote:
Show 14 quoted lines
>> It is usually nicer to put this "cover letter" material below
>> the three dashes after Signed-off-by line; not a huge deal,
>> though.
> 
> I remembered that the three dashes mattered, but I couldn't remember
> if it was above or below.
> 
> It turns out that it's fairly easy to configure gmail to accept an
> SMTP connection.  This recipe shows how to configure ssmtp, which is
> just a really dumb sender, to work with gmail:
> 
>     http://www.destr0yr.com/article.php/Gmail_and_sSMTP
> 
> This makes git-send-email work directly, and avoids the gmail web MUA.

It is fairly easy to do the same with sendmail (which is default MTA for many Linux distributions). I have googled the answer thanks to some tips on #git channel. You have to change /etc/mail/sendmail.mc (or the file where SMART_HOST is commented out), add your credentials to /etc/mail/authinfo, then compile changes using "make -C /etc/mail" (all of it as root, I think).

Your credential should have the form (in /etc/mail/authinfo)
  AuthInfo:smtp.gmail.com "U:username@gmail.com" "P:password" "M:PLAIN"
  AuthInfo: "U:username@gmail.com" "P:password" "M:PLAIN"

You can store password base64 encoded by using "P=base64pass" instead. /etc/mail/authinfo should be readable only by sendmail.

Below here are changes I have made in diff form. Most probably only the first chunk is needed; correct me if I'm wrong, please

--- /etc/mail/sendmail.mc.orig 2005-05-06 14:35:09.000000000 +0200 +++ /etc/mail/sendmail.mc 2006-11-25 17:20:50.000000000 +0100

@@ -19,7 +19,7 @@
 dnl # Uncomment and edit the following line if your outgoing mail needs to
 dnl # be sent out through an external mail server:
 dnl #
-dnl define(`SMART_HOST',`smtp.your.provider')
+define(`SMART_HOST',`[smtp.gmail.com]')
 dnl #
 define(`confDEF_USER_ID',``8:12'')dnl
 dnl define(`confAUTO_REBUILD')dnl
@@ -37,7 +37,7 @@
 dnl # The following allows relaying if the user authenticates, and disallows
 dnl # plaintext authentication (PLAIN/LOGIN) on non-TLS links
 dnl #
-dnl define(`confAUTH_OPTIONS', `A p')dnl
+define(`confAUTH_OPTIONS', `A p')dnl
 dnl # 
 dnl # PLAIN is the preferred plaintext authentication method and used by
 dnl # Mozilla Mail and Evolution, though Outlook Express and other MUAs do
@@ -45,8 +45,8 @@
 dnl # guaranteed secure.
 dnl # Please remember that saslauthd needs to be running for AUTH. 
 dnl #
-dnl TRUST_AUTH_MECH(`EXTERNAL DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl
-dnl define(`confAUTH_MECHANISMS', `EXTERNAL GSSAPI DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl
+TRUST_AUTH_MECH(`EXTERNAL DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl
+define(`confAUTH_MECHANISMS', `EXTERNAL GSSAPI DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl
 dnl #
 dnl # Rudimentary information on creating certificates for sendmail TLS:
 dnl #     cd /usr/share/ssl/certs; make sendmail.pem
@@ -71,6 +71,7 @@
 dnl FEATURE(delay_checks)dnl
 FEATURE(`no_default_msa',`dnl')dnl
 FEATURE(`smrsh',`/usr/sbin/smrsh')dnl
+FEATURE(`authinfo',`hash -o /etc/mail/authinfo.db')dnl
 FEATURE(`mailertable',`hash -o /etc/mail/mailertable.db')dnl
 FEATURE(`virtusertable',`hash -o /etc/mail/virtusertable.db')dnl
 FEATURE(redirect)dnl
@@ -153,7 +154,7 @@
 dnl # The following example makes mail from this host and any additional
 dnl # specified domains appear to be sent from mydomain.com
 dnl #
-dnl MASQUERADE_AS(`mydomain.com')dnl
+MASQUERADE_AS(`gmail.com')dnl
 dnl #
 dnl # masquerade not just the headers, but the envelope as well
 dnl #

Perhaps we should have put those on GitWiki page. Any volunteers?
-- 
Jakub Narebski
Warsaw, Poland
ShadeHawk on #git
Previous: Mike ColemanNext: Uwe Kleine-König
Message 4 of 6 in “fix some doc typos and grammar”
  1. fix some doc typos and grammarMike Coleman, Feb 2, 2007
  2. Junio C HamanoFeb 2, 2007
  3. Mike ColemanFeb 2, 2007
  4. Jakub NarebskiFeb 2, 2007
  5. How to configure your MTA [Was: [PATCH] fix some doc typos and grammar]Uwe Kleine-König, Feb 2, 2007
  6. Andy ParkinsFeb 2, 2007

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.