共有リポジトリのローカルコピーを使用して一連のばかげた手順を実行しましたが、それを修正する方法を探しています。手順は次のとおりです。
私はブックマークを使用して、他の人が使用する開発ブランチの複数のヘッドを作成しました。
-o---o---o-----o--- <- dev branch \----1----1------ <- another head of the dev branch, where I committed stuff
しばらくして、まだローカルの新しいブランチを作成しました
/---------------x <- new branch -o---o---o-----o--- <- dev branch \----1----1------ <- another head of the dev branch, where I committed stuff
コードのみを含む1つのヘッドについて、別のブランチでリベースを実行しました
/-1'--1'-- <- rebase /---------------x <- new branch -o---o---o-----o--- <- dev branch \----1----1------ <- another head of the dev branch, where I committed stuff
次に、リベースをマージし、その後、いくつかのコミットを行った後、デフォルトをマージしました
----------d-\ <-default \ /-1'--1'\ \ /---------------x--------x--x-x-x-- <- new branch -o---o---o-----o--- \----1----1------
hg push --new-branch -b newBranch
ここで、新しいブランチをサーバー( )にプッシュしたかったのですがabort: push creates new remote head
、コミット1'
はdevブランチに属しているため、取得します。
正しいことは何ですか?この追加のヘッドを作成することは避けたいと思います。
更新:
リクエストごとに、これは次の出力ですhg heads
。
changeset: 839:f2033d695fcd <- want to push this
branch: newBranch
tag: tip
user: me
date: Wed Oct 31 13:05:51 2012 +0100
changeset: 826:7fde19d7f467
branch: devBranch
user: my-collegue
date: Tue Oct 23 14:59:42 2012 +0200
changeset: 820:23853bbf68df <- the part after rebase that got merged
branch: devBranch
user: me
date: Mon Oct 22 15:36:26 2012 +0200
changeset: 807:899344cfb145 <- obsolete (branch with 1's)
branch: devBranch
parent: 711:454f29c03fb1
user: me
date: Mon Oct 22 15:36:26 2012 +0200
changeset: 712:d5e8a62a7f5f <- default, needs to stay
parent: 648:2bbcc01aa191
user: me
date: Wed Aug 22 16:21:09 2012 +0200