Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

No changes are pushed when using hg-git

I'm trying to get the hg-git extension working under Windows and after hours of fiddling, I finally seem to have it working. However, nothing shows up in my git repository even though the output of hg push reads:

importing Hg objects into Git
creating and sending data
    github::refs/heads/master => GIT:8d946209
[command completed successfully Wed Oct 20 15:26:47 2010]
like image 760
James Avatar asked Oct 20 '10 20:10

James


People also ask

What is Hg in Git?

The Hg-Git plugin can convert commits/changesets losslessly from one system to another, so you can push via a Mercurial repository and another Mercurial client can pull it. In theory, the changeset IDs should not change, although this may not hold true for complex histories. Commands.

How do I push changes to a Git repository?

To push changes from the current branch press Ctrl+Shift+K or choose Git | Push from the main menu. To push changes from any local branch that has a remote, select this branch in the Branches popup and choose Push from the list of actions.

Does GitHub work with Mercurial?

hg-github is a Mercurial extension that wraps hg-git, and supports a work-flow where repositories are hosted on Bitbucket and mirrored on GitHub. This work-flow normally requires adding Git paths to each repository's config file, and creating Mercurial bookmarks pointing to the GitHub repository's branch name.


2 Answers

Try issuing the command hg bookmark -f master

(use -f to force an existing bookmark to move)

Then try pushing again.

This works because Hg-Git pushes your bookmarks up to the Git server as branches and will pull Git branches down and set them up as bookmarks. (from the official README.md)

like image 190
user1447520 Avatar answered Sep 24 '22 06:09

user1447520


And it seems that just after I asked this, I made a trivial change. This was picked up and pushed. So it seems that you have to wait until you've made a new commit in order for hg-git to pick it up.

like image 33
James Avatar answered Sep 22 '22 06:09

James