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

Re: [wishlist] git-add(1), git-restore(1): -U for more context (with -p)

From
Junio C Hamano <gitster@pobox.com>
Date
Aug 13, 2023, 19:44 UTC
Message-ID
<xmqq350mohgu.fsf@gitster.g>
In-Reply-To
<8bbfa6fe-fdaa-aeaf-51bc-16b3d3f7afaa@kernel.org>
Alejandro Colomar <alx@kernel.org> writes:
> It would be useful to have -U in git-add(1) and git-restore(1)
> to be able to see more context in combination with -p.

Even more useful would be to add commands to enlarge/shrink the context to the interactive prompt, wouldn't it? Not all hunks need unformly large context and having to decide how many lines of context to ask upfront and having to stick to the choice during the whole interactive session would be a bad interactive experience.

Previous: Alejandro ColomarNext: Alejandro Colomar
Message 2 of 3 in “[wishlist] git-add(1), git-restore(1): -U for more context (with -p)”
  1. Alejandro ColomarAug 13, 2023
  2. Junio C HamanoAug 13, 2023
  3. Alejandro ColomarAug 13, 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.