{"thread":{"id":"23551","subject":"Git-SVN on Cygwin 1.7: git svn rebase b0rks index if not run from top-level directory","startedAt":"2010-04-21T16:56:07Z","lastAt":"2010-05-27T21:04:19Z","messageCount":5,"participants":["Matthias Andree","Alexander Iljin","Eric Wong"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"140041","messageId":"4BCF2E27.1010906@gmx.de","threadId":"23551","inReplyTo":null,"subject":"Git-SVN on Cygwin 1.7: git svn rebase b0rks index if not run from top-level directory","fromName":"Matthias Andree","fromEmail":"matthias.andree@gmx.de","sentAt":"2010-04-21T16:56:07Z","receivedAt":"2010-04-21T16:56:07Z","isPatch":false,"sender":{"key":"matthias.andree@gmx.de","avatar":null},"body":"Greetings,\n\nLooking for help - I have some issues with git-svn as of git version\n1.7.1.rc1.12.ga601 on Cygwin 1.7.5 w/ Windows 7 32-bit professional German, but\nthis has been going on for a while now, but I hadn't figured how to reproduce.\n\n=== Symptoms ===\n\nWhen I run \"git svn rebase\" (trace below) *from a working directory somewhere\ndeep in the checkout,* the index gets dirty.\n\ngit diff-index HEAD then shows a massive amount of files that were to be updated:\n\n$ git diff-index HEAD\n:100644 100644 faba562f37df8f4a308594b9b867470507229292\n0000000000000000000000000000000000000000 M      .project\n:100644 100644 0184158eda0e3787d5d29e1f23a6809ed3e4b54c\n0000000000000000000000000000000000000000 M      README.txt\n:100644 100644 d00be041aecaf00e2c3e7358911a6e5d493e9e7f\n0000000000000000000000000000000000000000 M      docs/.gitignore\n:100644 100644 bed116f07ba5742e6ed344553008c262656020c7\n0000000000000000000000000000000000000000 M      docs/d3.3/.gitignore\n[...]\n\nThis is always 100644 100644 SHA1 000...000 M filename.\n\n=== Impact ===\n\n- Several parts of git then show bogus local changes, for instance, gitk.\n\n- git svn dcommit aborts because it believes the index were dirty\n\n\n=== Workarounds ===\n\nEither is sufficient:\n\n1. cd to top-level directory before running git-svn\n\n2. git update-index --refresh\n\n\n=== Reproduce ===\n\n1. Use a git-svn checkout that has at least one subdirectory\n\n2. cd to that subdirectory\n\n3. run git svn rebase. It concludes successfully, then:\n\n4. git diff-index HEAD -> output like the one shown above.\n\n\n\n=== Trace ===\n\ntrace: exec: 'git-svn' 'rebase'\ntrace: run_command: 'git-svn' 'rebase'\ntrace: built-in: git 'rev-parse' '--show-cdup'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.fetchall'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.noauthcache'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.nocheckout'\ntrace: built-in: git 'config' '--get' 'svn.authorsprog'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.dryrun'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.followparent'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.useSvmProps'\ntrace: built-in: git 'config' '--get' 'svn.authorsfile'\ntrace: built-in: git 'config' '--get' 'svn.repackflags'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.localtime'\ntrace: built-in: git 'config' '--get' 'svn.username'\ntrace: built-in: git 'config' '--int' '--get' 'svn.repack'\ntrace: built-in: git 'config' '--get' 'svn.ignorepaths'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.quiet'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.verbose'\ntrace: built-in: git 'config' '--int' '--get' 'svn.logwindowsize'\ntrace: built-in: git 'config' '--get' 'svn.configdir'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.merge'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.addauthorfrom'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.useSvnsyncProps'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.noMetadata'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.local'\ntrace: built-in: git 'config' '--get' 'svn.strategy'\ntrace: built-in: git 'config' '--bool' '--get' 'svn.uselogauthor'\ntrace: built-in: git 'rev-parse' '--symbolic' '--all'\ntrace: built-in: git 'config' '-l'\ntrace: built-in: git 'config' '-l'\ntrace: built-in: git 'update-index' '--refresh'\ntrace: built-in: git 'log' '--no-color' '--first-parent' '--pretty=medium' 'HEAD'\ntrace: built-in: git 'config' '--bool' 'svn.useSvmProps'\ntrace: built-in: git 'config' '-l'\ntrace: built-in: git 'for-each-ref' '--format=%(refname)' 'refs/'\ntrace: built-in: git 'for-each-ref' '--format=%(refname)' 'refs/'\ntrace: built-in: git 'config' '--get' 'svn-remote.svn.rewriteRoot'\ntrace: built-in: git 'config' '--get' 'svn-remote.svn.url'\ntrace: built-in: git 'config' '--get' 'svn-remote.svn.uuid'\ntrace: built-in: git 'rev-list' '--pretty=raw' '--no-color' '--reverse'\n'thesamehashthatwasreplacedforprivacy..refs/remotes/trunk' '--'\ntrace: built-in: git 'config' '--get' 'svn-remote.svn.rewriteRoot'\ntrace: built-in: git 'config' '--get' 'svn-remote.svn.rewriteUUID'\ntrace: built-in: git 'diff-index' 'HEAD' '--'\ntrace: built-in: git 'config' '--get' 'svn-remote.svn.usesvmprops'\ntrace: built-in: git 'config' '--get' 'svn-remote.svn.nometadata'\ntrace: built-in: git 'cat-file' 'commit' 'thesamehashthatwasreplacedforprivacy'\ntrace: built-in: git 'config' 'svn-remote.svn.reposRoot'\n'svn+ssh://scm.gforge.inria.fr/svn/PROJECT'\ntrace: built-in: git 'rev-list' '--pretty=raw' '--no-color' '--reverse'\n'thesamehashthatwasreplacedforprivacy..refs/remotes/trunk' '--'\ntrace: built-in: git 'config' 'svn-remote.svn.reposRoot'\n'svn+ssh://scm.gforge.inria.fr/svn/PROJECT'\ntrace: exec: 'git-rebase' 'refs/remotes/trunk'\ntrace: run_command: 'git-rebase' 'refs/remotes/trunk'\ntrace: built-in: git 'rev-parse' '--git-dir'\ntrace: built-in: git 'rev-parse' '--show-toplevel'\ntrace: built-in: git 'config' '--bool' 'rebase.stat'\ntrace: built-in: git 'update-index' '--ignore-submodules' '--refresh'\ntrace: built-in: git 'diff-index' '--cached' '--name-status' '-r'\n'--ignore-submodules' 'HEAD' '--'\ntrace: built-in: git 'rev-parse' '--verify' 'refs/remotes/trunk^0'\ntrace: built-in: git 'rev-parse' '--verify' 'refs/remotes/trunk^0'\ntrace: built-in: git 'symbolic-ref' 'HEAD'\ntrace: built-in: git 'symbolic-ref' '-q' 'HEAD'\ntrace: built-in: git 'rev-parse' '--verify' 'master^0'\ntrace: built-in: git 'merge-base' 'thesamehashthatwasreplacedforprivacy'\n'thesamehashthatwasreplacedforprivacy'\ntrace: built-in: git 'rev-list' '--parents'\n'thesamehashthatwasreplacedforprivacy..thesamehashthatwasreplacedforprivacy'\nCurrent branch master is up to date.\n\n\n\n-- \nMatthias Andree\n"},{"id":"140046","messageId":"178224036.20100422014120@yandex.ru","threadId":"23551","inReplyTo":"4BCF2E27.1010906@gmx.de","subject":"Re: Git 1.7 rebase problems","fromName":"Alexander Iljin","fromEmail":"ajsoft@yandex.ru","sentAt":"2010-04-21T18:41:20Z","receivedAt":"2010-04-21T18:41:20Z","isPatch":false,"sender":{"key":"ajsoft@yandex.ru","avatar":"https://gravatar.com/avatar/5d53b714db7aaf3add180e650b6cbcfc17cd4ca0f29981ad97222e969a24bebb?d=mp&s=160"},"body":"Hello!\n\nMA> Looking for help - I have some issues with git-svn as of git version\nMA> 1.7.1.rc1.12.ga601 on Cygwin 1.7.5 w/ Windows 7 32-bit professional German, but\nMA> this has been going on for a while now, but I hadn't figured how to reproduce.\n\nMA> === Symptoms ===\n\nMA> When I run \"git svn rebase\" (trace below) *from a working directory somewhere\nMA> deep in the checkout,* the index gets dirty.\n\n  Wow! I just filed a very similar issue at msysGit discussion group,\n  with steps to reproduce, etc. See here:\n  http://groups.google.com/group/msysgit/browse_thread/thread/c7218c7d1ba8949b\n  I could not make interactive rebase work, it just hanged there.\n\n  Going to the root of the repository fixed the problem.\n\n---=====---\n Alexander\n"},{"id":"142389","messageId":"20100526185157.GB24211@dcvr.yhbt.net","threadId":"23551","inReplyTo":"4BCF2E27.1010906@gmx.de","subject":"Re: Git svn rebase/dcommit break (index) if not run from directory containing ./.git","fromName":"Eric Wong","fromEmail":"normalperson@yhbt.net","sentAt":"2010-05-26T18:51:57Z","receivedAt":"2010-05-26T18:51:57Z","isPatch":false,"sender":{"key":"e@80x24.org","avatar":null},"body":"Matthias Andree <matthias.andree@gmx.de> wrote:\n> [resending this with new Subject since there wasn't a reply in 33 days,  \n> cc:ing Eric]\n>\n> === Reproduce ===\n>\n> 1. Use a git-svn checkout that has at least one subdirectory\n>\n> 2. cd to that subdirectory\n>\n> 3. run git svn rebase. It concludes successfully, then:\n>\n> 4. git diff-index HEAD -> output like the one shown above.\n>\n> This is on Cygwin 1.7.5 w/ Windows 7 32-bit professional German.\n\nHi Matthias,\n\nI can't reproduce this on a GNU/Linux system, so I'm guessing this\nis a weird Cygwin/Windows issue, and I don't know Windows.\n\n-- \nEric Wong\n"},{"id":"142402","messageId":"op.vdcugytd1e62zd@merlin.emma.line.org","threadId":"23551","inReplyTo":"20100526185157.GB24211@dcvr.yhbt.net","subject":"Re: Git svn rebase/dcommit break (index) if not run from directory containing ./.git","fromName":"Matthias Andree","fromEmail":"matthias.andree@gmx.de","sentAt":"2010-05-27T08:13:36Z","receivedAt":"2010-05-27T08:13:36Z","isPatch":false,"sender":{"key":"matthias.andree@gmx.de","avatar":null},"body":"Am 26.05.2010, 20:51 Uhr, schrieb Eric Wong:\n\n> Matthias Andree <matthias.andree@gmx.de> wrote:\n>> [resending this with new Subject since there wasn't a reply in 33 days,\n>> cc:ing Eric]\n>>\n>> === Reproduce ===\n>>\n>> 1. Use a git-svn checkout that has at least one subdirectory\n>>\n>> 2. cd to that subdirectory\n>>\n>> 3. run git svn rebase. It concludes successfully, then:\n>>\n>> 4. git diff-index HEAD -> output like the one shown above.\n>>\n>> This is on Cygwin 1.7.5 w/ Windows 7 32-bit professional German.\n>\n> Hi Matthias,\n>\n> I can't reproduce this on a GNU/Linux system, so I'm guessing this\n> is a weird Cygwin/Windows issue, and I don't know Windows.\n\nDo you deem it possible to have the workaround applied in code, i. e.  \nchange to the top-level directory up front?\n\nIf not, any hints as to debugging facilities and procedures beyond  \nGIT_TRACE?\n\n-- \nMatthias Andree\n"},{"id":"142468","messageId":"20100527210419.GB2291@dcvr.yhbt.net","threadId":"23551","inReplyTo":"op.vdcugytd1e62zd@merlin.emma.line.org","subject":"Re: Git svn rebase/dcommit break (index) if not run from directory containing ./.git","fromName":"Eric Wong","fromEmail":"normalperson@yhbt.net","sentAt":"2010-05-27T21:04:19Z","receivedAt":"2010-05-27T21:04:19Z","isPatch":false,"sender":{"key":"e@80x24.org","avatar":null},"body":"Matthias Andree <matthias.andree@gmx.de> wrote:\n> Am 26.05.2010, 20:51 Uhr, schrieb Eric Wong:\n>> Matthias Andree <matthias.andree@gmx.de> wrote:\n>>> [resending this with new Subject since there wasn't a reply in 33 days,\n>>> cc:ing Eric]\n>>>\n>>> === Reproduce ===\n>>>\n>>> 1. Use a git-svn checkout that has at least one subdirectory\n>>>\n>>> 2. cd to that subdirectory\n>>>\n>>> 3. run git svn rebase. It concludes successfully, then:\n>>>\n>>> 4. git diff-index HEAD -> output like the one shown above.\n>>>\n>>> This is on Cygwin 1.7.5 w/ Windows 7 32-bit professional German.\n>>\n>> Hi Matthias,\n>>\n>> I can't reproduce this on a GNU/Linux system, so I'm guessing this\n>> is a weird Cygwin/Windows issue, and I don't know Windows.\n>\n> Do you deem it possible to have the workaround applied in code, i. e.  \n> change to the top-level directory up front?\n\n\"git rebase\" (invoked by \"git svn\") already does that.  This could\nbe a bug in \"git rebase\" itself...\n\n> If not, any hints as to debugging facilities and procedures beyond  \n> GIT_TRACE?\n\nWell I usually use \"strace -f\", but that's Linux-only.  Maybe there's\nsomething similar for Cygwin.\n\n-- \nEric Wong\n"}]}