Tuesday, June 3, 2014

Pushing to a remote bitbucket repository with Mercurial

Ugh.  This is a lot harder than it ought to be.  I am finding that a lot of activities with Mercurial is just easier to do through the command line instead of TortoiseHg.

If you want to push to your bitbucket repo, type this command in your directory:

> hg push https://username@bitbucket.org/username/someproject

However, the smarter way is to go into the .hg directory and modify the hgrc file like so:

[paths]
default-push = https://username@bitbucket.org/username/someproject

Now just type 'hg push' at the command prompt.

If you do not see the hgrc file, then you will have to make one!

No comments:

Post a Comment