##// END OF EJS Templates
merge with stable
Matt Mackall -
r22844:1533e642 merge default
parent child Browse files
Show More
@@ -449,10 +449,12 b' def unshelvecontinue(ui, repo, state, op'
449 if not shelvectx in state.pendingctx.children():
449 if not shelvectx in state.pendingctx.children():
450 # rebase was a no-op, so it produced no child commit
450 # rebase was a no-op, so it produced no child commit
451 shelvectx = state.pendingctx
451 shelvectx = state.pendingctx
452 else:
453 # only strip the shelvectx if the rebase produced it
454 state.stripnodes.append(shelvectx.node())
452
455
453 mergefiles(ui, repo, state.wctx, shelvectx)
456 mergefiles(ui, repo, state.wctx, shelvectx)
454
457
455 state.stripnodes.append(shelvectx.node())
456 repair.strip(ui, repo, state.stripnodes, backup=False, topic='shelve')
458 repair.strip(ui, repo, state.stripnodes, backup=False, topic='shelve')
457 shelvedstate.clear(repo)
459 shelvedstate.clear(repo)
458 unshelvecleanup(ui, repo, state.name, opts)
460 unshelvecleanup(ui, repo, state.name, opts)
@@ -330,7 +330,8 b' def ifcontains(context, mapping, args):'
330
330
331 # Iterating over items gives a formatted string, so we iterate
331 # Iterating over items gives a formatted string, so we iterate
332 # directly over the raw values.
332 # directly over the raw values.
333 if item in [i.values()[0] for i in items()]:
333 if ((callable(items) and item in [i.values()[0] for i in items()]) or
334 (isinstance(items, str) and item in items)):
334 yield _evalifliteral(args[2], context, mapping)
335 yield _evalifliteral(args[2], context, mapping)
335 elif len(args) == 4:
336 elif len(args) == 4:
336 yield _evalifliteral(args[3], context, mapping)
337 yield _evalifliteral(args[3], context, mapping)
@@ -2296,6 +2296,11 b' Test pad function'
2296
2296
2297 Test ifcontains function
2297 Test ifcontains function
2298
2298
2299 $ hg log --template '{rev} {ifcontains(rev, "2 two 0", "is in the string", "is not")}\n'
2300 2 is in the string
2301 1 is not
2302 0 is in the string
2303
2299 $ hg log --template '{rev} {ifcontains("a", file_adds, "added a", "did not add a")}\n'
2304 $ hg log --template '{rev} {ifcontains("a", file_adds, "added a", "did not add a")}\n'
2300 2 did not add a
2305 2 did not add a
2301 1 did not add a
2306 1 did not add a
@@ -687,6 +687,49 b' unshelve and conflicts with tracked and '
687 g
687 g
688 $ hg shelve --delete default
688 $ hg shelve --delete default
689
689
690 Recreate some conflict again
691
692 $ cd ../repo
693 $ hg up -C -r 3
694 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
695 (leaving bookmark test)
696 $ echo y >> a/a
697 $ hg shelve
698 shelved as default
699 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
700 $ hg up test
701 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
702 (activating bookmark test)
703 $ hg unshelve
704 unshelving change 'default'
705 rebasing shelved changes
706 merging a/a
707 warning: conflicts during merge.
708 merging a/a incomplete! (edit conflicts, then use 'hg resolve --mark')
709 unresolved conflicts (see 'hg resolve', then 'hg unshelve --continue')
710 [1]
711
712 Test that resolving all conflicts in one direction (so that the rebase
713 is a no-op), works (issue4398)
714
715 $ hg revert -a -r .
716 reverting a/a (glob)
717 $ hg resolve -m a/a
718 (no more unresolved files)
719 $ hg unshelve -c
720 unshelve of 'default' complete
721 $ hg diff
722 $ hg status
723 ? a/a.orig
724 ? foo/foo
725 $ hg summary
726 parent: 4:33f7f61e6c5e tip
727 create conflict
728 branch: default
729 bookmarks: *test
730 commit: 2 unknown (clean)
731 update: (current)
732
690 $ hg shelve --delete --stat
733 $ hg shelve --delete --stat
691 abort: options '--delete' and '--stat' may not be used together
734 abort: options '--delete' and '--stat' may not be used together
692 [255]
735 [255]
General Comments 0
You need to be logged in to leave comments. Login now