[Bug 5221] New: Rebase drops existing empty revisions
mercurial-bugs at selenic.com
mercurial-bugs at selenic.com
Thu Apr 28 19:23:54 UTC 2016
https://bz.mercurial-scm.org/show_bug.cgi?id=5221
Bug ID: 5221
Summary: Rebase drops existing empty revisions
Product: Mercurial
Version: 3.8-rc
Hardware: PC
OS: Windows
Status: UNCONFIRMED
Severity: feature
Priority: wish
Component: rebase
Assignee: bugzilla at selenic.com
Reporter: matt_harbison at yahoo.com
CC: mercurial-devel at selenic.com
I had a revision that opened a named branch without making file changes, and
then some subsequent commits. When I rebased it, the branch opening commit was
dropped, which had the effect of changing the branch name on the rest of the
commits.
Dropping commits made empty by the rebase makes sense, but maybe existing empty
ones should be preserved? (Although, if a cset with file changes + branch
rename gets emptied out by the rebase, it should maybe still be preserved to
keep the branch name. Not sure if there's a reason to care about other
metadata.)
STR:
$ hg init r
$ cd r
$ echo a > a
$ hg ci -Aqm a
$ hg branch -q my-branch
$ hg ci -m "add my-branch"
$ echo b > b
$ hg ci -Aqm b
$ hg up -q '.^^'
$ echo b > a
$ hg ci -m ab
$ hg log -G -T "{rev}: {desc} ({branch})\n"
@ 3: ab (default)
|
| o 2: b (my-branch)
| |
| o 1: add my-branch (my-branch)
|/
o 0: a (default)
$ hg --config extensions.rebase= rebase -s 1 -d .
rebasing 1:0c224a1f4404 "add my-branch"
note: rebase of 1:0c224a1f4404 created no changes to commit
rebasing 2:4749dd04c2ff "b"
saved backup bundle to * (glob)
$ hg log -G -T "{rev}: {desc} ({branch})\n"
o 2: b (default)
|
@ 1: ab (default)
|
o 0: a (default)
--
You are receiving this mail because:
You are on the CC list for the bug.
More information about the Mercurial-devel
mailing list