views:

30

answers:

2

I hope this is OK to ask here instead of superuser since I get very little response there to very specific questions like this.

I have a project that's under mercurial revision control and I'd like to move where it is located on my computer (from ~/workspace to ~/Dropbox/Projects). But if I move the project and then re-import it, it loses the mercurial connection.

I can just commit, push, delete my project, and re-import from hg in the new directory. But there has to be an easier way, no?

A: 

I don't know specifically about Mercurial, but with some version control systems, moving a checked out copy of the code is very hard (some VCS keep metadata with absolute paths, etc.). So I would commit and re-fetch, personally.

Also, consider the possibility of losing that uncommitted work during the move...

dty
Well I'd commit before I moved it just to be sure. This is mostly just for the sake of knowing whether there is a supported way of doing this, since going through re-checkout seems unnecessary.
Falmarri
A: 

When you move the project, can you confirm if the .hg subfolder (which holds the repository data) moved as well?

Is the moved repository accessible using a command-line or a different mercurial (say TortoiseHg) client?

In Eclipse, what happens when you do "Team -> Share Project..." again?

Raghuram
I moved it with mv -r project /path/to/new/project. And I guess what's happening is hgeclipse (mercurial client) no longer sees it as a mercurial project
Falmarri