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

RE: git pull on ia64 linux tree

From
Linus Torvalds <torvalds@osdl.org>
Date
Apr 27, 2005, 22:35 UTC
Message-ID
<Pine.LNX.4.58.0504271525520.18901@ppc970.osdl.org>
In-Reply-To
<B8E391BBE9FE384DAA4C5C003888BE6F035B31D9@scsmsx401.amr.corp.intel.com>
On Wed, 27 Apr 2005, Luck, Tony wrote:
> 
> The merge is right ... but "cg-update" leaves files that have been
> deleted lying around in the checked out tree.

Yes. I _think_ the right thing to do ends up being something like the update script doing

	diff-tree -r $orig $final | grep '^-'

at the end to get the list of deleted files, and just doing 'rm' on the result.

One problem with this is that "grep" always thinks lines end in '\n', and what we'd really want (from a scriptability angle) is

	diff-tree -z -r $orig $final | grep -0 '^-'

but I don't think you can tell grep to think that lines are zero-terminated instead of terminated with \n'. But I don't see how to do that with grep.

Another similar alternative is to use "show-files --others" before and after the merge and seeing what files got added to the list of "files we don't track", but that just sounds horribly hacky.

Anyway, there are clearly at least two ways of doing this, and we'll just have to have people work on the scripts to do it right..

		Linus
Previous: Luck, TonyNext: Petr Baudis
Message 2 of 11 in “RE: git pull on ia64 linux tree”
  1. Luck, TonyApr 27, 2005
  2. Linus TorvaldsApr 27, 2005
  3. Petr BaudisApr 27, 2005
  4. Linus TorvaldsApr 27, 2005
  5. Linus TorvaldsApr 27, 2005
  6. Petr BaudisApr 28, 2005
  7. Linus TorvaldsApr 28, 2005
  8. Petr BaudisApr 28, 2005
  9. Linus TorvaldsApr 28, 2005
  10. Petr BaudisApr 28, 2005
  11. Edgar ToernigApr 28, 2005

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.