tests/test-merge-changedelete.t
author Simon Farnsworth <simonfar@fb.com>
Sat, 19 Mar 2016 18:37:10 -0700
changeset 28634 3ceac01bc29f
parent 28029 72072cfc7e91
child 29774 a7f8939641aa
permissions -rw-r--r--
merge: save merge part labels for later reuse We permit the caller of merge operations to supply labels for the merge parts ("local", "other", and optionally "base"). These labels are used in conflict markers to reduce confusion; however, the labels were not persistent, so 'hg resolve' would lose the labels. Store the labels in the mergestate.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
     1
Tests for change/delete conflicts, including:
12328
b63f6422d2a7 tests: fix a bunch of pointless #s in unified tests
Matt Mackall <mpm@selenic.com>
parents: 12259
diff changeset
     2
b5605d88dc27: Make ui.prompt repeat on "unrecognized response" again
b63f6422d2a7 tests: fix a bunch of pointless #s in unified tests
Matt Mackall <mpm@selenic.com>
parents: 12259
diff changeset
     3
 (issue897)
b63f6422d2a7 tests: fix a bunch of pointless #s in unified tests
Matt Mackall <mpm@selenic.com>
parents: 12259
diff changeset
     4
b63f6422d2a7 tests: fix a bunch of pointless #s in unified tests
Matt Mackall <mpm@selenic.com>
parents: 12259
diff changeset
     5
840e2b315c1f: Fix misleading error and prompts during update/merge
b63f6422d2a7 tests: fix a bunch of pointless #s in unified tests
Matt Mackall <mpm@selenic.com>
parents: 12259
diff changeset
     6
 (issue556)
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
     7
26895
fc41f9ffd4a4 test-merge-prompt.t: unset HGMERGE
Siddharth Agarwal <sid0@fb.com>
parents: 26850
diff changeset
     8
Make sure HGMERGE doesn't interfere with the test
fc41f9ffd4a4 test-merge-prompt.t: unset HGMERGE
Siddharth Agarwal <sid0@fb.com>
parents: 26850
diff changeset
     9
  $ unset HGMERGE
fc41f9ffd4a4 test-merge-prompt.t: unset HGMERGE
Siddharth Agarwal <sid0@fb.com>
parents: 26850
diff changeset
    10
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    11
  $ status() {
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    12
  >     echo "--- status ---"
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    13
  >     hg st -A file1 file2 file3
27126
72b4e1bf8f28 test-merge-changedelete.t: add resolve --list output
Siddharth Agarwal <sid0@fb.com>
parents: 27125
diff changeset
    14
  >     echo "--- resolve --list ---"
72b4e1bf8f28 test-merge-changedelete.t: add resolve --list output
Siddharth Agarwal <sid0@fb.com>
parents: 27125
diff changeset
    15
  >     hg resolve --list file1 file2 file3
27136
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
    16
  >     echo "--- debugmergestate ---"
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
    17
  >     hg debugmergestate
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    18
  >     for file in file1 file2 file3; do
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    19
  >         if [ -f $file ]; then
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    20
  >             echo "--- $file ---"
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    21
  >             cat $file
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    22
  >         else
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    23
  >             echo "*** $file does not exist"
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    24
  >         fi
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    25
  >     done
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    26
  > }
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    27
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
    28
  $ hg init repo
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
    29
  $ cd repo
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    30
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    31
  $ echo 1 > file1
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    32
  $ echo 2 > file2
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    33
  $ echo 3 > file3
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    34
  $ hg ci -Am 'added files'
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    35
  adding file1
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    36
  adding file2
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    37
  adding file3
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    38
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    39
  $ hg rm file1
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    40
  $ echo changed >> file2
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    41
  $ echo changed1 >> file3
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    42
  $ hg ci -m 'removed file1, changed file2, changed file3'
5672
8a65ea986755 Tests for b5605d88dc27 and 840e2b315c1f (interactive prompts during merge)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
diff changeset
    43
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    44
  $ hg co 0
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    45
  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    46
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    47
  $ echo changed >> file1
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    48
  $ hg rm file2
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    49
  $ echo changed2 >> file3
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    50
  $ hg ci -m 'changed file1, removed file2, changed file3'
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    51
  created new head
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    52
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    53
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    54
Non-interactive merge:
5672
8a65ea986755 Tests for b5605d88dc27 and 840e2b315c1f (interactive prompts during merge)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
diff changeset
    55
12365
22f3353bcc36 tests: cleanup exit code handling in unified tests
Matt Mackall <mpm@selenic.com>
parents: 12328
diff changeset
    56
  $ hg merge -y
18543
c8ba98bf0e71 merge: don't indent "local changed %s which remote deleted" prompt
Mads Kiilerich <madski@unity3d.com>
parents: 15521
diff changeset
    57
  local changed file1 which remote deleted
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
    58
  use (c)hanged version, (d)elete, or leave (u)nresolved? u
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    59
  remote changed file2 which local deleted
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
    60
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    61
  merging file3
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    62
  warning: conflicts while merging file3! (edit, then use 'hg resolve --mark')
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
    63
  0 files updated, 0 files merged, 0 files removed, 3 files unresolved
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    64
  use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    65
  [1]
5672
8a65ea986755 Tests for b5605d88dc27 and 840e2b315c1f (interactive prompts during merge)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
diff changeset
    66
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    67
  $ status
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    68
  --- status ---
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    69
  M file2
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
    70
  M file3
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    71
  C file1
27126
72b4e1bf8f28 test-merge-changedelete.t: add resolve --list output
Siddharth Agarwal <sid0@fb.com>
parents: 27125
diff changeset
    72
  --- resolve --list ---
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
    73
  U file1
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
    74
  U file2
27126
72b4e1bf8f28 test-merge-changedelete.t: add resolve --list output
Siddharth Agarwal <sid0@fb.com>
parents: 27125
diff changeset
    75
  U file3
27136
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
    76
  --- debugmergestate ---
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
    77
  * version 2 records
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
    78
  local: 13910f48cf7bdb2a0ba6e24b4900e4fdd5739dd4
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
    79
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
    80
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
    81
  file: file1 (record type "C", state "u", hash 60b27f004e454aca81b0480209cce5081ec52390)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
    82
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
    83
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
    84
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
    85
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
    86
  file: file2 (record type "C", state "u", hash null)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
    87
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
    88
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
    89
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
    90
  file extras: file3 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27136
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
    91
  file: file3 (record type "F", state "u", hash d5b0a58bc47161b1b8a831084b366f757c4f0b11)
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
    92
    local path: file3 (flags "")
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
    93
    ancestor path: file3 (node 2661d26c649684b482d10f91960cc3db683c38b4)
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
    94
    other path: file3 (node a2644c43e210356772c7772a8674544a62e06beb)
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    95
  --- file1 ---
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    96
  1
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    97
  changed
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    98
  --- file2 ---
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
    99
  2
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   100
  changed
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   101
  --- file3 ---
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   102
  3
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   103
  <<<<<<< local: 13910f48cf7b - test: changed file1, removed file2, changed file3
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   104
  changed2
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   105
  =======
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   106
  changed1
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   107
  >>>>>>> other: 10f9a0a634e8  - test: removed file1, changed file2, changed file3
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   108
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   109
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   110
Interactive merge:
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   111
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   112
  $ hg co -C
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   113
  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
28029
72072cfc7e91 update: warn about other topological heads on bare update
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 28011
diff changeset
   114
  1 other heads for branch "default"
5672
8a65ea986755 Tests for b5605d88dc27 and 840e2b315c1f (interactive prompts during merge)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
diff changeset
   115
12365
22f3353bcc36 tests: cleanup exit code handling in unified tests
Matt Mackall <mpm@selenic.com>
parents: 12328
diff changeset
   116
  $ hg merge --config ui.interactive=true <<EOF
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   117
  > c
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   118
  > d
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   119
  > EOF
18543
c8ba98bf0e71 merge: don't indent "local changed %s which remote deleted" prompt
Mads Kiilerich <madski@unity3d.com>
parents: 15521
diff changeset
   120
  local changed file1 which remote deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   121
  use (c)hanged version, (d)elete, or leave (u)nresolved? c
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 18543
diff changeset
   122
  remote changed file2 which local deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   123
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? d
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   124
  merging file3
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   125
  warning: conflicts while merging file3! (edit, then use 'hg resolve --mark')
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   126
  0 files updated, 2 files merged, 0 files removed, 1 files unresolved
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   127
  use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   128
  [1]
5672
8a65ea986755 Tests for b5605d88dc27 and 840e2b315c1f (interactive prompts during merge)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
diff changeset
   129
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   130
  $ status
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   131
  --- status ---
15521
117f9190c1ba tests: hide 'No such file or directory' messages
Mads Kiilerich <mads@kiilerich.com>
parents: 12365
diff changeset
   132
  file2: * (glob)
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   133
  M file3
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   134
  C file1
27126
72b4e1bf8f28 test-merge-changedelete.t: add resolve --list output
Siddharth Agarwal <sid0@fb.com>
parents: 27125
diff changeset
   135
  --- resolve --list ---
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   136
  R file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   137
  R file2
27126
72b4e1bf8f28 test-merge-changedelete.t: add resolve --list output
Siddharth Agarwal <sid0@fb.com>
parents: 27125
diff changeset
   138
  U file3
27136
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   139
  --- debugmergestate ---
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   140
  * version 2 records
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   141
  local: 13910f48cf7bdb2a0ba6e24b4900e4fdd5739dd4
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   142
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   143
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   144
  file: file1 (record type "C", state "r", hash 60b27f004e454aca81b0480209cce5081ec52390)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   145
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   146
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   147
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   148
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   149
  file: file2 (record type "C", state "r", hash null)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   150
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   151
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   152
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   153
  file extras: file3 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27136
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   154
  file: file3 (record type "F", state "u", hash d5b0a58bc47161b1b8a831084b366f757c4f0b11)
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   155
    local path: file3 (flags "")
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   156
    ancestor path: file3 (node 2661d26c649684b482d10f91960cc3db683c38b4)
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   157
    other path: file3 (node a2644c43e210356772c7772a8674544a62e06beb)
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   158
  --- file1 ---
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   159
  1
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   160
  changed
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   161
  *** file2 does not exist
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   162
  --- file3 ---
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   163
  3
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   164
  <<<<<<< local: 13910f48cf7b - test: changed file1, removed file2, changed file3
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   165
  changed2
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   166
  =======
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   167
  changed1
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   168
  >>>>>>> other: 10f9a0a634e8  - test: removed file1, changed file2, changed file3
5672
8a65ea986755 Tests for b5605d88dc27 and 840e2b315c1f (interactive prompts during merge)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
diff changeset
   169
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   170
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   171
Interactive merge with bad input:
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   172
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   173
  $ hg co -C
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   174
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
28029
72072cfc7e91 update: warn about other topological heads on bare update
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 28011
diff changeset
   175
  1 other heads for branch "default"
5672
8a65ea986755 Tests for b5605d88dc27 and 840e2b315c1f (interactive prompts during merge)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
diff changeset
   176
12365
22f3353bcc36 tests: cleanup exit code handling in unified tests
Matt Mackall <mpm@selenic.com>
parents: 12328
diff changeset
   177
  $ hg merge --config ui.interactive=true <<EOF
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   178
  > foo
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   179
  > bar
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   180
  > d
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   181
  > baz
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   182
  > c
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   183
  > EOF
18543
c8ba98bf0e71 merge: don't indent "local changed %s which remote deleted" prompt
Mads Kiilerich <madski@unity3d.com>
parents: 15521
diff changeset
   184
  local changed file1 which remote deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   185
  use (c)hanged version, (d)elete, or leave (u)nresolved? foo
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 18543
diff changeset
   186
  unrecognized response
18543
c8ba98bf0e71 merge: don't indent "local changed %s which remote deleted" prompt
Mads Kiilerich <madski@unity3d.com>
parents: 15521
diff changeset
   187
  local changed file1 which remote deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   188
  use (c)hanged version, (d)elete, or leave (u)nresolved? bar
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 18543
diff changeset
   189
  unrecognized response
18543
c8ba98bf0e71 merge: don't indent "local changed %s which remote deleted" prompt
Mads Kiilerich <madski@unity3d.com>
parents: 15521
diff changeset
   190
  local changed file1 which remote deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   191
  use (c)hanged version, (d)elete, or leave (u)nresolved? d
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   192
  remote changed file2 which local deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   193
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? baz
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 18543
diff changeset
   194
  unrecognized response
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 18543
diff changeset
   195
  remote changed file2 which local deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   196
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? c
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   197
  merging file3
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   198
  warning: conflicts while merging file3! (edit, then use 'hg resolve --mark')
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   199
  0 files updated, 1 files merged, 1 files removed, 1 files unresolved
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   200
  use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   201
  [1]
5672
8a65ea986755 Tests for b5605d88dc27 and 840e2b315c1f (interactive prompts during merge)
Thomas Arendsen Hein <thomas@intevation.de>
parents:
diff changeset
   202
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   203
  $ status
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   204
  --- status ---
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   205
  M file2
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   206
  M file3
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   207
  R file1
27126
72b4e1bf8f28 test-merge-changedelete.t: add resolve --list output
Siddharth Agarwal <sid0@fb.com>
parents: 27125
diff changeset
   208
  --- resolve --list ---
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   209
  R file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   210
  R file2
27126
72b4e1bf8f28 test-merge-changedelete.t: add resolve --list output
Siddharth Agarwal <sid0@fb.com>
parents: 27125
diff changeset
   211
  U file3
27136
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   212
  --- debugmergestate ---
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   213
  * version 2 records
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   214
  local: 13910f48cf7bdb2a0ba6e24b4900e4fdd5739dd4
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   215
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   216
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   217
  file: file1 (record type "C", state "r", hash 60b27f004e454aca81b0480209cce5081ec52390)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   218
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   219
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   220
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   221
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   222
  file: file2 (record type "C", state "r", hash null)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   223
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   224
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   225
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   226
  file extras: file3 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27136
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   227
  file: file3 (record type "F", state "u", hash d5b0a58bc47161b1b8a831084b366f757c4f0b11)
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   228
    local path: file3 (flags "")
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   229
    ancestor path: file3 (node 2661d26c649684b482d10f91960cc3db683c38b4)
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   230
    other path: file3 (node a2644c43e210356772c7772a8674544a62e06beb)
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   231
  *** file1 does not exist
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   232
  --- file2 ---
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   233
  2
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   234
  changed
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   235
  --- file3 ---
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   236
  3
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   237
  <<<<<<< local: 13910f48cf7b - test: changed file1, removed file2, changed file3
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   238
  changed2
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   239
  =======
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   240
  changed1
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   241
  >>>>>>> other: 10f9a0a634e8  - test: removed file1, changed file2, changed file3
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   242
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   243
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   244
Interactive merge with not enough input:
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   245
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   246
  $ hg co -C
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   247
  2 files updated, 0 files merged, 1 files removed, 0 files unresolved
28029
72072cfc7e91 update: warn about other topological heads on bare update
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 28011
diff changeset
   248
  1 other heads for branch "default"
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   249
12365
22f3353bcc36 tests: cleanup exit code handling in unified tests
Matt Mackall <mpm@selenic.com>
parents: 12328
diff changeset
   250
  $ hg merge --config ui.interactive=true <<EOF
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   251
  > d
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   252
  > EOF
18543
c8ba98bf0e71 merge: don't indent "local changed %s which remote deleted" prompt
Mads Kiilerich <madski@unity3d.com>
parents: 15521
diff changeset
   253
  local changed file1 which remote deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   254
  use (c)hanged version, (d)elete, or leave (u)nresolved? d
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 18543
diff changeset
   255
  remote changed file2 which local deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   256
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   257
  merging file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   258
  warning: conflicts while merging file3! (edit, then use 'hg resolve --mark')
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   259
  0 files updated, 0 files merged, 1 files removed, 2 files unresolved
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   260
  use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   261
  [1]
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   262
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   263
  $ status
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   264
  --- status ---
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   265
  M file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   266
  M file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   267
  R file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   268
  --- resolve --list ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   269
  R file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   270
  U file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   271
  U file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   272
  --- debugmergestate ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   273
  * version 2 records
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   274
  local: 13910f48cf7bdb2a0ba6e24b4900e4fdd5739dd4
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   275
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   276
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   277
  file: file1 (record type "C", state "r", hash 60b27f004e454aca81b0480209cce5081ec52390)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   278
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   279
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   280
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   281
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   282
  file: file2 (record type "C", state "u", hash null)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   283
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   284
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   285
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   286
  file extras: file3 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   287
  file: file3 (record type "F", state "u", hash d5b0a58bc47161b1b8a831084b366f757c4f0b11)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   288
    local path: file3 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   289
    ancestor path: file3 (node 2661d26c649684b482d10f91960cc3db683c38b4)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   290
    other path: file3 (node a2644c43e210356772c7772a8674544a62e06beb)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   291
  *** file1 does not exist
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   292
  --- file2 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   293
  2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   294
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   295
  --- file3 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   296
  3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   297
  <<<<<<< local: 13910f48cf7b - test: changed file1, removed file2, changed file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   298
  changed2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   299
  =======
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   300
  changed1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   301
  >>>>>>> other: 10f9a0a634e8  - test: removed file1, changed file2, changed file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   302
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   303
Choose local versions of files
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   304
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   305
  $ hg co -C
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   306
  2 files updated, 0 files merged, 1 files removed, 0 files unresolved
28029
72072cfc7e91 update: warn about other topological heads on bare update
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 28011
diff changeset
   307
  1 other heads for branch "default"
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   308
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   309
  $ hg merge --tool :local
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   310
  0 files updated, 3 files merged, 0 files removed, 0 files unresolved
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   311
  (branch merge, don't forget to commit)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   312
  $ status 2>&1 | tee $TESTTMP/local.status
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   313
  --- status ---
15521
117f9190c1ba tests: hide 'No such file or directory' messages
Mads Kiilerich <mads@kiilerich.com>
parents: 12365
diff changeset
   314
  file2: * (glob)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   315
  M file3
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   316
  C file1
27126
72b4e1bf8f28 test-merge-changedelete.t: add resolve --list output
Siddharth Agarwal <sid0@fb.com>
parents: 27125
diff changeset
   317
  --- resolve --list ---
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   318
  R file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   319
  R file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   320
  R file3
27136
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   321
  --- debugmergestate ---
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   322
  * version 2 records
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   323
  local: 13910f48cf7bdb2a0ba6e24b4900e4fdd5739dd4
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   324
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   325
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   326
  file: file1 (record type "C", state "r", hash 60b27f004e454aca81b0480209cce5081ec52390)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   327
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   328
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   329
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   330
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   331
  file: file2 (record type "C", state "r", hash null)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   332
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   333
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   334
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   335
  file extras: file3 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   336
  file: file3 (record type "F", state "r", hash d5b0a58bc47161b1b8a831084b366f757c4f0b11)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   337
    local path: file3 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   338
    ancestor path: file3 (node 2661d26c649684b482d10f91960cc3db683c38b4)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   339
    other path: file3 (node a2644c43e210356772c7772a8674544a62e06beb)
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   340
  --- file1 ---
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   341
  1
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   342
  changed
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   343
  *** file2 does not exist
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   344
  --- file3 ---
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   345
  3
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   346
  changed2
12259
7b05cb9ac6d2 tests: unify test-merge-prompt
Adrian Buehlmann <adrian@cadifra.com>
parents: 5672
diff changeset
   347
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   348
Choose other versions of files
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   349
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   350
  $ hg co -C
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   351
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
28029
72072cfc7e91 update: warn about other topological heads on bare update
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 28011
diff changeset
   352
  1 other heads for branch "default"
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   353
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   354
  $ hg merge --tool :other
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   355
  0 files updated, 2 files merged, 1 files removed, 0 files unresolved
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   356
  (branch merge, don't forget to commit)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   357
  $ status 2>&1 | tee $TESTTMP/other.status
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   358
  --- status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   359
  M file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   360
  M file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   361
  R file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   362
  --- resolve --list ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   363
  R file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   364
  R file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   365
  R file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   366
  --- debugmergestate ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   367
  * version 2 records
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   368
  local: 13910f48cf7bdb2a0ba6e24b4900e4fdd5739dd4
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   369
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   370
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   371
  file: file1 (record type "C", state "r", hash 60b27f004e454aca81b0480209cce5081ec52390)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   372
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   373
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   374
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   375
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   376
  file: file2 (record type "C", state "r", hash null)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   377
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   378
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   379
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   380
  file extras: file3 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   381
  file: file3 (record type "F", state "r", hash d5b0a58bc47161b1b8a831084b366f757c4f0b11)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   382
    local path: file3 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   383
    ancestor path: file3 (node 2661d26c649684b482d10f91960cc3db683c38b4)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   384
    other path: file3 (node a2644c43e210356772c7772a8674544a62e06beb)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   385
  *** file1 does not exist
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   386
  --- file2 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   387
  2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   388
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   389
  --- file3 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   390
  3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   391
  changed1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   392
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   393
Fail
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   394
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   395
  $ hg co -C
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   396
  2 files updated, 0 files merged, 1 files removed, 0 files unresolved
28029
72072cfc7e91 update: warn about other topological heads on bare update
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 28011
diff changeset
   397
  1 other heads for branch "default"
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   398
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   399
  $ hg merge --tool :fail
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   400
  0 files updated, 0 files merged, 0 files removed, 3 files unresolved
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   401
  use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   402
  [1]
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   403
  $ status 2>&1 | tee $TESTTMP/fail.status
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   404
  --- status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   405
  M file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   406
  M file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   407
  C file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   408
  --- resolve --list ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   409
  U file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   410
  U file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   411
  U file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   412
  --- debugmergestate ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   413
  * version 2 records
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   414
  local: 13910f48cf7bdb2a0ba6e24b4900e4fdd5739dd4
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   415
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   416
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   417
  file: file1 (record type "C", state "u", hash 60b27f004e454aca81b0480209cce5081ec52390)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   418
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   419
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   420
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   421
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   422
  file: file2 (record type "C", state "u", hash null)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   423
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   424
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   425
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   426
  file extras: file3 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   427
  file: file3 (record type "F", state "u", hash d5b0a58bc47161b1b8a831084b366f757c4f0b11)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   428
    local path: file3 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   429
    ancestor path: file3 (node 2661d26c649684b482d10f91960cc3db683c38b4)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   430
    other path: file3 (node a2644c43e210356772c7772a8674544a62e06beb)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   431
  --- file1 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   432
  1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   433
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   434
  --- file2 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   435
  2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   436
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   437
  --- file3 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   438
  3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   439
  changed2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   440
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   441
Force prompts with no input (should be similar to :fail)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   442
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   443
  $ hg co -C
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   444
  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
28029
72072cfc7e91 update: warn about other topological heads on bare update
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 28011
diff changeset
   445
  1 other heads for branch "default"
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   446
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   447
  $ hg merge --config ui.interactive=True --tool :prompt
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   448
  local changed file1 which remote deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   449
  use (c)hanged version, (d)elete, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   450
  remote changed file2 which local deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   451
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   452
  no tool found to merge file3
27162
4ab69be0ea15 filemerge: add a 'leave unresolved' option to regular prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27137
diff changeset
   453
  keep (l)ocal, take (o)ther, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   454
  0 files updated, 0 files merged, 0 files removed, 3 files unresolved
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   455
  use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   456
  [1]
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   457
  $ status 2>&1 | tee $TESTTMP/prompt.status
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   458
  --- status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   459
  M file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   460
  M file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   461
  C file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   462
  --- resolve --list ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   463
  U file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   464
  U file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   465
  U file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   466
  --- debugmergestate ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   467
  * version 2 records
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   468
  local: 13910f48cf7bdb2a0ba6e24b4900e4fdd5739dd4
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   469
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   470
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   471
  file: file1 (record type "C", state "u", hash 60b27f004e454aca81b0480209cce5081ec52390)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   472
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   473
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   474
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   475
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   476
  file: file2 (record type "C", state "u", hash null)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   477
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   478
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   479
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   480
  file extras: file3 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   481
  file: file3 (record type "F", state "u", hash d5b0a58bc47161b1b8a831084b366f757c4f0b11)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   482
    local path: file3 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   483
    ancestor path: file3 (node 2661d26c649684b482d10f91960cc3db683c38b4)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   484
    other path: file3 (node a2644c43e210356772c7772a8674544a62e06beb)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   485
  --- file1 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   486
  1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   487
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   488
  --- file2 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   489
  2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   490
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   491
  --- file3 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   492
  3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   493
  changed2
27557
28b5c4fcf48d tests: Solaris diff -U also emits "No differences encountered"
Danek Duvall <danek.duvall@oracle.com>
parents: 27164
diff changeset
   494
  $ cmp $TESTTMP/fail.status $TESTTMP/prompt.status || diff -U8 $TESTTMP/fail.status $TESTTMP/prompt.status
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   495
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   496
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   497
Force prompts
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   498
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   499
  $ hg co -C
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   500
  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
28029
72072cfc7e91 update: warn about other topological heads on bare update
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 28011
diff changeset
   501
  1 other heads for branch "default"
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   502
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   503
  $ hg merge --tool :prompt
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   504
  local changed file1 which remote deleted
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   505
  use (c)hanged version, (d)elete, or leave (u)nresolved? u
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   506
  remote changed file2 which local deleted
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   507
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   508
  no tool found to merge file3
27164
88d5db4b155c filemerge: default regular prompts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27163
diff changeset
   509
  keep (l)ocal, take (o)ther, or leave (u)nresolved? u
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   510
  0 files updated, 0 files merged, 0 files removed, 3 files unresolved
27164
88d5db4b155c filemerge: default regular prompts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27163
diff changeset
   511
  use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
88d5db4b155c filemerge: default regular prompts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27163
diff changeset
   512
  [1]
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   513
  $ status
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   514
  --- status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   515
  M file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   516
  M file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   517
  C file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   518
  --- resolve --list ---
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   519
  U file1
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   520
  U file2
27164
88d5db4b155c filemerge: default regular prompts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27163
diff changeset
   521
  U file3
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   522
  --- debugmergestate ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   523
  * version 2 records
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   524
  local: 13910f48cf7bdb2a0ba6e24b4900e4fdd5739dd4
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   525
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   526
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   527
  file: file1 (record type "C", state "u", hash 60b27f004e454aca81b0480209cce5081ec52390)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   528
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   529
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   530
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   531
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   532
  file: file2 (record type "C", state "u", hash null)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   533
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   534
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   535
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   536
  file extras: file3 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27164
88d5db4b155c filemerge: default regular prompts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27163
diff changeset
   537
  file: file3 (record type "F", state "u", hash d5b0a58bc47161b1b8a831084b366f757c4f0b11)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   538
    local path: file3 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   539
    ancestor path: file3 (node 2661d26c649684b482d10f91960cc3db683c38b4)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   540
    other path: file3 (node a2644c43e210356772c7772a8674544a62e06beb)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   541
  --- file1 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   542
  1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   543
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   544
  --- file2 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   545
  2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   546
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   547
  --- file3 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   548
  3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   549
  changed2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   550
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   551
Choose to merge all files
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   552
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   553
  $ hg co -C
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   554
  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
28029
72072cfc7e91 update: warn about other topological heads on bare update
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 28011
diff changeset
   555
  1 other heads for branch "default"
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   556
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   557
  $ hg merge --tool :merge3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   558
  local changed file1 which remote deleted
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   559
  use (c)hanged version, (d)elete, or leave (u)nresolved? u
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   560
  remote changed file2 which local deleted
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   561
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   562
  merging file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   563
  warning: conflicts while merging file3! (edit, then use 'hg resolve --mark')
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   564
  0 files updated, 0 files merged, 0 files removed, 3 files unresolved
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   565
  use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to abandon
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   566
  [1]
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   567
  $ status
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   568
  --- status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   569
  M file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   570
  M file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   571
  C file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   572
  --- resolve --list ---
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   573
  U file1
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   574
  U file2
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   575
  U file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   576
  --- debugmergestate ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   577
  * version 2 records
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   578
  local: 13910f48cf7bdb2a0ba6e24b4900e4fdd5739dd4
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   579
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   580
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   581
  file: file1 (record type "C", state "u", hash 60b27f004e454aca81b0480209cce5081ec52390)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   582
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   583
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   584
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   585
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   586
  file: file2 (record type "C", state "u", hash null)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   587
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   588
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   589
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   590
  file extras: file3 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   591
  file: file3 (record type "F", state "u", hash d5b0a58bc47161b1b8a831084b366f757c4f0b11)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   592
    local path: file3 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   593
    ancestor path: file3 (node 2661d26c649684b482d10f91960cc3db683c38b4)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   594
    other path: file3 (node a2644c43e210356772c7772a8674544a62e06beb)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   595
  --- file1 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   596
  1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   597
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   598
  --- file2 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   599
  2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   600
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   601
  --- file3 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   602
  3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   603
  <<<<<<< local: 13910f48cf7b - test: changed file1, removed file2, changed file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   604
  changed2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   605
  ||||||| base
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   606
  =======
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   607
  changed1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   608
  >>>>>>> other: 10f9a0a634e8  - test: removed file1, changed file2, changed file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   609
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   610
Exercise transitions between local, other, fail and prompt, and make sure the
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   611
dirstate stays consistent. (Compare with each other and to the above
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   612
invocations.)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   613
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   614
  $ testtransitions() {
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   615
  >     # this traversal order covers every transition
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   616
  >     tools="local other prompt local fail other local prompt other fail prompt fail local"
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   617
  >     lasttool="merge3"
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   618
  >     for tool in $tools; do
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   619
  >         echo "=== :$lasttool -> :$tool ==="
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   620
  >         ref="$TESTTMP/$tool.status"
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   621
  >         hg resolve --unmark --all
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   622
  >         hg resolve --tool ":$tool" --all --config ui.interactive=True
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   623
  >         status > "$TESTTMP/compare.status" 2>&1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   624
  >         echo '--- diff of status ---'
27557
28b5c4fcf48d tests: Solaris diff -U also emits "No differences encountered"
Danek Duvall <danek.duvall@oracle.com>
parents: 27164
diff changeset
   625
  >         if cmp "$TESTTMP/$tool.status" "$TESTTMP/compare.status" || diff -U8 "$TESTTMP/$tool.status" "$TESTTMP/compare.status"; then
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   626
  >             echo '(status identical)'
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   627
  >         fi
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   628
  >         lasttool="$tool"
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   629
  >         echo
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   630
  >     done
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   631
  > }
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   632
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   633
  $ testtransitions
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   634
  === :merge3 -> :local ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   635
  (no more unresolved files)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   636
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   637
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   638
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   639
  === :local -> :other ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   640
  (no more unresolved files)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   641
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   642
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   643
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   644
  === :other -> :prompt ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   645
  local changed file1 which remote deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   646
  use (c)hanged version, (d)elete, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   647
  remote changed file2 which local deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   648
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   649
  no tool found to merge file3
27162
4ab69be0ea15 filemerge: add a 'leave unresolved' option to regular prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27137
diff changeset
   650
  keep (l)ocal, take (o)ther, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   651
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   652
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   653
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   654
  === :prompt -> :local ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   655
  (no more unresolved files)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   656
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   657
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   658
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   659
  === :local -> :fail ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   660
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   661
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   662
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   663
  === :fail -> :other ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   664
  (no more unresolved files)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   665
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   666
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   667
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   668
  === :other -> :local ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   669
  (no more unresolved files)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   670
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   671
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   672
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   673
  === :local -> :prompt ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   674
  local changed file1 which remote deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   675
  use (c)hanged version, (d)elete, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   676
  remote changed file2 which local deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   677
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   678
  no tool found to merge file3
27162
4ab69be0ea15 filemerge: add a 'leave unresolved' option to regular prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27137
diff changeset
   679
  keep (l)ocal, take (o)ther, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   680
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   681
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   682
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   683
  === :prompt -> :other ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   684
  (no more unresolved files)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   685
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   686
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   687
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   688
  === :other -> :fail ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   689
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   690
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   691
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   692
  === :fail -> :prompt ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   693
  local changed file1 which remote deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   694
  use (c)hanged version, (d)elete, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   695
  remote changed file2 which local deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   696
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   697
  no tool found to merge file3
27162
4ab69be0ea15 filemerge: add a 'leave unresolved' option to regular prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27137
diff changeset
   698
  keep (l)ocal, take (o)ther, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   699
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   700
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   701
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   702
  === :prompt -> :fail ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   703
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   704
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   705
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   706
  === :fail -> :local ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   707
  (no more unresolved files)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   708
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   709
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   710
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   711
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   712
26850
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   713
Non-interactive linear update
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   714
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   715
  $ hg co -C 0
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   716
  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
26850
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   717
  $ echo changed >> file1
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   718
  $ hg rm file2
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   719
  $ hg update 1 -y
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   720
  local changed file1 which remote deleted
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   721
  use (c)hanged version, (d)elete, or leave (u)nresolved? u
26850
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   722
  remote changed file2 which local deleted
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   723
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   724
  1 files updated, 0 files merged, 0 files removed, 2 files unresolved
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   725
  use 'hg resolve' to retry unresolved file merges
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   726
  [1]
26850
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   727
  $ status
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   728
  --- status ---
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   729
  A file1
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   730
  C file2
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   731
  C file3
27126
72b4e1bf8f28 test-merge-changedelete.t: add resolve --list output
Siddharth Agarwal <sid0@fb.com>
parents: 27125
diff changeset
   732
  --- resolve --list ---
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   733
  U file1
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   734
  U file2
27136
29b08ca680b0 test-merge-changedelete.t: print out debugmergestate
Siddharth Agarwal <sid0@fb.com>
parents: 27126
diff changeset
   735
  --- debugmergestate ---
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   736
  * version 2 records
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   737
  local: ab57bf49aa276a22d35a473592d4c34b5abc3eff
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   738
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28634
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   739
  labels:
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   740
    local: working copy
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   741
    other: destination
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   742
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   743
  file: file1 (record type "C", state "u", hash 60b27f004e454aca81b0480209cce5081ec52390)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   744
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   745
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   746
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   747
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   748
  file: file2 (record type "C", state "u", hash null)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   749
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   750
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   751
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   752
  --- file1 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   753
  1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   754
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   755
  --- file2 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   756
  2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   757
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   758
  --- file3 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   759
  3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   760
  changed1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   761
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   762
Choose local versions of files
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   763
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   764
  $ hg co -C 0
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   765
  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   766
  $ echo changed >> file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   767
  $ hg rm file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   768
  $ hg update 1 --tool :local
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   769
  1 files updated, 2 files merged, 0 files removed, 0 files unresolved
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   770
  $ status 2>&1 | tee $TESTTMP/local.status
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   771
  --- status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   772
  file2: * (glob)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   773
  A file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   774
  C file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   775
  --- resolve --list ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   776
  R file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   777
  R file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   778
  --- debugmergestate ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   779
  * version 2 records
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   780
  local: ab57bf49aa276a22d35a473592d4c34b5abc3eff
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   781
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28634
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   782
  labels:
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   783
    local: working copy
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   784
    other: destination
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   785
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   786
  file: file1 (record type "C", state "r", hash 60b27f004e454aca81b0480209cce5081ec52390)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   787
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   788
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   789
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   790
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   791
  file: file2 (record type "C", state "r", hash null)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   792
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   793
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   794
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   795
  --- file1 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   796
  1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   797
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   798
  *** file2 does not exist
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   799
  --- file3 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   800
  3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   801
  changed1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   802
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   803
Choose other versions of files
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   804
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   805
  $ hg co -C 0
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   806
  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   807
  $ echo changed >> file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   808
  $ hg rm file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   809
  $ hg update 1 --tool :other
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   810
  1 files updated, 1 files merged, 1 files removed, 0 files unresolved
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   811
  $ status 2>&1 | tee $TESTTMP/other.status
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   812
  --- status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   813
  file1: * (glob)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   814
  C file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   815
  C file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   816
  --- resolve --list ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   817
  R file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   818
  R file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   819
  --- debugmergestate ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   820
  * version 2 records
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   821
  local: ab57bf49aa276a22d35a473592d4c34b5abc3eff
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   822
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28634
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   823
  labels:
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   824
    local: working copy
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   825
    other: destination
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   826
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   827
  file: file1 (record type "C", state "r", hash 60b27f004e454aca81b0480209cce5081ec52390)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   828
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   829
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   830
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   831
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   832
  file: file2 (record type "C", state "r", hash null)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   833
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   834
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   835
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   836
  *** file1 does not exist
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   837
  --- file2 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   838
  2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   839
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   840
  --- file3 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   841
  3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   842
  changed1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   843
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   844
Fail
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   845
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   846
  $ hg co -C 0
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   847
  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   848
  $ echo changed >> file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   849
  $ hg rm file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   850
  $ hg update 1 --tool :fail
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   851
  1 files updated, 0 files merged, 0 files removed, 2 files unresolved
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   852
  use 'hg resolve' to retry unresolved file merges
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   853
  [1]
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   854
  $ status 2>&1 | tee $TESTTMP/fail.status
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   855
  --- status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   856
  A file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   857
  C file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   858
  C file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   859
  --- resolve --list ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   860
  U file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   861
  U file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   862
  --- debugmergestate ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   863
  * version 2 records
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   864
  local: ab57bf49aa276a22d35a473592d4c34b5abc3eff
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   865
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28634
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   866
  labels:
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   867
    local: working copy
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   868
    other: destination
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   869
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   870
  file: file1 (record type "C", state "u", hash 60b27f004e454aca81b0480209cce5081ec52390)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   871
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   872
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   873
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   874
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   875
  file: file2 (record type "C", state "u", hash null)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   876
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   877
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   878
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
26850
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   879
  --- file1 ---
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   880
  1
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   881
  changed
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   882
  --- file2 ---
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   883
  2
00209e38e7d9 test-merge-prompt.t: add tests for linear updates + change/delete conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 22589
diff changeset
   884
  changed
27125
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   885
  --- file3 ---
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   886
  3
969ca40cad1d test-merge-changedelete.t: add a file with regular merge conflicts
Siddharth Agarwal <sid0@fb.com>
parents: 26947
diff changeset
   887
  changed1
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   888
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   889
Force prompts with no input
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   890
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   891
  $ hg co -C 0
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   892
  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   893
  $ echo changed >> file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   894
  $ hg rm file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   895
  $ hg update 1 --config ui.interactive=True --tool :prompt
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   896
  local changed file1 which remote deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   897
  use (c)hanged version, (d)elete, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   898
  remote changed file2 which local deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
   899
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   900
  1 files updated, 0 files merged, 0 files removed, 2 files unresolved
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   901
  use 'hg resolve' to retry unresolved file merges
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   902
  [1]
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   903
  $ status 2>&1 | tee $TESTTMP/prompt.status
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   904
  --- status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   905
  A file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   906
  C file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   907
  C file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   908
  --- resolve --list ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   909
  U file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   910
  U file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   911
  --- debugmergestate ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   912
  * version 2 records
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   913
  local: ab57bf49aa276a22d35a473592d4c34b5abc3eff
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   914
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28634
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   915
  labels:
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   916
    local: working copy
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   917
    other: destination
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   918
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   919
  file: file1 (record type "C", state "u", hash 60b27f004e454aca81b0480209cce5081ec52390)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   920
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   921
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   922
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   923
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   924
  file: file2 (record type "C", state "u", hash null)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   925
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   926
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   927
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   928
  --- file1 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   929
  1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   930
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   931
  --- file2 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   932
  2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   933
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   934
  --- file3 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   935
  3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   936
  changed1
27557
28b5c4fcf48d tests: Solaris diff -U also emits "No differences encountered"
Danek Duvall <danek.duvall@oracle.com>
parents: 27164
diff changeset
   937
  $ cmp $TESTTMP/fail.status $TESTTMP/prompt.status || diff -U8 $TESTTMP/fail.status $TESTTMP/prompt.status
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   938
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   939
Choose to merge all files
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   940
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   941
  $ hg co -C 0
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   942
  3 files updated, 0 files merged, 0 files removed, 0 files unresolved
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   943
  $ echo changed >> file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   944
  $ hg rm file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   945
  $ hg update 1 --tool :merge3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   946
  local changed file1 which remote deleted
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   947
  use (c)hanged version, (d)elete, or leave (u)nresolved? u
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   948
  remote changed file2 which local deleted
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   949
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? u
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   950
  1 files updated, 0 files merged, 0 files removed, 2 files unresolved
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   951
  use 'hg resolve' to retry unresolved file merges
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   952
  [1]
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   953
  $ status
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   954
  --- status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   955
  A file1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   956
  C file2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   957
  C file3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   958
  --- resolve --list ---
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   959
  U file1
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   960
  U file2
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   961
  --- debugmergestate ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   962
  * version 2 records
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   963
  local: ab57bf49aa276a22d35a473592d4c34b5abc3eff
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   964
  other: 10f9a0a634e82080907e62f075ab119cbc565ea6
28634
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   965
  labels:
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   966
    local: working copy
3ceac01bc29f merge: save merge part labels for later reuse
Simon Farnsworth <simonfar@fb.com>
parents: 28029
diff changeset
   967
    other: destination
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   968
  file extras: file1 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   969
  file: file1 (record type "C", state "u", hash 60b27f004e454aca81b0480209cce5081ec52390)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   970
    local path: file1 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   971
    ancestor path: file1 (node b8e02f6433738021a065f94175c7cd23db5f05be)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   972
    other path: file1 (node null)
28011
8abd9f785030 merge: add file ancestor linknode to mergestate
Durham Goode <durham@fb.com>
parents: 27599
diff changeset
   973
  file extras: file2 (ancestorlinknode = ab57bf49aa276a22d35a473592d4c34b5abc3eff)
27599
ad5966de3c9a filemerge: default change/delete conflicts to 'leave unresolved' (BC)
Siddharth Agarwal <sid0@fb.com>
parents: 27557
diff changeset
   974
  file: file2 (record type "C", state "u", hash null)
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   975
    local path: file2 (flags "")
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   976
    ancestor path: file2 (node 5d9299349fc01ddd25d0070d149b124d8f10411e)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   977
    other path: file2 (node e7c1328648519852e723de86c0c0525acd779257)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   978
  --- file1 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   979
  1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   980
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   981
  --- file2 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   982
  2
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   983
  changed
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   984
  --- file3 ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   985
  3
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   986
  changed1
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   987
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   988
Test transitions between different merge tools
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   989
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   990
  $ testtransitions
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   991
  === :merge3 -> :local ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   992
  (no more unresolved files)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   993
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   994
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   995
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   996
  === :local -> :other ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   997
  (no more unresolved files)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   998
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
   999
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1000
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1001
  === :other -> :prompt ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1002
  local changed file1 which remote deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
  1003
  use (c)hanged version, (d)elete, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1004
  remote changed file2 which local deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
  1005
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1006
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1007
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1008
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1009
  === :prompt -> :local ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1010
  (no more unresolved files)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1011
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1012
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1013
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1014
  === :local -> :fail ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1015
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1016
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1017
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1018
  === :fail -> :other ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1019
  (no more unresolved files)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1020
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1021
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1022
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1023
  === :other -> :local ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1024
  (no more unresolved files)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1025
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1026
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1027
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1028
  === :local -> :prompt ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1029
  local changed file1 which remote deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
  1030
  use (c)hanged version, (d)elete, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1031
  remote changed file2 which local deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
  1032
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1033
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1034
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1035
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1036
  === :prompt -> :other ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1037
  (no more unresolved files)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1038
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1039
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1040
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1041
  === :other -> :fail ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1042
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1043
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1044
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1045
  === :fail -> :prompt ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1046
  local changed file1 which remote deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
  1047
  use (c)hanged version, (d)elete, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1048
  remote changed file2 which local deleted
27163
27b89a0957ec filemerge: add a 'leave unresolved' option to change/delete prompts
Siddharth Agarwal <sid0@fb.com>
parents: 27162
diff changeset
  1049
  use (c)hanged version, leave (d)eleted, or leave (u)nresolved? 
27137
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1050
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1051
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1052
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1053
  === :prompt -> :fail ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1054
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1055
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1056
  
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1057
  === :fail -> :local ===
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1058
  (no more unresolved files)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1059
  --- diff of status ---
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1060
  (status identical)
25e4b2f000c5 merge: move almost all change/delete conflicts to resolve phase (BC) (API)
Siddharth Agarwal <sid0@fb.com>
parents: 27136
diff changeset
  1061