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

Re: [PATCH] apply: tell user location of corrupted patch file

From
Junio C Hamano <gitster@pobox.com>
Date
Oct 5, 2019, 22:44 UTC
Message-ID
<xmqqbluu7qxn.fsf@gitster-ct.c.googlers.com>
In-Reply-To
<xmqqv9t37fsw.fsf@gitster-ct.c.googlers.com>
Junio C Hamano <gitster@pobox.com> writes:
Show 10 quoted lines
>> An alternate design was considered which involved printing the line
>> numbers relative to the output of `git am --show-current-patch` (in
>> other words, the actual mail file that's provided to am). This design
>> was not chosen because am does not store the whole mail and instead,
>> splits the mail into several files. As a result of this, this would
>> break existing users' workflow if they piped their mail directly to am
>> from their mail client, the whole mail would not exist in any file and
>> they would have to manually recreate the mail to see the line number.
>
> More importantly,...
Addendum.

I think the primary reason why the "alternate design" will not fly is *NOT* that it breaks existing users (which it would), but giving a line number in the original mbox file is not always possible.

Imagine the message you received was munged by the sending mailer, or a relaying mailer, and what you received is encoded in base64 ;-)

Previous: Junio C HamanoNext: Junio C Hamano
Message 11 of 12 in “[BUG] incorrect line numbers reported in git am”
  1. Denton LiuOct 2, 2019
  2. Junio C HamanoOct 2, 2019
  3. Denton LiuOct 2, 2019
  4. Junio C HamanoOct 2, 2019
  5. Denton LiuOct 2, 2019
  6. Junio C HamanoOct 3, 2019
  7. Duy NguyenOct 3, 2019
  8. Junio C HamanoOct 3, 2019
  9. apply: tell user location of corrupted patch fileDenton Liu, Oct 4, 2019
  10. Junio C HamanoOct 5, 2019
  11. Junio C HamanoOct 5, 2019
  12. Junio C HamanoOct 5, 2019

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.