https://bz.mercurial-scm.org/show_bug.cgi?id=5498

            Bug ID: 5498
           Summary: "roll" of histedit removed wrong changesets
           Product: Mercurial
           Version: 4.1.1
          Hardware: PC
                OS: Linux
            Status: UNCONFIRMED
          Severity: bug
          Priority: wish
         Component: histedit
          Assignee: bugzi...@mercurial-scm.org
          Reporter: aklitz...@gmail.com
                CC: mercurial-devel@mercurial-scm.org

histedit will remove changesets with the example.


cd /tmp/
hg init dummy
cd dummy

echo "dummy" > dummy
hg add .
hg ci -m "test 1"

echo "dummy2" > dummy2
hg add .
hg ci -m "test 2"

hg up -r 0

echo "dummy3" > dummy3
hg add .
hg ci -m "test 3"

hg histedit

histedit shows a single line because it cannot handle the "draft" commit with
multiple heads. But if someone changes "pick" to "roll" Mercurial will do
strange things with the history.
That is really annoying since we use the "autoverb" feature and "roll" is
sometimes the default one.

Expected:
Print a warning like for "public" changesets and do nothing.

warning: histedit rules saved to: .hg/histedit-last-edit.txt
hg: parse error: cannot fold into public change XYZ





History before:

@  Änderung:        2:07b8f0553759
|  Marke:           tip
|  Vorgänger:       0:16436d3d271d
|  Nutzer:          ABC
|  Datum:           Wed Mar 08 09:10:41 2017 +0100
|  Zusammenfassung: test 3
|
| o  Änderung:        1:e28d5347a3f4
|/   Nutzer:          ABC
|    Datum:           Wed Mar 08 09:10:41 2017 +0100
|    Zusammenfassung: test 2
|
o  Änderung:        0:16436d3d271d
   Nutzer:          ABC
   Datum:           Wed Mar 08 09:10:41 2017 +0100
   Zusammenfassung: test 1


History after:
@  Änderung:        0:10905d80a643
   Marke:           tip
   Nutzer:          ABC
   Datum:           Wed Mar 08 09:10:41 2017 +0100
   Zusammenfassung: test 1

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel

Reply via email to