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

Re: manual option --inline --no-attach override required for format.attach

From
BIBrian Inglis <brian.inglis@shaw.ca>
Date
Feb 17, 2023, 22:12 UTC
Message-ID
<e6696187-6fda-5b24-e2ba-91d323ffbfc3@Shaw.ca>
In-Reply-To
<xmqqr0uqwovt.fsf@gitster.g>
On 2023-02-15 15:21, Junio C Hamano wrote:
Show 20 quoted lines
> Brian Inglis <Brian.Inglis@Shaw.ca> writes:
> 
>> What did you do before the bug happened? (Steps to reproduce your issue)
>> git format-patch --inline ... --to=linux-man@vger.kernel.org
> 
> This is documented to use multipart/mixed attachement with
> "Content-Disposition: inline".
> 
>> git format-patch --no-attach ... --to=linux-man@vger.kernel.org
> 
> This should be the default, text/plain patch contained inline in the
> message.
> 
>> git send-email ... --to=linux-man@vger.kernel.org
> 
> It is unclera what ... hides on this command line, but if you sent
> output from both of the above two format-patch invocations, then the
> output from the first invocation of format-patch with --inline would
> be MIME multipart messages, so it is understandable if the recipient
> sees such messages.
Thanks Junio,

I think I was being confused by a project maintainer insisting on --inline when what he really wanted was --no-attach to get inline patches for his process, no other project previously caring that /etc/gitconfig had format.attach, and my not even being aware that was set until I checked! I also found my ISP had added outgoing milter rate limiting, rejecting everything after the 5th patch email in a series, adding to our situation!

But the point stands that there is no way to switch attach off in local or repo config if it is on in a more global config, other than remembering to manually specify --no-attach on every git format-patch. Suggest allowing attach=no|off|0. This would benefit those contributing from orgs tightly controlled environments where they may be unable to change global configs.

There should also be a config item if project maintainers want to see --inline attachments, working in the same manner as attach, or as an argument of attach?

-- 
Take care. Thanks, Brian Inglis			Calgary, Alberta, Canada

La perfection est atteinte			Perfection is achieved
non pas lorsqu'il n'y a plus rien à ajouter	not when there is no more to add
mais lorsqu'il n'y a plus rien à retirer	but when there is no more to cut
			-- Antoine de Saint-Exupéry
Previous: Junio C HamanoNext: brian m. carlson
Message 3 of 4 in “manual option --inline --no-attach override required for format.attach”
  1. Brian InglisFeb 15, 2023
  2. Junio C HamanoFeb 15, 2023
  3. Brian InglisFeb 17, 2023
  4. brian m. carlsonFeb 16, 2023

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.