tests/test-graft.t
author Matt Mackall <mpm@selenic.com>
Mon, 31 Oct 2011 15:41:39 -0500
branchstable
changeset 15392 d7bfbc92a1c0
parent 15361 c1930992e111
child 15501 2371f4aea665
child 15506 dc9fb7015d7f
permissions -rw-r--r--
util: add a doctest for empty sha() calls
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
15361
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
     1
Create a repo with some stuff in it:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
     2
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
     3
  $ hg init a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
     4
  $ cd a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
     5
  $ echo a > a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
     6
  $ echo a > d
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
     7
  $ echo a > e
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
     8
  $ hg ci -qAm0
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
     9
  $ echo b > a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    10
  $ hg ci -m1 -u bar
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    11
  $ hg mv a b
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    12
  $ hg ci -m2
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    13
  $ hg cp b c
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    14
  $ hg ci -m3 -u baz
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    15
  $ echo b > d
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    16
  $ echo f > e
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    17
  $ hg ci -m4
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    18
  $ hg up -q 3
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    19
  $ echo b > e
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    20
  $ hg branch -q stable
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    21
  $ hg ci -m5
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    22
  $ hg merge -q default --tool internal:local
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    23
  $ hg branch -q default
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    24
  $ hg ci -m6
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    25
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    26
Need to specify a rev:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    27
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    28
  $ hg graft
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    29
  abort: no revisions specified
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    30
  [255]
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    31
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    32
Can't graft ancestor:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    33
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    34
  $ hg graft 1 2
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    35
  skipping ancestor revision 1
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    36
  skipping ancestor revision 2
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    37
  [255]
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    38
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    39
Can't graft with dirty wd:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    40
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    41
  $ hg up -q 0
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    42
  $ echo foo > a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    43
  $ hg graft 1
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    44
  abort: outstanding uncommitted changes
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    45
  [255]
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    46
  $ hg revert a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    47
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    48
Graft a rename:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    49
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    50
  $ hg graft 2 -u foo
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    51
  grafting revision 2
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    52
  merging a and b to b
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    53
  $ hg export tip --git
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    54
  # HG changeset patch
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    55
  # User foo
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    56
  # Date 0 0
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    57
  # Node ID d2e44c99fd3f31c176ea4efb9eca9f6306c81756
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    58
  # Parent  68795b066622ca79a25816a662041d8f78f3cd9e
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    59
  2
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    60
  
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    61
  diff --git a/a b/b
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    62
  rename from a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    63
  rename to b
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    64
  --- a/a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    65
  +++ b/b
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    66
  @@ -1,1 +1,1 @@
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    67
  -a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    68
  +b
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    69
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    70
Look for extra:source
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    71
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    72
  $ hg log --debug -r tip
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    73
  changeset:   7:d2e44c99fd3f31c176ea4efb9eca9f6306c81756
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    74
  tag:         tip
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    75
  parent:      0:68795b066622ca79a25816a662041d8f78f3cd9e
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    76
  parent:      -1:0000000000000000000000000000000000000000
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    77
  manifest:    7:5d59766436fd8fbcd38e7bebef0f6eaf3eebe637
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    78
  user:        foo
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    79
  date:        Thu Jan 01 00:00:00 1970 +0000
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    80
  files+:      b
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    81
  files-:      a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    82
  extra:       branch=default
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    83
  extra:       source=5c095ad7e90f871700f02dd1fa5012cb4498a2d4
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    84
  description:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    85
  2
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    86
  
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    87
  
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    88
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    89
Graft out of order, skipping a merge and a duplicate
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    90
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    91
  $ hg graft 1 5 4 3 'merge()' 2 --debug
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    92
  skipping ungraftable merge revision 6
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    93
  scanning for duplicate grafts
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    94
  skipping already grafted revision 2
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    95
  grafting revision 1
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    96
    searching for copies back to rev 1
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    97
    unmatched files in local:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    98
     a.orig
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
    99
     b
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   100
    all copies found (* = to merge, ! = divergent):
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   101
     b -> a *
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   102
    checking for directory renames
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   103
  resolving manifests
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   104
   overwrite False partial False
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   105
   ancestor 68795b066622 local d2e44c99fd3f+ remote 5d205f8b35b6
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   106
   b: local copied/moved to a -> m
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   107
  preserving b for resolve of b
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   108
  updating: b 1/1 files (100.00%)
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   109
    searching for copies back to rev 1
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   110
    unmatched files in local:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   111
     a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   112
    unmatched files in other:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   113
     b
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   114
    all copies found (* = to merge, ! = divergent):
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   115
     b -> a *
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   116
    checking for directory renames
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   117
  b
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   118
   b: searching for copy revision for a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   119
   b: copy a:b789fdd96dc2f3bd229c1dd8eedf0fc60e2b68e3
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   120
  grafting revision 5
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   121
    searching for copies back to rev 1
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   122
    unmatched files in local:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   123
     a.orig
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   124
  resolving manifests
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   125
   overwrite False partial False
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   126
   ancestor 4c60f11aa304 local 6f5ea6ac8b70+ remote 97f8bfe72746
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   127
   e: remote is newer -> g
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   128
  updating: e 1/1 files (100.00%)
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   129
  getting e
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   130
    searching for copies back to rev 1
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   131
    unmatched files in local:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   132
     c
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   133
    all copies found (* = to merge, ! = divergent):
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   134
     c -> b *
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   135
    checking for directory renames
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   136
  e
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   137
  grafting revision 4
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   138
    searching for copies back to rev 1
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   139
    unmatched files in local:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   140
     a.orig
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   141
  resolving manifests
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   142
   overwrite False partial False
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   143
   ancestor 4c60f11aa304 local 77eb504366ab+ remote 9c233e8e184d
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   144
   e: versions differ -> m
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   145
   d: remote is newer -> g
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   146
  preserving e for resolve of e
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   147
  updating: d 1/2 files (50.00%)
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   148
  getting d
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   149
  updating: e 2/2 files (100.00%)
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   150
  picked tool 'internal:merge' for e (binary False symlink False)
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   151
  merging e
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   152
  my e@77eb504366ab+ other e@9c233e8e184d ancestor e@68795b066622
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   153
  warning: conflicts during merge.
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   154
  merging e failed!
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   155
    searching for copies back to rev 1
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   156
    unmatched files in local:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   157
     c
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   158
    all copies found (* = to merge, ! = divergent):
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   159
     c -> b *
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   160
    checking for directory renames
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   161
  abort: unresolved conflicts, can't continue
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   162
  (use hg resolve and hg graft --continue)
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   163
  [255]
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   164
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   165
Continue without resolve should fail:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   166
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   167
  $ hg graft -c
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   168
  grafting revision 4
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   169
  abort: unresolved merge conflicts (see hg help resolve)
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   170
  [255]
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   171
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   172
Fix up:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   173
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   174
  $ echo b > e
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   175
  $ hg resolve -m e
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   176
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   177
Continue with a revision should fail:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   178
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   179
  $ hg graft -c 6
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   180
  abort: can't specify --continue and revisions
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   181
  [255]
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   182
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   183
Continue for real, clobber usernames
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   184
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   185
  $ hg graft -c -U
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   186
  grafting revision 4
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   187
  grafting revision 3
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   188
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   189
Compare with original:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   190
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   191
  $ hg diff -r 6
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   192
  $ hg status --rev 0:. -C
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   193
  M d
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   194
  M e
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   195
  A b
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   196
    a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   197
  A c
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   198
    a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   199
  R a
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   200
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   201
View graph:
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   202
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   203
  $ hg --config extensions.graphlog= log -G --template '{author}@rev: {desc}\n'
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   204
  @  test@rev: 3
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   205
  |
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   206
  o  test@rev: 4
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   207
  |
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   208
  o  test@rev: 5
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   209
  |
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   210
  o  bar@rev: 1
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   211
  |
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   212
  o  foo@rev: 2
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   213
  |
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   214
  | o    test@rev: 6
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   215
  | |\
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   216
  | | o  test@rev: 5
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   217
  | | |
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   218
  | o |  test@rev: 4
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   219
  | |/
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   220
  | o  baz@rev: 3
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   221
  | |
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   222
  | o  test@rev: 2
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   223
  | |
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   224
  | o  bar@rev: 1
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   225
  |/
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   226
  o  test@rev: 0
c1930992e111 graft: add a test
Matt Mackall <mpm@selenic.com>
parents:
diff changeset
   227