Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

git was told to move a file, but the file already exists #22

Open
Ma-XX-oN opened this issue Nov 7, 2015 · 4 comments
Open

git was told to move a file, but the file already exists #22

Ma-XX-oN opened this issue Nov 7, 2015 · 4 comments

Comments

@Ma-XX-oN
Copy link

Ma-XX-oN commented Nov 7, 2015

Still going through the repository and found another issue, where a file is attempted to be moved, but it already exists. Here is part of the log:

Replaying changeset 45064 from 01/04/2002 16:33:02
d:\Users\maxxon\Desktop\vss2git\CaseWare\4.3\Cwin32\cwmfc: Rename CoolTree.cpp to cwuitree.cpp
Executing: C:\Program Files\Git\cmd\git.exe mv -- d:\Users\maxxon\Desktop\vss2git\CaseWare\4.3\Cwin32\cwmfc\CoolTree.cpp d:\Users\maxxon\Desktop\vss2git\CaseWare\4.3\Cwin32\cwmfc\cwuitree.cpp
!fatal: destination exists, source=CaseWare/4.3/Cwin32/cwmfc/CoolTree.cpp, destination=CaseWare/4.3/Cwin32/cwmfc/cwuitree.cpp
ERROR: git returned exit code 128
Executable: C:\Program Files\Git\cmd\git.exe
Arguments: mv -- d:\Users\maxxon\Desktop\vss2git\CaseWare\4.3\Cwin32\cwmfc\CoolTree.cpp d:\Users\maxxon\Desktop\vss2git\CaseWare\4.3\Cwin32\cwmfc\cwuitree.cpp
Stdout:
Stderr: fatal: destination exists, source=CaseWare/4.3/Cwin32/cwmfc/CoolTree.cpp, destination=CaseWare/4.3/Cwin32/cwmfc/cwuitree.cpp
Hpdi.Vss2Git.ProcessExitException: git returned exit code 128
   at Hpdi.Vss2Git.GitWrapper.FailExitCode(String exec, String args, String stdout, String stderr, Int32 exitCode) in d:\Users\maxxon\Documents\Visual Studio 2013\Projects\vss2git-master\vss2git-master\Vss2Git\GitWrapper.cs:line 301
   at Hpdi.Vss2Git.GitWrapper.ExecuteUnless(ProcessStartInfo startInfo, String unless) in d:\Users\maxxon\Documents\Visual Studio 2013\Projects\vss2git-master\vss2git-master\Vss2Git\GitWrapper.cs:line 296
   at Hpdi.Vss2Git.GitWrapper.GitExec(String args) in d:\Users\maxxon\Documents\Visual Studio 2013\Projects\vss2git-master\vss2git-master\Vss2Git\GitWrapper.cs:line 263
   at Hpdi.Vss2Git.GitWrapper.Move(String sourcePath, String destPath) in d:\Users\maxxon\Documents\Visual Studio 2013\Projects\vss2git-master\vss2git-master\Vss2Git\GitWrapper.cs:line 144
   at Hpdi.Vss2Git.GitExporter.CaseSensitiveRename(String sourcePath, String destPath, RenameDelegate renamer) in d:\Users\maxxon\Documents\Visual Studio 2013\Projects\vss2git-master\vss2git-master\Vss2Git\GitExporter.cs:line 752
   at Hpdi.Vss2Git.GitExporter.ReplayRevision(VssPathMapper pathMapper, Revision revision, GitWrapper git, LinkedList`1 labels) in d:\Users\maxxon\Documents\Visual Studio 2013\Projects\vss2git-master\vss2git-master\Vss2Git\GitExporter.cs:line 375
   at Hpdi.Vss2Git.GitExporter.<>c__DisplayClass11.<ReplayChangeset>b__d() in d:\Users\maxxon\Documents\Visual Studio 2013\Projects\vss2git-master\vss2git-master\Vss2Git\GitExporter.cs:line 247
   at Hpdi.Vss2Git.GitExporter.AbortRetryIgnore(ThreadStart work, MessageBoxButtons buttons) in d:\Users\maxxon\Documents\Visual Studio 2013\Projects\vss2git-master\vss2git-master\Vss2Git\GitExporter.cs:line 594

I removed the destination file manually with git and continued on. I think that is the correct course of action.

Maxx

@wqweto
Copy link

wqweto commented Jan 20, 2016

This is fixed by this PR on the rustyx fork.

@VasiliPupkin256
Copy link

But rusty doesn't pull his fork to trevorr

@VasiliPupkin256
Copy link

wqweto, your fix is bad. This is a result of reckless commit combination done by vss2git. It should not combining commits if the last commit removes or overwrite a file changed by the previous commit

@wqweto
Copy link

wqweto commented Jan 12, 2018

You are right, of course. This was a quick fix to get something working.

The root cause of the issue seems to be that vss2git does not handle folder renames (VSS calls these "projects") very well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants