mirror of
https://github.com/facebook/sapling.git
synced 2024-10-07 15:27:13 +03:00
histedit: unify strip backup files on success (BC)
Previously we wrote two different strip backup files on success. This patch unifies them. It will make scmutil.cleanupnodes migration more smooth.
This commit is contained in:
parent
94f02e40d4
commit
f9577750a4
@ -1171,12 +1171,16 @@ def _finishhistedit(ui, repo, state):
|
||||
for n in succs[1:]:
|
||||
ui.debug(m % node.short(n))
|
||||
|
||||
safecleanupnode(ui, repo, tmpnodes)
|
||||
|
||||
if not state.keep:
|
||||
if mapping:
|
||||
movebookmarks(ui, repo, mapping, state.topmost, ntm)
|
||||
# TODO update mq state
|
||||
else:
|
||||
mapping = {}
|
||||
|
||||
for n in tmpnodes:
|
||||
mapping[n] = ()
|
||||
|
||||
safecleanupnode(ui, repo, mapping)
|
||||
|
||||
state.clear()
|
||||
|
@ -265,7 +265,6 @@ short hash. This tests issue3893.
|
||||
HG: branch 'default'
|
||||
HG: changed alpha
|
||||
saved backup bundle to $TESTTMP/foo/.hg/strip-backup/*-backup.hg (glob)
|
||||
saved backup bundle to $TESTTMP/foo/.hg/strip-backup/*-backup.hg (glob)
|
||||
|
||||
$ hg update -q 2
|
||||
$ echo x > x
|
||||
|
@ -87,8 +87,7 @@
|
||||
> fold e860deea161a 4 e
|
||||
> pick 652413bf663e 5 f
|
||||
> EOF
|
||||
saved backup bundle to $TESTTMP/r/.hg/strip-backup/96e494a2d553-3c6c5d92-backup.hg (glob)
|
||||
saved backup bundle to $TESTTMP/r/.hg/strip-backup/d2ae7f538514-48787b8d-backup.hg (glob)
|
||||
saved backup bundle to $TESTTMP/r/.hg/strip-backup/96e494a2d553-45c027ab-backup.hg (glob)
|
||||
$ hg log --graph
|
||||
@ changeset: 3:cacdfd884a93
|
||||
| bookmark: five
|
||||
|
@ -418,7 +418,6 @@ Now, let's try to fold the second commit into the first:
|
||||
|
||||
$ HGEDITOR="sh ./editor.sh" hg histedit 0
|
||||
saved backup bundle to $TESTTMP/issue4251/.hg/strip-backup/*-backup.hg (glob)
|
||||
saved backup bundle to $TESTTMP/issue4251/.hg/strip-backup/*-backup.hg (glob)
|
||||
|
||||
$ hg --config diff.git=yes export 0
|
||||
# HG changeset patch
|
||||
|
@ -382,8 +382,7 @@ dropped revision.
|
||||
HG: user: test
|
||||
HG: branch 'default'
|
||||
HG: changed file
|
||||
saved backup bundle to $TESTTMP/fold-with-dropped/.hg/strip-backup/55c8d8dc79ce-4066cd98-backup.hg (glob)
|
||||
saved backup bundle to $TESTTMP/fold-with-dropped/.hg/strip-backup/617f94f13c0f-a35700fc-backup.hg (glob)
|
||||
saved backup bundle to $TESTTMP/fold-with-dropped/.hg/strip-backup/617f94f13c0f-3d69522c-backup.hg (glob)
|
||||
$ hg logt -G
|
||||
@ 1:10c647b2cdd5 +4
|
||||
|
|
||||
|
@ -170,13 +170,13 @@ Base setup for the rest of the testing
|
||||
o 0:cb9a9f314b8b a
|
||||
|
||||
$ hg debugobsolete
|
||||
96e494a2d553dd05902ba1cee1d94d4cb7b8faed 0 {b346ab9a313db8537ecf96fca3ca3ca984ef3bd7} (*) {'user': 'test'} (glob)
|
||||
b558abc46d09c30f57ac31e85a8a3d64d2e906e4 0 {96e494a2d553dd05902ba1cee1d94d4cb7b8faed} (*) {'user': 'test'} (glob)
|
||||
d2ae7f538514cd87c17547b0de4cea71fe1af9fb 0 {cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b} (*) {'user': 'test'} (glob)
|
||||
177f92b773850b59254aa5e923436f921b55483b b346ab9a313db8537ecf96fca3ca3ca984ef3bd7 0 (*) {'user': 'test'} (glob)
|
||||
055a42cdd88768532f9cf79daa407fc8d138de9b 59d9f330561fd6c88b1a6b32f0e45034d88db784 0 (*) {'user': 'test'} (glob)
|
||||
e860deea161a2f77de56603b340ebbb4536308ae 59d9f330561fd6c88b1a6b32f0e45034d88db784 0 (*) {'user': 'test'} (glob)
|
||||
652413bf663ef2a641cab26574e46d5f5a64a55a cacdfd884a9321ec4e1de275ef3949fa953a1f83 0 (*) {'user': 'test'} (glob)
|
||||
96e494a2d553dd05902ba1cee1d94d4cb7b8faed 0 {b346ab9a313db8537ecf96fca3ca3ca984ef3bd7} (*) {'user': 'test'} (glob)
|
||||
b558abc46d09c30f57ac31e85a8a3d64d2e906e4 0 {96e494a2d553dd05902ba1cee1d94d4cb7b8faed} (*) {'user': 'test'} (glob)
|
||||
|
||||
|
||||
Ensure hidden revision does not prevent histedit
|
||||
|
Loading…
Reference in New Issue
Block a user