##// END OF EJS Templates
absorb: preserve branch-changing changesets even if empty...
Manuel Jacob -
r45516:1b757f38 default
parent child Browse files
Show More
@@ -887,6 +887,8 b' class fixupstate(object):'
887 if len(parents) != 1:
887 if len(parents) != 1:
888 return False
888 return False
889 pctx = parents[0]
889 pctx = parents[0]
890 if ctx.branch() != pctx.branch():
891 return False
890 # ctx changes more files (not a subset of memworkingcopy)
892 # ctx changes more files (not a subset of memworkingcopy)
891 if not set(ctx.files()).issubset(set(memworkingcopy)):
893 if not set(ctx.files()).issubset(set(memworkingcopy)):
892 return False
894 return False
@@ -525,3 +525,31 b' This should move us to the non-obsolete '
525 a: 1 of 1 chunk(s) applied
525 a: 1 of 1 chunk(s) applied
526 $ hg id
526 $ hg id
527 bfafb49242db tip
527 bfafb49242db tip
528
529 $ cd ..
530 $ hg init repo6
531 $ cd repo6
532 $ echo a1 > a
533 $ touch b
534 $ hg commit -m a -A a b
535 $ hg branch foo -q
536 $ echo b > b
537 $ hg commit -m foo # will become empty
538 $ hg branch bar -q
539 $ hg commit -m bar # is already empty
540 $ echo a2 > a
541 $ printf '' > b
542 $ hg absorb --apply-changes --verbose | grep became
543 0:0cde1ae39321: 1 file(s) changed, became 3:fc7fcdd90fdb
544 1:795dfb1adcef: 2 file(s) changed, became 4:a8740537aa53
545 2:b02935f68891: 2 file(s) changed, became 5:59533e01c707
546 $ hg log -T '{rev} (branch: {branch}) {desc}\n' -G --stat
547 @ 5 (branch: bar) bar
548 |
549 o 4 (branch: foo) foo
550 |
551 o 3 (branch: default) a
552 a | 1 +
553 b | 0
554 2 files changed, 1 insertions(+), 0 deletions(-)
555
General Comments 0
You need to be logged in to leave comments. Login now