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

Re: [PATCH] date: remove approxidate_relative()

From
René Scharfe <l.s.r@web.de>
Date
Apr 10, 2023, 20:52 UTC
Message-ID
<b17e05d5-deda-527f-1587-9f1cd7046a0b@web.de>
In-Reply-To
<20230410202536.GE104097@coredump.intra.peff.net>
Am 10.04.23 um 22:25 schrieb Jeff King:
Show 8 quoted lines
>
> I'm not sure of the least-confusing way to address a single hunk, though
> (by line number is one option, by hunk-number within the patch is
> another). I suspect the best workflow for a user would be to
> interactively say "show me more context for this hunk". Some viewers
> have support for that (e.g., GitHub's web view of a diff). But handling
> that for a one-shot CLI program is tricky, not to mention then feeding
> it back to format-patch to generate the output you want to send. :)

So basically you propose a format-patch --interactive mode that shows each hunk and allows extending its context. This could work. For hunks that span multiple screens it might be a bit iffy -- or perhaps not, if the scrollback buffer of the terminal or console is big enough.

René
Previous: Jeff KingNext: Jeff King
Message 4 of 9 in “date: remove approxidate_relative()”
  1. date: remove approxidate_relative()René Scharfe, Apr 8, 2023
  2. Junio C HamanoApr 10, 2023
  3. Jeff KingApr 10, 2023
  4. René ScharfeApr 10, 2023
  5. Jeff KingApr 11, 2023
  6. Junio C HamanoApr 10, 2023
  7. Jeff KingApr 11, 2023
  8. Junio C HamanoApr 11, 2023
  9. Jeff KingApr 12, 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.