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

Re: [PATCH] date: remove approxidate_relative()

From
Jeff King <peff@peff.net>
Date
Apr 11, 2023, 09:25 UTC
Message-ID
<20230411092502.GA398350@coredump.intra.peff.net>
In-Reply-To
<b17e05d5-deda-527f-1587-9f1cd7046a0b@web.de>
On Mon, Apr 10, 2023 at 10:52:01PM +0200, René Scharfe wrote:
Show 14 quoted lines
> Am 10.04.23 um 22:25 schrieb Jeff King:
> >
> > 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.
Well, less proposing and more thinking out loud. :)

One thing that I think would make it awkward is that some people (well, me at least) tend to show diffs repeatedly. So I might look at a diff several times, and then even run format-patch multiple times as part of my workflow of sending it. Interactively expanding the diff each time, and then losing that result, would be annoying.

So an interactive tool that somehow output "oh, and here are some parameters you can feed back to get the same view" would be my ideal.

-Peff
Previous: René ScharfeNext: Junio C Hamano
Message 5 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.