tests/test-manifest-merging.t
author Mads Kiilerich <madski@unity3d.com>
Mon, 10 Feb 2014 00:54:27 +0100
changeset 20413 0ac94c0a3a38
parent 16913 f2719b387380
permissions -rw-r--r--
shelve: status messages from unshelve It was hard for the user to know what was going on when unshelving - especially if the user had to resolve conflicts and thus got to see the intermediate states. Seeing that pending changes was gone could scare the user, make him panic, and do stuff that really made him lose data. Merging (both when rebasing and with pending changes) also requires some understanding of where in the process you are and what you are merging. To help the user we now show a couple of status messages (when relevant): temporarily committing pending changes (restore with 'hg unshelve --abort') rebasing shelved changes

  $ hg init base

  $ cd base
  $ echo 'alpha' > alpha
  $ hg ci -A -m 'add alpha'
  adding alpha
  $ cd ..

  $ hg clone base work
  updating to branch default
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved

  $ cd work
  $ echo 'beta' > beta
  $ hg ci -A -m 'add beta'
  adding beta
  $ cd ..

  $ cd base
  $ echo 'gamma' > gamma
  $ hg ci -A -m 'add gamma'
  adding gamma
  $ cd ..

  $ cd work
  $ hg pull -q
  $ hg merge
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
  (branch merge, don't forget to commit)

Update --clean to revision 1 to simulate a failed merge:

  $ rm alpha beta gamma
  $ hg update --clean 1
  2 files updated, 0 files merged, 0 files removed, 0 files unresolved

  $ cd ..