hg-git: push -d default seems not to work.

Kevin Bullock kbullock at ringworld.org
Wed May 3 13:47:35 UTC 2017


> On May 3, 2017, at 2:28 AM, Uwe Brauer <oub at mat.ucm.es> wrote:
> 
> Hi
> 
> Maybe somebody acquainted with hg-git could give me a hint.
> 
> I clone a git repo, via git clone.
> I clone that local repo via hg clone.
> 
> Now in the hg-clone-repo
> I use a named branch for a new feature, after a couple of commits I
> merge it into the default (bookmark master) branch.
> 
> Now I only want to push (locally) the default branch.
> 
> hg push -b default
> 
> However all the commits are pushed, which is not what I  want.
> 
> Example hg-repo
> 
> @    changeset:   6935:cf9dce9370e5
> |\   bookmark:    master
> | |  tag:         default/master
> | |  tag:         tip
> | |  parent:      6933:f126406be5c9
> | |  parent:      6934:b61106aa8e7b
> | |  user:        Uwe Brauer <oub at mat.ucm.es>
> | |  date:        Wed May 03 07:19:00 2017 +0000
> | |  summary:     Actualize question macro.
> | |
> | o  changeset:   6934:b61106aa8e7b
> |/   branch:      exam
> |    user:        Uwe Brauer <oub at mat.ucm.es>
> |    date:        Wed May 03 07:18:12 2017 +0000
> |    summary:     Actualize question macro.
> |
> o  changeset:   6933:f126406be5c9
> |  user:        Arash Esbati <arash at gnu.org>
> |  date:        Tue May 02 11:59:20 2017 +0200
> |  summary:     Use `ispell-tex-arg-end' on parsed elements
> |
> 
> So I only want to push changeset cf9dce9370e5 but not b61106aa8e7b

In order to push cf9dce9... you must push all ancestors of it, including b61106a... This isn't because of hg-git, it's intrinsic to how DVCS works. 

pacem in terris / мир / शान्ति / ‎‫سَلاَم‬ / 平和
Kevin R. Bullock


More information about the Mercurial mailing list