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

Re: Issue when adding new files to staged changes using interactive mode

From
Raymond E. Pasco <ray@ameretat.dev>
Date
Jul 29, 2020, 18:58 UTC
Message-ID
<C4JC6LFSAFFS.2U4ZZ9ZMO066A@ziyou.local>
In-Reply-To
<5BDF4B85-7AC1-495F-85C3-D429E3E51106@gmail.com>

This is introduced in commit feea6946a5b746ff4ebf8ccdf959e303203a6011 (diff-files: treat "i-t-a" files as "not-in-index"). I guess this leads to add-patch skipping directly to attempting to apply the hunk, rather than trying to combine it with what's already in the index, and apply --check --cached correctly reports that it's already in the index.

I'm looking at add-patch.c but it's not immediately obvious to me how it handles already-staged changes, so I don't have a proposed patch.

Previous: Another EmailNext: Raymond E. Pasco
Message 2 of 5 in “Issue when adding new files to staged changes using interactive mode”
  1. Another EmailJul 28, 2020
  2. Raymond E. PascoJul 29, 2020
  3. Raymond E. PascoJul 29, 2020
  4. Another EmailJul 29, 2020
  5. Taylor BlauJul 31, 2020

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.