4

Trying to import an existing git repository into SVN per this answer; went smoothly for a couple of commits, but then I hit a failed precommit hook.

r180827 = 444fa1c75e5a31fe8d887637a7fbd3fc62b34354 (refs/remotes/trunk)
No changes between current HEAD and refs/remotes/trunk
Resetting to the latest refs/remotes/trunk
Unstaged changes after reset:
M       [some file]
M       [another file]
M       [...etc...]
        A       [problem file]
A repository hook failed: 'pre-commit' hook failed with error output:
[error description]
  at /usr/libexec/git-core/git-svn line 922

I fixed the hook so I could get past it; but when I tried just git svn dcommit again (clearly wrong), I got

[some file]: needs update
[another file]: needs update
[...etc...]

When I do 'git status', I get:

#       modified: [some file]
#       modified: [another file]
#       modified: [...etc...]
#
# Untracked files:
#   (use "git add<file>..." to include in what will be committed
#       
#       [problem file]
#       [other file modified in the commit that created the problem file]
#       [yet other files modified in that commit]
#       [...etc...]

I suppose I could blow the whole SVN tree away and start over, but I'd really rather not. How do I recover from this and continue the dcommit?

Community
  • 1
  • 1
David Moles
  • 48,006
  • 27
  • 136
  • 235

1 Answers1

1

I got the exact same problem because of the following error when dcommitting:

   0 [main] perl.exe" 5992 handle_exceptions: Exception: STATUS_ACCESS_VIOLATION
6635 [main] perl.exe" 5992 open_stackdumpfile: Dumping stack trace to perl.exe.stackdump

Since I could not find any other solution, I simply did a local commit on the changes that were now "uncommitted" (as per the last example in the question), and after that I could run dcommit again. This effectively squashed the remaining local commits into a single one, but at least it worked.

If anyone knows of a better solution, it would be highly appreciated.

Adrian Schmidt
  • 1,886
  • 22
  • 35
  • 1
    I got this error as well but it took some time for me resolve. Your solution didn't work out for me. [Will write a lengthy summary](http://mikerobertking.blogspot.com/2014/06/git-svn-dcommit-exception.html) on what is happening and how to fix it to prevent anyone else from spending countless hours on this issue – Michael K. Jan 18 '15 at 06:15