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

filter-branch --parent-filter in bare repository

From
WRWolfgang Rohdewald <wolfgang@rohdewald.de>
Date
Aug 13, 2012, 05:52 UTC
Message-ID
<3856084.85o9JFDjPO@i5>

Using git version 1.7.12.rc2.18.g61b472e (1.7.9 has the same problem)

If I run (directly in the bare repository)
git filter-branch -d ../localrewrite --parent-filter cat

I get this error message on the last line, nothing unusual before: error: Untracked working tree file 'AUTHORS' would be overwritten by merge.

but if I run (directly in the bare repository)
git filter-branch -d .localrewrite --parent-filter cat

everything works fine. Depending on the path of the temporary directory, the error may also point to some other file. AUTHORS is in the root directory, but it is never untracked.

If I do a clone and run the same command in the clone, it also works with any temp directory.

And this only happens with one specific repository - a KDE game, converted with svn2git. No other game has this problem. git fsck only finds dangling tags.

The resulting repositories are identical, so I can ignore the error message for now. But still - why can't I run this in the bare repository? git help filter-branch does not mention something like that.

You can get the repository here: http://www.rohdewald.de/oss/tst.tbz

Maybe related:

I run this directly in the bare repository. If the command succeeds, I find a checkout directly there (everything was clean before), so I have

branches description HEAD hooks info objects refs PLUS all directories and files right in there: AUTHORS History.h ksokobanui.rc MapDelta.h PathFinder.cpp Bookmark.cpp hooks LevelCollection.cpp Map.h PathFinder.h Bookmark.h HtmlPrinter.cpp LevelCollection.h Messages.sh PlayField.cpp branches HtmlPrinter.h LevelMap.cpp ModalLabel.cpp PlayField.h CMakeLists.txt ImageData.cpp LevelMap.h ModalLabel.h Queue.h config-ksokoban.h.cmake ImageData.h levels Move.cpp README data images main.cpp Move.h refs description index MainWindow.cpp MoveSequence.cpp StaticImage.cpp doc info MainWindow.h MoveSequence.h StaticImage.h HEAD InternalCollections.cpp Map.cpp NEWS TODO History.cpp InternalCollections.h MapDelta.cpp objects

-- 
Wolfgang
Message 1 of 1 in “filter-branch --parent-filter in bare repository”
  1. Wolfgang RohdewaldAug 13, 2012

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.