From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm1-f49.google.com (mail-wm1-f49.google.com [209.85.128.49]) by mx.groups.io with SMTP id smtpd.web10.3142.1575461618304237890 for ; Wed, 04 Dec 2019 04:13:38 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@linaro.org header.s=google header.b=H+bb99eE; spf=pass (domain: linaro.org, ip: 209.85.128.49, mailfrom: leif.lindholm@linaro.org) Received: by mail-wm1-f49.google.com with SMTP id p17so7633682wmi.3 for ; Wed, 04 Dec 2019 04:13:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=pkRePtrTArfz1X89QwKWggxb4bKN0dMcYhHaXeyKsJo=; b=H+bb99eE/g3zQ7mAJxpjqqmi/HzrAB4OOZWCqUFVdq12BHPBLSj3imvZu9nxkQXcv5 YFBr43S1nvKYlrNJaJIi+JNU5hf6D0K7onKZH1kVjxx9FiEf1+qKMA0jwH2JsrDBocFz hfLPxRgEMBqlA1BNEwwIH4mximmKQ+ttnjK9w7/zOEOrkJVxolJAebXQ3fdusHple4v3 TTykRU/feYq4jggC6OlOt/rGlvEEoNSMhapV1ju9S74MuGkJDGkGho7/5tzF3CzGL6Fy +FqyFSNsFfigNhsm2zjhLcmuyXu3SxB2Jpms0p9u04UEHER4IZ812b2XCS7tag/o6EOn j4xQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=pkRePtrTArfz1X89QwKWggxb4bKN0dMcYhHaXeyKsJo=; b=JlpDIMhNOeWbZY5UtWf45Npbuy4WUYGE3sgDjbXHBRLMXYP5qH6II6LNHRRlxbXtVo me+AaSJnikXre2JV+TRsw+yerF153QQPabRsSgFfxspm4jGHGCQPsVoWKTJPZH6JKEPI CT2PF3iONzCVPkuF75n+wugmnCtZXBnrkjzwjYOX9049eErmHztA07SOJpN/M4WLsC0e 93ZI9zZRLlBTZxH1eROAbT29arjeJ911xFEDXdQmg3oSusW+SYV4NNEB80sFdw2SGTqU emceA/h3KV8jDpYZ/LS0w+yUtKkX6NFqu0deCHkF0UvI0H+OtB4Qy9f+IKj29+lomSUG jHiA== X-Gm-Message-State: APjAAAWG7rCnzHD6yAC8b28dMM2HL7GIYWdkm37rZgih0VH8omvieenL Ga47XErGs8qOff1LxF/K/+ScqOomFk0= X-Google-Smtp-Source: APXvYqwYDMW/PN+ucvYjFhUMDt/WwApLSkx0nDGm5CRMBra8BaHBFQ1EmUu+PPT6LcEEgiSJDmI/8A== X-Received: by 2002:a1c:23ca:: with SMTP id j193mr1172181wmj.83.1575461616540; Wed, 04 Dec 2019 04:13:36 -0800 (PST) Return-Path: Received: from bivouac.eciton.net (bivouac.eciton.net. [2a00:1098:0:86:1000:23:0:2]) by smtp.gmail.com with ESMTPSA id z12sm6404848wmd.16.2019.12.04.04.13.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 04 Dec 2019 04:13:35 -0800 (PST) Date: Wed, 4 Dec 2019 12:13:34 +0000 From: "Leif Lindholm" To: devel@edk2.groups.io, nathaniel.l.desimone@intel.com Subject: Re: [edk2-devel] Public-Service-Announcement: send-email issues with Git 2.22.0+ Message-ID: <20191204121334.GL7359@bivouac.eciton.net> References: <02A34F284D1DA44BB705E61F7180EF0AB5C14981@ORSMSX114.amr.corp.intel.com> MIME-Version: 1.0 In-Reply-To: <02A34F284D1DA44BB705E61F7180EF0AB5C14981@ORSMSX114.amr.corp.intel.com> User-Agent: Mutt/1.10.1 (2018-07-13) Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi Nate, On Wed, Dec 04, 2019 at 04:31:04 +0000, Nate DeSimone wrote: > I have been dealing with a very frustrating issue recently where all > of my "CR LF" line endings get erroneously converted into "LF LF" > once I send my patch to the mailing list. I have discovered the root > cause for this problem. The issue is the following commit to git > itself: > > https://github.com/git/git/commit/5983ddc165221c3ec2a4299b65cfb2ecc1ce7765 > > This change is present in git version 2.20.0 or later, per the release notes: > > https://github.com/git/git/blob/v2.22.0/Documentation/RelNotes/2.22.0.txt > > With this change, if you leave sendemail.transferEncoding set to the > default value of "auto", then git will inspect the body of your > email. If it finds a '\r' character in the message, then it converts > the entire message content into Quoted-Printable encoding. It > appears that when groups.io converts the QP encoding back to text > format, the '\r' characters somehow become '\n'. To workaround this > make sure to set the following configuration option: > > git config --global sendemail.transferEncoding 8bit Thanks for this investigation. Just one warning to readers - while convenient, --global may not be the correct course of action for all developers. > This will prevent send-email from converting the message into QP > encoding, allowing the patches to pass through to the mailing list > unharmed. Hope that saves other people a few hours of frustration. Could you possibly submit a patch adding this setting to this table https://github.com/tianocore/edk2/blob/master/BaseTools/Scripts/SetupGit.py#L54 such that it gets set automatically by that script? This way it's conveniently configured per-tree with the other known good default settings. I got curious and looked into what the git documentation says about this option. For 2.9.1 (the first search hit, July 2016) it says: "Default is the value of the sendemail.transferEncoding configuration value; if that is unspecified, git will use 8bit and not add a Content-Transfer-Encoding header." For 2.24.0 (the current release, November 2019) it says: "Default is the value of the sendemail.transferEncoding configuration value; if that is unspecified, default to auto." So a user of old git versions might not even have tripped over this... Best Regards, Leif