English 中文(简体)
Converting Perforce repositories in to mercurial
原标题:

I have a perforce repository on Windows machine say (p4). I can access this p4 repo using p4v client by providing IP:PortNumber details.

Now I want to run "hg convert" command on this p4 repository from Linux machine so that p4 will be converted in to "p4-hg" a mercurial repository.

Mercurial is already installed on linux box and "hg convert" extension is also enabled. hg convert command is running perfectly.

I tried to convert p4 to hg using below command on linux box but it s not working:

hg convert http://ipAddressandPortNumber /home/p4-hg

On local machine I am able to convert any perforce repo to mercurial repo. That means, URL path does not work with "hg convert" command?

Please suggest me something.

问题回答

From a Perforce point of view, your command looks wrong.

If you can connect using p4v, you know the p4 server works. Try something like this (assuming Unix-like operating system, change as appropriate):

$ export P4PORT=ip.ad.re.ss:port
$ p4 login
   ( ... enter your password ...)

$ hg convert //depot/... /home/p4-hg

Assuming the "hg convert" command uses p4 underneath (which I assume it must), then this should help. If that doesn t work, you need to be more specific about the error message and how it is breaking.

You re correct that the perforce repository needs to be local for Mercurial to convert it. You ll need to copy it locally to convert.





相关问题
Can I clone part of a Mercurial repository?

Is it possible to clone part of a Mercurial repository? Let s say the repository is quite large, or contains multiple projects, or multiple branches. Can I clone only part of the repository? E.g. in ...

Sync files in Two Different Repos using HG

I ve got a problem when I try to sync files in two different repos. What I want to do is: I ve got 2 repos A and B, and they share some common files, suppose they lie in A/docs/common/ and B/docs/...

Tips on upgrading CVS to git/hg?

We still use CVS, I use git and hg for my personal use though I m still a novice at both, but I realize they re much more modern and better, faster, distributed, etc. It s just everyone is so ...

git for mercurial like git-svn

Hello is there a tool for git that allow to work with mercurial repositories F.e. for svn there is a git-svn package, that allows to clone/commit/update from svn and work in a git way.. So is there ...

Useful Mercurial Hooks [closed]

What are some useful Mercurial hooks that you have come across? A few example hooks are located in the Mercurial book: acl bugzilla notify check for whitespace I personally don t find these very ...

热门标签