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

[RFC/PATCH 0/3] support mboxrd format

From
EWEric Wong <e@80x24.org>
Date
May 30, 2016, 23:21 UTC
Message-ID
<20160530232142.21098-1-e@80x24.org>

Sometimes users will copy+paste an entire mbox into a commit message, leading to bad splits when a patch is output as an email.

Unlike other mbox-family formats, mboxrd allows reversible round-tripping while avoiding bad splits for old "mboxo" readers.

I'm also considering altering the current "From ${COMMIT} Mon Sep 17 00:00:00 2001" line to something else so mailsplit (or "am") can autodetect.

Maybe:
	From ${COMMIT}@mboxrd Mon Sep 17 00:00:00 2001
?

We may also want to default to single escaping "From " in commit messages for --pretty=email to avoid corruption when somebody copy+pastes an mbox into the commit message. This is a technically incompatible change, but I think it's preferable to breaking splitting complete.

In other words, --pretty=email changes to output "mboxo" for now.

Long term (possibly git 3.0?), maybe mboxrd can become the default mail format. IMHO, it should've been since 2005.

ref: http://homepage.ntlworld.com/jonathan.deboynepollard/FGA/mail-mbox-formats.html
Eric Wong (3):
      pretty: support "mboxrd" output format
      mailsplit: support unescaping mboxrd messages
      am: support --patch-format=mboxrd
 Documentation/git-am.txt        |  3 ++-
 Documentation/git-mailsplit.txt |  7 ++++++-
 builtin/am.c                    | 14 ++++++++++---
 builtin/log.c                   |  2 +-
 builtin/mailsplit.c             | 23 +++++++++++++++++++++
 commit.h                        |  6 ++++++
 log-tree.c                      |  4 ++--
 pretty.c                        | 45 +++++++++++++++++++++++++++++++++--------
 t/t4014-format-patch.sh         | 27 +++++++++++++++++++++++++
 t/t4150-am.sh                   | 20 ++++++++++++++++++
 t/t5100-mailinfo.sh             | 13 ++++++++++++
 t/t5100/0001mboxrd              |  4 ++++
 t/t5100/0002mboxrd              |  3 +++
 t/t5100/sample.mboxrd           | 17 ++++++++++++++++
 14 files changed, 172 insertions(+), 16 deletions(-)
Next: Eric Wong
Message 1 of 18 in “support mboxrd format”
  1. 0/3 support mboxrd formatEric Wong, May 30, 2016
  2. 1/3 pretty: support "mboxrd" output formatEric Wong, May 30, 2016
  3. Eric SunshineMay 31, 2016
  4. Eric WongMay 31, 2016
  5. Eric SunshineMay 31, 2016
  6. Eric WongMay 31, 2016
  7. Eric SunshineMay 31, 2016
  8. Eric SunshineMay 31, 2016
  9. Eric WongJun 2, 2016
  10. Eric SunshineJun 3, 2016
  11. Junio C HamanoJun 3, 2016
  12. Eric SunshineJun 3, 2016
  13. Junio C HamanoJun 3, 2016
  14. Eric SunshineJun 4, 2016
  15. Eric SunshineJun 4, 2016
  16. Junio C HamanoJun 4, 2016
  17. 2/3 mailsplit: support unescaping mboxrd messagesEric Wong, May 30, 2016
  18. 3/3 am: support --patch-format=mboxrdEric Wong, May 30, 2016

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.