{"thread":{"id":"24896","subject":"Problems with extra files on git filter-branch when core.ignorecase is true","startedAt":"2010-08-28T22:21:41Z","lastAt":"2010-08-28T22:21:41Z","messageCount":1,"participants":["Simeon Maxein"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"149182","messageId":"AANLkTinEYNxKAAhq2O3joNYYrAmr=zRrUR3BakircnJW@mail.gmail.com","threadId":"24896","inReplyTo":null,"subject":"Problems with extra files on git filter-branch when core.ignorecase is true","fromName":"Simeon Maxein","fromEmail":"smaxein@googlemail.com","sentAt":"2010-08-28T22:21:41Z","receivedAt":"2010-08-28T22:21:41Z","isPatch":false,"sender":{"key":"smaxein@googlemail.com","avatar":"https://gravatar.com/avatar/f85c8c10abdc691c40249ebff4df1d31d57fa71e957154bf92f7058280d7208b?d=mp&s=160"},"body":"Today when trying to change the contents of a repository with git\nfilter-branch, a tool that was run on a part of the working tree for\neach version reported an extra file that couldn't be accounted for.\nAfter some testing and a small discussion on the irc channel, I was\nable to come up with the following scenario to reproduce the issue.\nThe test was performed under Ubuntu with Git 1.7.0.4 on a case\nsensitive file system:\n\n> ~$ mkdir gittest\n> ~$ cd gittest\n> ~/gittest$ git init\n> Initialized empty Git repository in /home/user/gittest/.git/\n> ~/gittest$ git config core.ignorecase true\n> ~/gittest$ echo 'foo' > testfile.txt\n> ~/gittest$ git add testfile.txt\n> ~/gittest$ git commit -m \"initial commit\"\n> [master (root-commit) 794888c] initial commit\n>  1 files changed, 1 insertions(+), 0 deletions(-)\n>  create mode 100644 testfile.txt\n> ~/gittest$ git rm testfile.txt\n> rm 'testfile.txt'\n> ~/gittest$ echo 'bar' > testFile.txt\n> ~/gittest$ git add testFile.txt\n> ~/gittest$ git commit -m \"additional commit\"\n> [master a669956] additional commit\n>  2 files changed, 1 insertions(+), 1 deletions(-)\n>  create mode 100644 testFile.txt\n>  delete mode 100644 testfile.txt\n> ~/gittest$ git filter-branch --tree-filter 'ls' master\n> Rewrite 794888cdbe107aa7408cc5ed4132dcd3bc2753c8 (1/2)testfile.txt\n> Rewrite a66995628af5710828a6a59628553938bc30ee37 (2/2)testfile.txt  testFile.txt\n>\n> WARNING: Ref 'refs/heads/master' is unchanged\n\nIn the second rewrite line, I would only expect testFile.txt to\nappear, regardless of the core.ignorecase setting. On a case\ninsensitive filesystem the above example works correctly.\n\nIt might seem strange to set core.ignorecase to true on a case\nsensitive filesystem, however, this issue also appears when using a\n(case sensitive) tmpfs temp directory to filter a case insensitive\nrepository.\n\nThanks in advance for your help.\n\nSimeon\n"}]}