Reputation: 1041
I am taking a class that has a read-only git repository. I want to clone this into an hg repo. However, since I can't push back to this repo, I want to push to a repo in bitbucket with my local changes, but still pull down any changes from the git repo. I know you can clone a git repo with hg-git, but I want everything to be hg except the read-only git remote for the class. Thanks!
Upvotes: 0
Views: 52
Reputation: 97260
Just have 2 paths defined in project's .hgrc
Git's path will appear automatically, when you'll clone repo. HG's URL you have to add by hand
With up-to-date Mercurial you can have two slightly different configs (and resulting commands)
default = git+URL/OF/GIT
hg = URL/OF/HG
means using hg pull
+ hg push hg
default = git+URL/OF/GIT
default:pushurl = URL/OF/HG
means using plain hg pull
+ hg push
, but push will happen anyway to Mercurial-repo
Upvotes: 2