tests/test-commit-interactive.t
author timeless <timeless@mozdev.org>
Wed, 06 Apr 2016 18:19:36 +0000
changeset 28815 44611ad4fbd9
parent 27478 baa9810ee3ec
child 28962 ad2cd2ef25d9
permissions -rw-r--r--
crecord: check for untracked arguments hg commit tracked untracked -- fails complaining about untracked prior to this commit, hg commit -i tracked untracked -- did not fail This is corrected by calling the refactored localrepo.checkcommitpatterns
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
12328
b63f6422d2a7 tests: fix a bunch of pointless #s in unified tests
Matt Mackall <mpm@selenic.com>
parents: 12316
diff changeset
     1
Set up a repo
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
     2
23172
e955549cd045 tests: write hgrc of more than two lines by using shell heredoc
Yuya Nishihara <yuya@tcha.org>
parents: 23054
diff changeset
     3
  $ cat <<EOF >> $HGRCPATH
e955549cd045 tests: write hgrc of more than two lines by using shell heredoc
Yuya Nishihara <yuya@tcha.org>
parents: 23054
diff changeset
     4
  > [ui]
e955549cd045 tests: write hgrc of more than two lines by using shell heredoc
Yuya Nishihara <yuya@tcha.org>
parents: 23054
diff changeset
     5
  > interactive = true
e955549cd045 tests: write hgrc of more than two lines by using shell heredoc
Yuya Nishihara <yuya@tcha.org>
parents: 23054
diff changeset
     6
  > [extensions]
e955549cd045 tests: write hgrc of more than two lines by using shell heredoc
Yuya Nishihara <yuya@tcha.org>
parents: 23054
diff changeset
     7
  > record =
e955549cd045 tests: write hgrc of more than two lines by using shell heredoc
Yuya Nishihara <yuya@tcha.org>
parents: 23054
diff changeset
     8
  > EOF
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
     9
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    10
  $ hg init a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    11
  $ cd a
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
    12
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    13
Select no files
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
    14
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    15
  $ touch empty-rw
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    16
  $ hg add empty-rw
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
    17
25796
4eb8d8a44bf1 record: omit meaningless 'commit' suggestion at 'hg commit -i'
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25759
diff changeset
    18
  $ hg record --config ui.interactive=false
4eb8d8a44bf1 record: omit meaningless 'commit' suggestion at 'hg commit -i'
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25759
diff changeset
    19
  abort: running non-interactively, use commit instead
4eb8d8a44bf1 record: omit meaningless 'commit' suggestion at 'hg commit -i'
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25759
diff changeset
    20
  [255]
4eb8d8a44bf1 record: omit meaningless 'commit' suggestion at 'hg commit -i'
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25759
diff changeset
    21
  $ hg commit -i --config ui.interactive=false
4eb8d8a44bf1 record: omit meaningless 'commit' suggestion at 'hg commit -i'
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25759
diff changeset
    22
  abort: running non-interactively
4eb8d8a44bf1 record: omit meaningless 'commit' suggestion at 'hg commit -i'
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25759
diff changeset
    23
  [255]
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
    24
  $ hg commit -i empty-rw<<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    25
  > n
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    26
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    27
  diff --git a/empty-rw b/empty-rw
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    28
  new file mode 100644
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
    29
  examine changes to 'empty-rw'? [Ynesfdaq?] n
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
    30
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    31
  no changes to record
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    32
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    33
  $ hg tip -p
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    34
  changeset:   -1:000000000000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    35
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    36
  user:        
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    37
  date:        Thu Jan 01 00:00:00 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    38
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    39
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    40
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    41
Select files but no hunks
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
    42
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
    43
  $ hg commit -i  empty-rw<<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    44
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    45
  > n
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    46
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    47
  diff --git a/empty-rw b/empty-rw
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    48
  new file mode 100644
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
    49
  examine changes to 'empty-rw'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
    50
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    51
  abort: empty commit message
12316
4134686b83e1 tests: add exit codes to unified tests
Matt Mackall <mpm@selenic.com>
parents: 12074
diff changeset
    52
  [255]
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    53
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    54
  $ hg tip -p
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    55
  changeset:   -1:000000000000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    56
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    57
  user:        
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    58
  date:        Thu Jan 01 00:00:00 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    59
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    60
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
    61
28815
44611ad4fbd9 crecord: check for untracked arguments
timeless <timeless@mozdev.org>
parents: 27478
diff changeset
    62
Abort for untracked
44611ad4fbd9 crecord: check for untracked arguments
timeless <timeless@mozdev.org>
parents: 27478
diff changeset
    63
44611ad4fbd9 crecord: check for untracked arguments
timeless <timeless@mozdev.org>
parents: 27478
diff changeset
    64
  $ touch untracked
44611ad4fbd9 crecord: check for untracked arguments
timeless <timeless@mozdev.org>
parents: 27478
diff changeset
    65
  $ hg commit -i -m should-fail empty-rw untracked
44611ad4fbd9 crecord: check for untracked arguments
timeless <timeless@mozdev.org>
parents: 27478
diff changeset
    66
  abort: untracked: file not tracked!
44611ad4fbd9 crecord: check for untracked arguments
timeless <timeless@mozdev.org>
parents: 27478
diff changeset
    67
  [255]
44611ad4fbd9 crecord: check for untracked arguments
timeless <timeless@mozdev.org>
parents: 27478
diff changeset
    68
  $ rm untracked
44611ad4fbd9 crecord: check for untracked arguments
timeless <timeless@mozdev.org>
parents: 27478
diff changeset
    69
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    70
Record empty file
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
    71
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
    72
  $ hg commit -i -d '0 0' -m empty empty-rw<<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    73
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    74
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    75
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    76
  diff --git a/empty-rw b/empty-rw
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    77
  new file mode 100644
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
    78
  examine changes to 'empty-rw'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
    79
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    80
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    81
  $ hg tip -p
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    82
  changeset:   0:c0708cf4e46e
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    83
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    84
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    85
  date:        Thu Jan 01 00:00:00 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    86
  summary:     empty
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    87
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    88
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
    89
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    90
Summary shows we updated to the new cset
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    91
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    92
  $ hg summary
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    93
  parent: 0:c0708cf4e46e tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    94
   empty
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    95
  branch: default
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    96
  commit: (clean)
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
    97
  update: (current)
25382
6084926366b9 summary: move the parents phase marker to commit line (issue4688)
Gilles Moris <gilles.moris@free.fr>
parents: 25111
diff changeset
    98
  phases: 1 draft
10964
aa0426c79664 test-record: add hg summary to verify we update dirstate
Augie Fackler <durin42@gmail.com>
parents: 8811
diff changeset
    99
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   100
Rename empty file
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   101
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   102
  $ hg mv empty-rw empty-rename
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   103
  $ hg commit -i -d '1 0' -m rename<<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   104
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   105
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   106
  diff --git a/empty-rw b/empty-rename
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   107
  rename from empty-rw
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   108
  rename to empty-rename
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   109
  examine changes to 'empty-rw' and 'empty-rename'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   110
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   111
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   112
  $ hg tip -p
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   113
  changeset:   1:d695e8dcb197
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   114
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   115
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   116
  date:        Thu Jan 01 00:00:01 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   117
  summary:     rename
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   118
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   119
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   120
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   121
Copy empty file
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   122
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   123
  $ hg cp empty-rename empty-copy
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   124
  $ hg commit -i -d '2 0' -m copy<<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   125
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   126
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   127
  diff --git a/empty-rename b/empty-copy
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   128
  copy from empty-rename
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   129
  copy to empty-copy
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   130
  examine changes to 'empty-rename' and 'empty-copy'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   131
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   132
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   133
  $ hg tip -p
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   134
  changeset:   2:1d4b90bea524
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   135
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   136
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   137
  date:        Thu Jan 01 00:00:02 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   138
  summary:     copy
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   139
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   140
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   141
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   142
Delete empty file
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   143
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   144
  $ hg rm empty-copy
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   145
  $ hg commit -i -d '3 0' -m delete<<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   146
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   147
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   148
  diff --git a/empty-copy b/empty-copy
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   149
  deleted file mode 100644
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   150
  examine changes to 'empty-copy'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   151
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   152
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   153
  $ hg tip -p
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   154
  changeset:   3:b39a238f01a1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   155
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   156
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   157
  date:        Thu Jan 01 00:00:03 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   158
  summary:     delete
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   159
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   160
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   161
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   162
Add binary file
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   163
26863
0879bf38ec84 test: enforce bundle1 in "test-commit-interactive.t"
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 25796
diff changeset
   164
  $ hg bundle --type v1 --base -2 tip.bundle
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   165
  1 changesets found
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   166
  $ hg add tip.bundle
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   167
  $ hg commit -i -d '4 0' -m binary<<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   168
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   169
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   170
  diff --git a/tip.bundle b/tip.bundle
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   171
  new file mode 100644
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   172
  this is a binary file
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   173
  examine changes to 'tip.bundle'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   174
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   175
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   176
  $ hg tip -p
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   177
  changeset:   4:ad816da3711e
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   178
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   179
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   180
  date:        Thu Jan 01 00:00:04 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   181
  summary:     binary
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   182
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   183
  diff -r b39a238f01a1 -r ad816da3711e tip.bundle
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   184
  Binary file tip.bundle has changed
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   185
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   186
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   187
Change binary file
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   188
26863
0879bf38ec84 test: enforce bundle1 in "test-commit-interactive.t"
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 25796
diff changeset
   189
  $ hg bundle --base -2 --type v1 tip.bundle
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   190
  1 changesets found
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   191
  $ hg commit -i -d '5 0' -m binary-change<<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   192
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   193
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   194
  diff --git a/tip.bundle b/tip.bundle
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   195
  this modifies a binary file (all or nothing)
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   196
  examine changes to 'tip.bundle'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   197
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   198
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   199
  $ hg tip -p
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   200
  changeset:   5:dccd6f3eb485
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   201
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   202
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   203
  date:        Thu Jan 01 00:00:05 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   204
  summary:     binary-change
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   205
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   206
  diff -r ad816da3711e -r dccd6f3eb485 tip.bundle
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   207
  Binary file tip.bundle has changed
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   208
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   209
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   210
Rename and change binary file
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   211
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   212
  $ hg mv tip.bundle top.bundle
26863
0879bf38ec84 test: enforce bundle1 in "test-commit-interactive.t"
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 25796
diff changeset
   213
  $ hg bundle --base -2 --type v1 top.bundle
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   214
  1 changesets found
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   215
  $ hg commit -i -d '6 0' -m binary-change-rename<<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   216
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   217
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   218
  diff --git a/tip.bundle b/top.bundle
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   219
  rename from tip.bundle
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   220
  rename to top.bundle
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   221
  this modifies a binary file (all or nothing)
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   222
  examine changes to 'tip.bundle' and 'top.bundle'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   223
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   224
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   225
  $ hg tip -p
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   226
  changeset:   6:7fa44105f5b3
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   227
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   228
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   229
  date:        Thu Jan 01 00:00:06 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   230
  summary:     binary-change-rename
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   231
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   232
  diff -r dccd6f3eb485 -r 7fa44105f5b3 tip.bundle
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   233
  Binary file tip.bundle has changed
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   234
  diff -r dccd6f3eb485 -r 7fa44105f5b3 top.bundle
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   235
  Binary file top.bundle has changed
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   236
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   237
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   238
Add plain file
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   239
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   240
  $ for i in 1 2 3 4 5 6 7 8 9 10; do
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   241
  >     echo $i >> plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   242
  > done
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   243
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   244
  $ hg add plain
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   245
  $ hg commit -i -d '7 0' -m plain plain<<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   246
  > y
24845
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   247
  > y
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   248
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   249
  diff --git a/plain b/plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   250
  new file mode 100644
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   251
  examine changes to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   252
  
24845
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   253
  @@ -0,0 +1,10 @@
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   254
  +1
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   255
  +2
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   256
  +3
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   257
  +4
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   258
  +5
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   259
  +6
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   260
  +7
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   261
  +8
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   262
  +9
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   263
  +10
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   264
  record this change to 'plain'? [Ynesfdaq?] y
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   265
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   266
  $ hg tip -p
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   267
  changeset:   7:11fb457c1be4
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   268
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   269
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   270
  date:        Thu Jan 01 00:00:07 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   271
  summary:     plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   272
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   273
  diff -r 7fa44105f5b3 -r 11fb457c1be4 plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   274
  --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   275
  +++ b/plain	Thu Jan 01 00:00:07 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   276
  @@ -0,0 +1,10 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   277
  +1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   278
  +2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   279
  +3
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   280
  +4
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   281
  +5
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   282
  +6
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   283
  +7
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   284
  +8
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   285
  +9
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   286
  +10
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   287
  
17446
3de04c07966a record: checks for valid username before starting recording process (issue3456)
Sumeet <sumeet@fb.com>
parents: 16913
diff changeset
   288
Modify end of plain file with username unset
3de04c07966a record: checks for valid username before starting recording process (issue3456)
Sumeet <sumeet@fb.com>
parents: 16913
diff changeset
   289
3de04c07966a record: checks for valid username before starting recording process (issue3456)
Sumeet <sumeet@fb.com>
parents: 16913
diff changeset
   290
  $ echo 11 >> plain
3de04c07966a record: checks for valid username before starting recording process (issue3456)
Sumeet <sumeet@fb.com>
parents: 16913
diff changeset
   291
  $ unset HGUSER
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   292
  $ hg commit -i --config ui.username= -d '8 0' -m end plain
20579
625533523c9e tests: fix up config --edit breakage
Matt Mackall <mpm@selenic.com>
parents: 20266
diff changeset
   293
  abort: no username supplied
20580
b75a23eec9c9 ui: fix extra space in username abort
Matt Mackall <mpm@selenic.com>
parents: 20579
diff changeset
   294
  (use "hg config --edit" to set your username)
17446
3de04c07966a record: checks for valid username before starting recording process (issue3456)
Sumeet <sumeet@fb.com>
parents: 16913
diff changeset
   295
  [255]
3de04c07966a record: checks for valid username before starting recording process (issue3456)
Sumeet <sumeet@fb.com>
parents: 16913
diff changeset
   296
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   297
18266
09a2b6741695 record: use patch.diffopts to account for user diffopts
Denis Laxalde <denis@laxalde.org>
parents: 17446
diff changeset
   298
Modify end of plain file, also test that diffopts are accounted for
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   299
17446
3de04c07966a record: checks for valid username before starting recording process (issue3456)
Sumeet <sumeet@fb.com>
parents: 16913
diff changeset
   300
  $ HGUSER="test"
3de04c07966a record: checks for valid username before starting recording process (issue3456)
Sumeet <sumeet@fb.com>
parents: 16913
diff changeset
   301
  $ export HGUSER
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   302
  $ hg commit -i --config diff.showfunc=true -d '8 0' -m end plain <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   303
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   304
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   305
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   306
  diff --git a/plain b/plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   307
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   308
  examine changes to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   309
  
18266
09a2b6741695 record: use patch.diffopts to account for user diffopts
Denis Laxalde <denis@laxalde.org>
parents: 17446
diff changeset
   310
  @@ -8,3 +8,4 @@ 7
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   311
   8
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   312
   9
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   313
   10
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   314
  +11
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   315
  record this change to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   316
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   317
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   318
Modify end of plain file, no EOL
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   319
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   320
  $ hg tip --template '{node}' >> plain
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   321
  $ hg commit -i -d '9 0' -m noeol plain <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   322
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   323
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   324
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   325
  diff --git a/plain b/plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   326
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   327
  examine changes to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   328
  
27411
c84a07530040 record: turn on showfunc
timeless <timeless@mozdev.org>
parents: 26863
diff changeset
   329
  @@ -9,3 +9,4 @@ 8
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   330
   9
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   331
   10
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   332
   11
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   333
  +7264f99c5f5ff3261504828afa4fb4d406c3af54
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   334
  \ No newline at end of file
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   335
  record this change to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   336
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   337
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   338
Record showfunc should preserve function across sections
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   339
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   340
  $ cat > f1.py <<EOF
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   341
  > def annotate(ui, repo, *pats, **opts):
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   342
  >     """show changeset information by line for each file
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   343
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   344
  >     List changes in files, showing the revision id responsible for
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   345
  >     each line.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   346
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   347
  >     This command is useful for discovering when a change was made and
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   348
  >     by whom.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   349
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   350
  >     If you include -f/-u/-d, the revision number is suppressed unless
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   351
  >     you also include -the revision number is suppressed unless
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   352
  >     you also include -n.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   353
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   354
  >     Without the -a/--text option, annotate will avoid processing files
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   355
  >     it detects as binary. With -a, annotate will annotate the file
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   356
  >     anyway, although the results will probably be neither useful
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   357
  >     nor desirable.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   358
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   359
  >     Returns 0 on success.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   360
  >     """
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   361
  >     return 0
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   362
  > def archive(ui, repo, dest, **opts):
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   363
  >     '''create an unversioned archive of a repository revision
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   364
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   365
  >     By default, the revision used is the parent of the working
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   366
  >     directory; use -r/--rev to specify a different revision.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   367
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   368
  >     The archive type is automatically detected based on file
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   369
  >     extension (to override, use -t/--type).
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   370
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   371
  >     .. container:: verbose
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   372
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   373
  >     Valid types are:
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   374
  > EOF
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   375
  $ hg add f1.py
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   376
  $ hg commit -m funcs
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   377
  $ cat > f1.py <<EOF
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   378
  > def annotate(ui, repo, *pats, **opts):
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   379
  >     """show changeset information by line for each file
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   380
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   381
  >     List changes in files, showing the revision id responsible for
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   382
  >     each line
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   383
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   384
  >     This command is useful for discovering when a change was made and
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   385
  >     by whom.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   386
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   387
  >     Without the -a/--text option, annotate will avoid processing files
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   388
  >     it detects as binary. With -a, annotate will annotate the file
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   389
  >     anyway, although the results will probably be neither useful
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   390
  >     nor desirable.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   391
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   392
  >     Returns 0 on success.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   393
  >     """
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   394
  >     return 0
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   395
  > def archive(ui, repo, dest, **opts):
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   396
  >     '''create an unversioned archive of a repository revision
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   397
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   398
  >     By default, the revision used is the parent of the working
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   399
  >     directory; use -r/--rev to specify a different revision.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   400
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   401
  >     The archive type is automatically detected based on file
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   402
  >     extension (or override using -t/--type).
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   403
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   404
  >     .. container:: verbose
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   405
  > 
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   406
  >     Valid types are:
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   407
  > EOF
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   408
  $ hg commit -i -m interactive <<EOF
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   409
  > y
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   410
  > y
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   411
  > y
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   412
  > y
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   413
  > EOF
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   414
  diff --git a/f1.py b/f1.py
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   415
  3 hunks, 6 lines changed
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   416
  examine changes to 'f1.py'? [Ynesfdaq?] y
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   417
  
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   418
  @@ -2,8 +2,8 @@ def annotate(ui, repo, *pats, **opts):
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   419
       """show changeset information by line for each file
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   420
   
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   421
       List changes in files, showing the revision id responsible for
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   422
  -    each line.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   423
  +    each line
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   424
   
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   425
       This command is useful for discovering when a change was made and
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   426
       by whom.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   427
   
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   428
  record change 1/3 to 'f1.py'? [Ynesfdaq?] y
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   429
  
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   430
  @@ -6,11 +6,7 @@ def annotate(ui, repo, *pats, **opts):
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   431
   
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   432
       This command is useful for discovering when a change was made and
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   433
       by whom.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   434
   
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   435
  -    If you include -f/-u/-d, the revision number is suppressed unless
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   436
  -    you also include -the revision number is suppressed unless
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   437
  -    you also include -n.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   438
  -
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   439
       Without the -a/--text option, annotate will avoid processing files
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   440
       it detects as binary. With -a, annotate will annotate the file
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   441
       anyway, although the results will probably be neither useful
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   442
  record change 2/3 to 'f1.py'? [Ynesfdaq?] y
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   443
  
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   444
  @@ -26,7 +22,7 @@ def archive(ui, repo, dest, **opts):
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   445
       directory; use -r/--rev to specify a different revision.
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   446
   
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   447
       The archive type is automatically detected based on file
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   448
  -    extension (to override, use -t/--type).
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   449
  +    extension (or override using -t/--type).
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   450
   
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   451
       .. container:: verbose
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   452
   
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   453
  record change 3/3 to 'f1.py'? [Ynesfdaq?] y
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   454
  
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   455
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   456
Modify end of plain file, add EOL
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   457
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   458
  $ echo >> plain
13292
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   459
  $ echo 1 > plain2
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   460
  $ hg add plain2
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   461
  $ hg commit -i -d '10 0' -m eol plain plain2 <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   462
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   463
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   464
  > y
24845
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   465
  > y
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   466
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   467
  diff --git a/plain b/plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   468
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   469
  examine changes to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   470
  
27411
c84a07530040 record: turn on showfunc
timeless <timeless@mozdev.org>
parents: 26863
diff changeset
   471
  @@ -9,4 +9,4 @@ 8
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   472
   9
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   473
   10
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   474
   11
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   475
  -7264f99c5f5ff3261504828afa4fb4d406c3af54
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   476
  \ No newline at end of file
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   477
  +7264f99c5f5ff3261504828afa4fb4d406c3af54
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   478
  record change 1/2 to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   479
  
13292
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   480
  diff --git a/plain2 b/plain2
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   481
  new file mode 100644
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   482
  examine changes to 'plain2'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   483
  
24845
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   484
  @@ -0,0 +1,1 @@
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   485
  +1
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   486
  record change 2/2 to 'plain2'? [Ynesfdaq?] y
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
   487
  
13292
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   488
Modify beginning, trim end, record both, add another file to test
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   489
changes numbering
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   490
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   491
  $ rm plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   492
  $ for i in 2 2 3 4 5 6 7 8 9 10; do
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   493
  >   echo $i >> plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   494
  > done
13292
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   495
  $ echo 2 >> plain2
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   496
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   497
  $ hg commit -i -d '10 0' -m begin-and-end plain plain2 <<EOF
13292
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   498
  > y
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   499
  > y
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   500
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   501
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   502
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   503
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   504
  diff --git a/plain b/plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   505
  2 hunks, 3 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   506
  examine changes to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   507
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   508
  @@ -1,4 +1,4 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   509
  -1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   510
  +2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   511
   2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   512
   3
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   513
   4
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   514
  record change 1/3 to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   515
  
27411
c84a07530040 record: turn on showfunc
timeless <timeless@mozdev.org>
parents: 26863
diff changeset
   516
  @@ -8,5 +8,3 @@ 7
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   517
   8
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   518
   9
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   519
   10
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   520
  -11
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   521
  -7264f99c5f5ff3261504828afa4fb4d406c3af54
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   522
  record change 2/3 to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   523
  
13292
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   524
  diff --git a/plain2 b/plain2
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   525
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   526
  examine changes to 'plain2'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   527
  
13292
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   528
  @@ -1,1 +1,2 @@
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   529
   1
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   530
  +2
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   531
  record change 3/3 to 'plain2'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   532
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   533
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   534
  $ hg tip -p
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   535
  changeset:   13:f941910cff62
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   536
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   537
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   538
  date:        Thu Jan 01 00:00:10 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   539
  summary:     begin-and-end
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   540
  
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   541
  diff -r 33abe24d946c -r f941910cff62 plain
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   542
  --- a/plain	Thu Jan 01 00:00:10 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   543
  +++ b/plain	Thu Jan 01 00:00:10 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   544
  @@ -1,4 +1,4 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   545
  -1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   546
  +2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   547
   2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   548
   3
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   549
   4
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   550
  @@ -8,5 +8,3 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   551
   8
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   552
   9
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   553
   10
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   554
  -11
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   555
  -7264f99c5f5ff3261504828afa4fb4d406c3af54
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   556
  diff -r 33abe24d946c -r f941910cff62 plain2
13292
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   557
  --- a/plain2	Thu Jan 01 00:00:10 1970 +0000
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   558
  +++ b/plain2	Thu Jan 01 00:00:10 1970 +0000
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   559
  @@ -1,1 +1,2 @@
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   560
   1
d32e09769048 test-record: test peculiar changes numbering
Patrick Mezard <pmezard@gmail.com>
parents: 13023
diff changeset
   561
  +2
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   562
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   563
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   564
Trim beginning, modify end
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   565
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   566
  $ rm plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   567
  > for i in 4 5 6 7 8 9 10.new; do
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   568
  >   echo $i >> plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   569
  > done
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   570
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   571
Record end
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   572
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   573
  $ hg commit -i -d '11 0' -m end-only plain <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   574
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   575
  > n
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   576
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   577
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   578
  diff --git a/plain b/plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   579
  2 hunks, 4 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   580
  examine changes to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   581
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   582
  @@ -1,9 +1,6 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   583
  -2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   584
  -2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   585
  -3
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   586
   4
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   587
   5
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   588
   6
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   589
   7
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   590
   8
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   591
   9
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   592
  record change 1/2 to 'plain'? [Ynesfdaq?] n
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   593
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   594
  @@ -4,7 +1,7 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   595
   4
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   596
   5
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   597
   6
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   598
   7
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   599
   8
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   600
   9
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   601
  -10
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   602
  +10.new
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   603
  record change 2/2 to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   604
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   605
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   606
  $ hg tip -p
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   607
  changeset:   14:4915f538659b
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   608
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   609
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   610
  date:        Thu Jan 01 00:00:11 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   611
  summary:     end-only
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   612
  
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   613
  diff -r f941910cff62 -r 4915f538659b plain
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   614
  --- a/plain	Thu Jan 01 00:00:10 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   615
  +++ b/plain	Thu Jan 01 00:00:11 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   616
  @@ -7,4 +7,4 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   617
   7
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   618
   8
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   619
   9
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   620
  -10
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   621
  +10.new
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   622
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   623
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   624
Record beginning
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   625
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   626
  $ hg commit -i -d '12 0' -m begin-only plain <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   627
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   628
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   629
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   630
  diff --git a/plain b/plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   631
  1 hunks, 3 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   632
  examine changes to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   633
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   634
  @@ -1,6 +1,3 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   635
  -2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   636
  -2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   637
  -3
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   638
   4
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   639
   5
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   640
   6
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   641
  record this change to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   642
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   643
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   644
  $ hg tip -p
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   645
  changeset:   15:1b1f93d4b94b
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   646
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   647
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   648
  date:        Thu Jan 01 00:00:12 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   649
  summary:     begin-only
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   650
  
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   651
  diff -r 4915f538659b -r 1b1f93d4b94b plain
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   652
  --- a/plain	Thu Jan 01 00:00:11 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   653
  +++ b/plain	Thu Jan 01 00:00:12 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   654
  @@ -1,6 +1,3 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   655
  -2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   656
  -2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   657
  -3
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   658
   4
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   659
   5
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   660
   6
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   661
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   662
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   663
Add to beginning, trim from end
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   664
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   665
  $ rm plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   666
  $ for i in 1 2 3 4 5 6 7 8 9; do
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   667
  >  echo $i >> plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   668
  > done
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   669
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   670
Record end
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   671
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   672
  $ hg commit -i --traceback -d '13 0' -m end-again plain<<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   673
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   674
  > n
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   675
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   676
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   677
  diff --git a/plain b/plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   678
  2 hunks, 4 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   679
  examine changes to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   680
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   681
  @@ -1,6 +1,9 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   682
  +1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   683
  +2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   684
  +3
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   685
   4
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   686
   5
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   687
   6
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   688
   7
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   689
   8
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   690
   9
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   691
  record change 1/2 to 'plain'? [Ynesfdaq?] n
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   692
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   693
  @@ -1,7 +4,6 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   694
   4
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   695
   5
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   696
   6
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   697
   7
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   698
   8
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   699
   9
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   700
  -10.new
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   701
  record change 2/2 to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   702
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   703
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   704
Add to beginning, middle, end
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   705
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   706
  $ rm plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   707
  $ for i in 1 2 3 4 5 5.new 5.reallynew 6 7 8 9 10 11; do
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   708
  >   echo $i >> plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   709
  > done
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   710
23435
486a1fe09422 record: don't honor format-changing diffopts (issue4459)
Siddharth Agarwal <sid0@fb.com>
parents: 23172
diff changeset
   711
Record beginning, middle, and test that format-breaking diffopts are ignored
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   712
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   713
  $ hg commit -i --config diff.noprefix=True -d '14 0' -m middle-only plain <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   714
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   715
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   716
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   717
  > n
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   718
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   719
  diff --git a/plain b/plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   720
  3 hunks, 7 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   721
  examine changes to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   722
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   723
  @@ -1,2 +1,5 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   724
  +1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   725
  +2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   726
  +3
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   727
   4
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   728
   5
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   729
  record change 1/3 to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   730
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   731
  @@ -1,6 +4,8 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   732
   4
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   733
   5
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   734
  +5.new
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   735
  +5.reallynew
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   736
   6
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   737
   7
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   738
   8
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   739
   9
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   740
  record change 2/3 to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   741
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   742
  @@ -3,4 +8,6 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   743
   6
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   744
   7
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   745
   8
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   746
   9
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   747
  +10
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   748
  +11
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   749
  record change 3/3 to 'plain'? [Ynesfdaq?] n
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   750
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   751
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   752
  $ hg tip -p
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   753
  changeset:   17:41cf3f5c55ae
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   754
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   755
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   756
  date:        Thu Jan 01 00:00:14 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   757
  summary:     middle-only
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   758
  
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   759
  diff -r a69d252246e1 -r 41cf3f5c55ae plain
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   760
  --- a/plain	Thu Jan 01 00:00:13 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   761
  +++ b/plain	Thu Jan 01 00:00:14 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   762
  @@ -1,5 +1,10 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   763
  +1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   764
  +2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   765
  +3
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   766
   4
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   767
   5
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   768
  +5.new
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   769
  +5.reallynew
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   770
   6
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   771
   7
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   772
   8
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   773
  
5037
b2607267236d Add record extension, giving darcs-like interactive hunk picking
Bryan O'Sullivan <bos@serpentine.com>
parents:
diff changeset
   774
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   775
Record end
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   776
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   777
  $ hg commit -i -d '15 0' -m end-only plain <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   778
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   779
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   780
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   781
  diff --git a/plain b/plain
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   782
  1 hunks, 2 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   783
  examine changes to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   784
  
27411
c84a07530040 record: turn on showfunc
timeless <timeless@mozdev.org>
parents: 26863
diff changeset
   785
  @@ -9,3 +9,5 @@ 6
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   786
   7
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   787
   8
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   788
   9
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   789
  +10
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   790
  +11
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   791
  record this change to 'plain'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   792
  
5128
c9126c24e098 record: work properly if invoked in a subdirectory
Bryan O'Sullivan <bos@serpentine.com>
parents: 5037
diff changeset
   793
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   794
  $ hg tip -p
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   795
  changeset:   18:58a72f46bc24
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   796
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   797
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   798
  date:        Thu Jan 01 00:00:15 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   799
  summary:     end-only
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   800
  
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   801
  diff -r 41cf3f5c55ae -r 58a72f46bc24 plain
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   802
  --- a/plain	Thu Jan 01 00:00:14 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   803
  +++ b/plain	Thu Jan 01 00:00:15 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   804
  @@ -9,3 +9,5 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   805
   7
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   806
   8
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   807
   9
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   808
  +10
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   809
  +11
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   810
  
5128
c9126c24e098 record: work properly if invoked in a subdirectory
Bryan O'Sullivan <bos@serpentine.com>
parents: 5037
diff changeset
   811
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   812
  $ mkdir subdir
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   813
  $ cd subdir
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   814
  $ echo a > a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   815
  $ hg ci -d '16 0' -Amsubdir
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   816
  adding subdir/a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   817
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   818
  $ echo a >> a
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   819
  $ hg commit -i -d '16 0' -m subdir-change a <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   820
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   821
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   822
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   823
  diff --git a/subdir/a b/subdir/a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   824
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   825
  examine changes to 'subdir/a'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   826
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   827
  @@ -1,1 +1,2 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   828
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   829
  +a
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   830
  record this change to 'subdir/a'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   831
  
5154
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   832
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   833
  $ hg tip -p
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   834
  changeset:   20:e0f6b99f6c49
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   835
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   836
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   837
  date:        Thu Jan 01 00:00:16 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   838
  summary:     subdir-change
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   839
  
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   840
  diff -r abd26b51de37 -r e0f6b99f6c49 subdir/a
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   841
  --- a/subdir/a	Thu Jan 01 00:00:16 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   842
  +++ b/subdir/a	Thu Jan 01 00:00:16 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   843
  @@ -1,1 +1,2 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   844
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   845
  +a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   846
  
5154
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   847
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   848
  $ echo a > f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   849
  $ echo b > f2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   850
  $ hg add f1 f2
5154
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   851
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   852
  $ hg ci -mz -d '17 0'
5154
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   853
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   854
  $ echo a >> f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   855
  $ echo b >> f2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   856
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   857
Help, quit
5154
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   858
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   859
  $ hg commit -i <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   860
  > ?
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   861
  > q
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   862
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   863
  diff --git a/subdir/f1 b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   864
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   865
  examine changes to 'subdir/f1'? [Ynesfdaq?] ?
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   866
  
20266
061766323061 record: use "ui.extractchoices()" to get the list of available responses
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 20171
diff changeset
   867
  y - yes, record this change
061766323061 record: use "ui.extractchoices()" to get the list of available responses
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 20171
diff changeset
   868
  n - no, skip this change
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
   869
  e - edit this change manually
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   870
  s - skip remaining changes to this file
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   871
  f - record remaining changes to this file
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   872
  d - done, skip remaining changes and files
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   873
  a - record all changes to all remaining files
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   874
  q - quit, recording no changes
20266
061766323061 record: use "ui.extractchoices()" to get the list of available responses
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 20171
diff changeset
   875
  ? - ? (display help)
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   876
  examine changes to 'subdir/f1'? [Ynesfdaq?] q
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   877
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   878
  abort: user quit
12316
4134686b83e1 tests: add exit codes to unified tests
Matt Mackall <mpm@selenic.com>
parents: 12074
diff changeset
   879
  [255]
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   880
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   881
Skip
5154
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   882
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   883
  $ hg commit -i <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   884
  > s
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   885
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   886
  diff --git a/subdir/f1 b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   887
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   888
  examine changes to 'subdir/f1'? [Ynesfdaq?] s
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   889
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   890
  diff --git a/subdir/f2 b/subdir/f2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   891
  1 hunks, 1 lines changed
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
   892
  examine changes to 'subdir/f2'? [Ynesfdaq?] abort: response expected
12316
4134686b83e1 tests: add exit codes to unified tests
Matt Mackall <mpm@selenic.com>
parents: 12074
diff changeset
   893
  [255]
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   894
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   895
No
5154
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   896
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   897
  $ hg commit -i <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   898
  > n
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   899
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   900
  diff --git a/subdir/f1 b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   901
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   902
  examine changes to 'subdir/f1'? [Ynesfdaq?] n
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   903
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   904
  diff --git a/subdir/f2 b/subdir/f2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   905
  1 hunks, 1 lines changed
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
   906
  examine changes to 'subdir/f2'? [Ynesfdaq?] abort: response expected
12316
4134686b83e1 tests: add exit codes to unified tests
Matt Mackall <mpm@selenic.com>
parents: 12074
diff changeset
   907
  [255]
5154
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   908
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   909
f, quit
5154
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   910
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   911
  $ hg commit -i <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   912
  > f
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   913
  > q
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   914
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   915
  diff --git a/subdir/f1 b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   916
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   917
  examine changes to 'subdir/f1'? [Ynesfdaq?] f
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   918
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   919
  diff --git a/subdir/f2 b/subdir/f2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   920
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   921
  examine changes to 'subdir/f2'? [Ynesfdaq?] q
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   922
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   923
  abort: user quit
12316
4134686b83e1 tests: add exit codes to unified tests
Matt Mackall <mpm@selenic.com>
parents: 12074
diff changeset
   924
  [255]
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   925
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   926
s, all
5154
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   927
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   928
  $ hg commit -i -d '18 0' -mx <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   929
  > s
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   930
  > a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   931
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   932
  diff --git a/subdir/f1 b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   933
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   934
  examine changes to 'subdir/f1'? [Ynesfdaq?] s
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   935
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   936
  diff --git a/subdir/f2 b/subdir/f2
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   937
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   938
  examine changes to 'subdir/f2'? [Ynesfdaq?] a
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   939
  
5154
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   940
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   941
  $ hg tip -p
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   942
  changeset:   22:6afbbefacf35
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   943
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   944
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   945
  date:        Thu Jan 01 00:00:18 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   946
  summary:     x
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   947
  
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   948
  diff -r b73c401c693c -r 6afbbefacf35 subdir/f2
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   949
  --- a/subdir/f2	Thu Jan 01 00:00:17 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   950
  +++ b/subdir/f2	Thu Jan 01 00:00:18 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   951
  @@ -1,1 +1,2 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   952
   b
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   953
  +b
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   954
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   955
5154
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   956
f
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   957
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   958
  $ hg commit -i -d '19 0' -my <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   959
  > f
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   960
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   961
  diff --git a/subdir/f1 b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   962
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   963
  examine changes to 'subdir/f1'? [Ynesfdaq?] f
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   964
  
5154
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   965
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   966
  $ hg tip -p
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   967
  changeset:   23:715028a33949
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   968
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   969
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   970
  date:        Thu Jan 01 00:00:19 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   971
  summary:     y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   972
  
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
   973
  diff -r 6afbbefacf35 -r 715028a33949 subdir/f1
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   974
  --- a/subdir/f1	Thu Jan 01 00:00:18 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   975
  +++ b/subdir/f1	Thu Jan 01 00:00:19 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   976
  @@ -1,1 +1,2 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   977
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   978
  +a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   979
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   980
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
   981
#if execbit
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
   982
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   983
Preserve chmod +x
5154
67afecb8d6cc record: improve docs, improve prompts
Bryan O'Sullivan <bos@serpentine.com>
parents: 5128
diff changeset
   984
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   985
  $ chmod +x f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   986
  $ echo a >> f1
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
   987
  $ hg commit -i -d '20 0' -mz <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   988
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   989
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   990
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   991
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   992
  diff --git a/subdir/f1 b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   993
  old mode 100644
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   994
  new mode 100755
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   995
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   996
  examine changes to 'subdir/f1'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
   997
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   998
  @@ -1,2 +1,3 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
   999
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1000
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1001
  +a
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1002
  record this change to 'subdir/f1'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1003
  
7718
6fa7b6fb90a9 record: do not lose permission changes on commit
Steve Borho <steve@borho.org>
parents: 5154
diff changeset
  1004
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1005
  $ hg tip --config diff.git=True -p
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
  1006
  changeset:   24:db967c1e5884
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1007
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1008
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1009
  date:        Thu Jan 01 00:00:20 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1010
  summary:     z
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1011
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1012
  diff --git a/subdir/f1 b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1013
  old mode 100644
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1014
  new mode 100755
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1015
  --- a/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1016
  +++ b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1017
  @@ -1,2 +1,3 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1018
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1019
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1020
  +a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1021
  
7718
6fa7b6fb90a9 record: do not lose permission changes on commit
Steve Borho <steve@borho.org>
parents: 5154
diff changeset
  1022
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1023
Preserve execute permission on original
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1024
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1025
  $ echo b >> f1
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
  1026
  $ hg commit -i -d '21 0' -maa <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1027
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1028
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1029
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1030
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1031
  diff --git a/subdir/f1 b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1032
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1033
  examine changes to 'subdir/f1'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1034
  
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1035
  @@ -1,3 +1,4 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1036
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1037
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1038
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1039
  +b
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1040
  record this change to 'subdir/f1'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1041
  
7718
6fa7b6fb90a9 record: do not lose permission changes on commit
Steve Borho <steve@borho.org>
parents: 5154
diff changeset
  1042
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1043
  $ hg tip --config diff.git=True -p
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
  1044
  changeset:   25:88903aef81c3
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1045
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1046
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1047
  date:        Thu Jan 01 00:00:21 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1048
  summary:     aa
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1049
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1050
  diff --git a/subdir/f1 b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1051
  --- a/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1052
  +++ b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1053
  @@ -1,3 +1,4 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1054
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1055
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1056
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1057
  +b
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1058
  
7718
6fa7b6fb90a9 record: do not lose permission changes on commit
Steve Borho <steve@borho.org>
parents: 5154
diff changeset
  1059
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1060
Preserve chmod -x
7718
6fa7b6fb90a9 record: do not lose permission changes on commit
Steve Borho <steve@borho.org>
parents: 5154
diff changeset
  1061
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1062
  $ chmod -x f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1063
  $ echo c >> f1
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
  1064
  $ hg commit -i -d '22 0' -mab <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1065
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1066
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1067
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1068
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1069
  diff --git a/subdir/f1 b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1070
  old mode 100755
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1071
  new mode 100644
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1072
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1073
  examine changes to 'subdir/f1'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1074
  
27411
c84a07530040 record: turn on showfunc
timeless <timeless@mozdev.org>
parents: 26863
diff changeset
  1075
  @@ -2,3 +2,4 @@ a
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1076
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1077
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1078
   b
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1079
  +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: 20580
diff changeset
  1080
  record this change to 'subdir/f1'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1081
  
8811
8b35b08724eb Make mq, record and transplant honor patch.eol
Patrick Mezard <pmezard@gmail.com>
parents: 7718
diff changeset
  1082
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1083
  $ hg tip --config diff.git=True -p
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
  1084
  changeset:   26:7af84b6cf560
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1085
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1086
  user:        test
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1087
  date:        Thu Jan 01 00:00:22 1970 +0000
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1088
  summary:     ab
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1089
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1090
  diff --git a/subdir/f1 b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1091
  old mode 100755
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1092
  new mode 100644
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1093
  --- a/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1094
  +++ b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1095
  @@ -2,3 +2,4 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1096
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1097
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1098
   b
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1099
  +c
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1100
  
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1101
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1102
#else
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1103
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1104
Slightly bogus tests to get almost same repo structure as when x bit is used
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1105
- but with different hashes.
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1106
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1107
Mock "Preserve chmod +x"
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1108
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1109
  $ echo a >> f1
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
  1110
  $ hg commit -i -d '20 0' -mz <<EOF
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1111
  > y
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1112
  > y
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1113
  > y
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1114
  > EOF
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1115
  diff --git a/subdir/f1 b/subdir/f1
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1116
  1 hunks, 1 lines changed
23054
40c01f95449b tests: adjust expected prompt choice outputs in test-record.t for Windows
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 22589
diff changeset
  1117
  examine changes to 'subdir/f1'? [Ynesfdaq?] y
40c01f95449b tests: adjust expected prompt choice outputs in test-record.t for Windows
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 22589
diff changeset
  1118
  
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1119
  @@ -1,2 +1,3 @@
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1120
   a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1121
   a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1122
  +a
23054
40c01f95449b tests: adjust expected prompt choice outputs in test-record.t for Windows
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 22589
diff changeset
  1123
  record this change to 'subdir/f1'? [Ynesfdaq?] y
40c01f95449b tests: adjust expected prompt choice outputs in test-record.t for Windows
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 22589
diff changeset
  1124
  
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1125
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1126
  $ hg tip --config diff.git=True -p
27478
baa9810ee3ec test-commit-interactive: updates for the no-execbit case
Matt Harbison <matt_harbison@yahoo.com>
parents: 27412
diff changeset
  1127
  changeset:   24:c26cfe2c4eb0
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1128
  tag:         tip
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1129
  user:        test
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1130
  date:        Thu Jan 01 00:00:20 1970 +0000
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1131
  summary:     z
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1132
  
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1133
  diff --git a/subdir/f1 b/subdir/f1
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1134
  --- a/subdir/f1
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1135
  +++ b/subdir/f1
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1136
  @@ -1,2 +1,3 @@
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1137
   a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1138
   a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1139
  +a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1140
  
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1141
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1142
Mock "Preserve execute permission on original"
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1143
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1144
  $ echo b >> f1
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
  1145
  $ hg commit -i -d '21 0' -maa <<EOF
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1146
  > y
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1147
  > y
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1148
  > y
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1149
  > EOF
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1150
  diff --git a/subdir/f1 b/subdir/f1
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1151
  1 hunks, 1 lines changed
23054
40c01f95449b tests: adjust expected prompt choice outputs in test-record.t for Windows
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 22589
diff changeset
  1152
  examine changes to 'subdir/f1'? [Ynesfdaq?] y
40c01f95449b tests: adjust expected prompt choice outputs in test-record.t for Windows
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 22589
diff changeset
  1153
  
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1154
  @@ -1,3 +1,4 @@
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1155
   a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1156
   a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1157
   a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1158
  +b
23054
40c01f95449b tests: adjust expected prompt choice outputs in test-record.t for Windows
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 22589
diff changeset
  1159
  record this change to 'subdir/f1'? [Ynesfdaq?] y
40c01f95449b tests: adjust expected prompt choice outputs in test-record.t for Windows
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 22589
diff changeset
  1160
  
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1161
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1162
  $ hg tip --config diff.git=True -p
27478
baa9810ee3ec test-commit-interactive: updates for the no-execbit case
Matt Harbison <matt_harbison@yahoo.com>
parents: 27412
diff changeset
  1163
  changeset:   25:a48d2d60adde
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1164
  tag:         tip
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1165
  user:        test
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1166
  date:        Thu Jan 01 00:00:21 1970 +0000
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1167
  summary:     aa
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1168
  
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1169
  diff --git a/subdir/f1 b/subdir/f1
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1170
  --- a/subdir/f1
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1171
  +++ b/subdir/f1
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1172
  @@ -1,3 +1,4 @@
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1173
   a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1174
   a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1175
   a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1176
  +b
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1177
  
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1178
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1179
Mock "Preserve chmod -x"
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1180
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1181
  $ chmod -x f1
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1182
  $ echo c >> f1
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
  1183
  $ hg commit -i -d '22 0' -mab <<EOF
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1184
  > y
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1185
  > y
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1186
  > y
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1187
  > EOF
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1188
  diff --git a/subdir/f1 b/subdir/f1
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1189
  1 hunks, 1 lines changed
23054
40c01f95449b tests: adjust expected prompt choice outputs in test-record.t for Windows
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 22589
diff changeset
  1190
  examine changes to 'subdir/f1'? [Ynesfdaq?] y
40c01f95449b tests: adjust expected prompt choice outputs in test-record.t for Windows
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 22589
diff changeset
  1191
  
27478
baa9810ee3ec test-commit-interactive: updates for the no-execbit case
Matt Harbison <matt_harbison@yahoo.com>
parents: 27412
diff changeset
  1192
  @@ -2,3 +2,4 @@ a
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1193
   a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1194
   a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1195
   b
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1196
  +c
23054
40c01f95449b tests: adjust expected prompt choice outputs in test-record.t for Windows
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 22589
diff changeset
  1197
  record this change to 'subdir/f1'? [Ynesfdaq?] y
40c01f95449b tests: adjust expected prompt choice outputs in test-record.t for Windows
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 22589
diff changeset
  1198
  
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1199
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1200
  $ hg tip --config diff.git=True -p
27478
baa9810ee3ec test-commit-interactive: updates for the no-execbit case
Matt Harbison <matt_harbison@yahoo.com>
parents: 27412
diff changeset
  1201
  changeset:   26:5cc89ae210fa
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1202
  tag:         tip
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1203
  user:        test
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1204
  date:        Thu Jan 01 00:00:22 1970 +0000
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1205
  summary:     ab
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1206
  
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1207
  diff --git a/subdir/f1 b/subdir/f1
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1208
  --- a/subdir/f1
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1209
  +++ b/subdir/f1
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1210
  @@ -2,3 +2,4 @@
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1211
   a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1212
   a
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1213
   b
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1214
  +c
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1215
  
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1216
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1217
#endif
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1218
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1219
  $ cd ..
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1220
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1221
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1222
Abort early when a merge is in progress
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1223
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1224
  $ hg up 4
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
  1225
  1 files updated, 0 files merged, 7 files removed, 0 files unresolved
11237
feb2a58fc592 record: check that we are not committing a merge before patch selection
Nicolas Dumazet <nicdumz.commits@gmail.com>
parents: 8811
diff changeset
  1226
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1227
  $ touch iwillmergethat
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1228
  $ hg add iwillmergethat
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1229
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1230
  $ hg branch thatbranch
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1231
  marked working directory as branch thatbranch
15615
41885892796e branch: warn on branching
Matt Mackall <mpm@selenic.com>
parents: 13295
diff changeset
  1232
  (branches are permanent and global, did you want a bookmark?)
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1233
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1234
  $ hg ci -m'new head'
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1235
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1236
  $ hg up default
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
  1237
  7 files updated, 0 files merged, 2 files removed, 0 files unresolved
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1238
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1239
  $ hg merge thatbranch
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1240
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1241
  (branch merge, don't forget to commit)
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1242
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
  1243
  $ hg commit -i -m'will abort'
13023
3e2281b85990 record: quote command in use hg commit message
timeless <timeless@gmail.com>
parents: 12843
diff changeset
  1244
  abort: cannot partially commit a merge (use "hg commit" instead)
12316
4134686b83e1 tests: add exit codes to unified tests
Matt Mackall <mpm@selenic.com>
parents: 12074
diff changeset
  1245
  [255]
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1246
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1247
  $ hg up -C
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1248
  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1249
18954
b1639e98e8a1 record: ignore trailing content when parsing patches - introduce 'other' lines
Mads Kiilerich <mads@kiilerich.com>
parents: 18953
diff changeset
  1250
Editing patch (and ignoring trailing text)
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1251
16901
5b89700cce30 tests: consistently use a HGEDITOR pattern that works with msys on windows
Mads Kiilerich <mads@kiilerich.com>
parents: 16899
diff changeset
  1252
  $ cat > editor.sh << '__EOF__'
19080
5e4491c114b2 check-code: add a rule against a GNU sed-ism
Kevin Bullock <kbullock@ringworld.org>
parents: 18954
diff changeset
  1253
  > sed -e 7d -e '5s/^-/ /' -e '/^# ---/i\
5e4491c114b2 check-code: add a rule against a GNU sed-ism
Kevin Bullock <kbullock@ringworld.org>
parents: 18954
diff changeset
  1254
  > trailing\nditto' "$1" > tmp
16332
42e95631887d tests: remove sed -i from test-record
Matt Mackall <mpm@selenic.com>
parents: 16328
diff changeset
  1255
  > mv tmp "$1"
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1256
  > __EOF__
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1257
  $ cat > editedfile << '__EOF__'
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1258
  > This is the first line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1259
  > This is the second line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1260
  > This is the third line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1261
  > __EOF__
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1262
  $ hg add editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1263
  $ hg commit -medit-patch-1
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1264
  $ cat > editedfile << '__EOF__'
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1265
  > This line has changed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1266
  > This change will be committed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1267
  > This is the third line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1268
  > __EOF__
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
  1269
  $ HGEDITOR="\"sh\" \"`pwd`/editor.sh\"" hg commit -i -d '23 0' -medit-patch-2 <<EOF
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1270
  > y
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1271
  > e
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1272
  > EOF
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1273
  diff --git a/editedfile b/editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1274
  1 hunks, 2 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1275
  examine changes to 'editedfile'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1276
  
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1277
  @@ -1,3 +1,3 @@
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1278
  -This is the first line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1279
  -This is the second line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1280
  +This line has changed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1281
  +This change will be committed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1282
   This is the third line
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1283
  record this change to 'editedfile'? [Ynesfdaq?] e
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1284
  
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1285
  $ cat editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1286
  This line has changed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1287
  This change will be committed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1288
  This is the third line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1289
  $ hg cat -r tip editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1290
  This is the first line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1291
  This change will be committed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1292
  This is the third line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1293
  $ hg revert editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1294
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1295
Trying to edit patch for whole file
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1296
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1297
  $ echo "This is the fourth line" >> editedfile
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
  1298
  $ hg commit -i <<EOF
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1299
  > e
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1300
  > q
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1301
  > EOF
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1302
  diff --git a/editedfile b/editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1303
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1304
  examine changes to 'editedfile'? [Ynesfdaq?] e
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1305
  
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1306
  cannot edit patch for whole file
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1307
  examine changes to 'editedfile'? [Ynesfdaq?] q
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1308
  
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1309
  abort: user quit
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1310
  [255]
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1311
  $ hg revert editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1312
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1313
Removing changes from patch
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1314
16338
118eb4575ea2 tests: fix one more sed -i
Matt Mackall <mpm@selenic.com>
parents: 16332
diff changeset
  1315
  $ sed -e '3s/third/second/' -e '2s/will/will not/' -e 1d editedfile > tmp
118eb4575ea2 tests: fix one more sed -i
Matt Mackall <mpm@selenic.com>
parents: 16332
diff changeset
  1316
  $ mv tmp editedfile
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1317
  $ echo "This line has been added" >> editedfile
16901
5b89700cce30 tests: consistently use a HGEDITOR pattern that works with msys on windows
Mads Kiilerich <mads@kiilerich.com>
parents: 16899
diff changeset
  1318
  $ cat > editor.sh << '__EOF__'
16332
42e95631887d tests: remove sed -i from test-record
Matt Mackall <mpm@selenic.com>
parents: 16328
diff changeset
  1319
  > sed -e 's/^[-+]/ /' "$1" > tmp
42e95631887d tests: remove sed -i from test-record
Matt Mackall <mpm@selenic.com>
parents: 16328
diff changeset
  1320
  > mv tmp "$1"
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1321
  > __EOF__
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
  1322
  $ HGEDITOR="\"sh\" \"`pwd`/editor.sh\"" hg commit -i <<EOF
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1323
  > y
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1324
  > e
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1325
  > EOF
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1326
  diff --git a/editedfile b/editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1327
  1 hunks, 3 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1328
  examine changes to 'editedfile'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1329
  
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1330
  @@ -1,3 +1,3 @@
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1331
  -This is the first line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1332
  -This change will be committed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1333
  -This is the third line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1334
  +This change will not be committed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1335
  +This is the second line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1336
  +This line has been added
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1337
  record this change to 'editedfile'? [Ynesfdaq?] e
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1338
  
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1339
  no changes to record
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1340
  $ cat editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1341
  This change will not be committed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1342
  This is the second line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1343
  This line has been added
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1344
  $ hg cat -r tip editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1345
  This is the first line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1346
  This change will be committed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1347
  This is the third line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1348
  $ hg revert editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1349
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1350
Invalid patch
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1351
16332
42e95631887d tests: remove sed -i from test-record
Matt Mackall <mpm@selenic.com>
parents: 16328
diff changeset
  1352
  $ sed -e '3s/third/second/' -e '2s/will/will not/' -e 1d editedfile > tmp
42e95631887d tests: remove sed -i from test-record
Matt Mackall <mpm@selenic.com>
parents: 16328
diff changeset
  1353
  $ mv tmp editedfile
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1354
  $ echo "This line has been added" >> editedfile
16901
5b89700cce30 tests: consistently use a HGEDITOR pattern that works with msys on windows
Mads Kiilerich <mads@kiilerich.com>
parents: 16899
diff changeset
  1355
  $ cat > editor.sh << '__EOF__'
16332
42e95631887d tests: remove sed -i from test-record
Matt Mackall <mpm@selenic.com>
parents: 16328
diff changeset
  1356
  > sed s/This/That/ "$1" > tmp
42e95631887d tests: remove sed -i from test-record
Matt Mackall <mpm@selenic.com>
parents: 16328
diff changeset
  1357
  > mv tmp "$1"
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1358
  > __EOF__
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
  1359
  $ HGEDITOR="\"sh\" \"`pwd`/editor.sh\"" hg commit -i <<EOF
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1360
  > y
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1361
  > e
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1362
  > EOF
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1363
  diff --git a/editedfile b/editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1364
  1 hunks, 3 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1365
  examine changes to 'editedfile'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1366
  
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1367
  @@ -1,3 +1,3 @@
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1368
  -This is the first line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1369
  -This change will be committed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1370
  -This is the third line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1371
  +This change will not be committed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1372
  +This is the second line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1373
  +This line has been added
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1374
  record this change to 'editedfile'? [Ynesfdaq?] e
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1375
  
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1376
  patching file editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1377
  Hunk #1 FAILED at 0
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1378
  1 out of 1 hunks FAILED -- saving rejects to file editedfile.rej
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1379
  abort: patch failed to apply
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1380
  [255]
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1381
  $ cat editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1382
  This change will not be committed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1383
  This is the second line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1384
  This line has been added
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1385
  $ hg cat -r tip editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1386
  This is the first line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1387
  This change will be committed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1388
  This is the third line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1389
  $ cat editedfile.rej
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1390
  --- editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1391
  +++ editedfile
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1392
  @@ -1,3 +1,3 @@
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1393
  -That is the first line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1394
  -That change will be committed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1395
  -That is the third line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1396
  +That change will not be committed
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1397
  +That is the second line
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1398
  +That line has been added
18953
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1399
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1400
Malformed patch - error handling
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1401
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1402
  $ cat > editor.sh << '__EOF__'
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1403
  > sed -e '/^@/p' "$1" > tmp
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1404
  > mv tmp "$1"
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1405
  > __EOF__
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
  1406
  $ HGEDITOR="\"sh\" \"`pwd`/editor.sh\"" hg commit -i <<EOF
18953
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1407
  > y
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1408
  > e
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1409
  > EOF
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1410
  diff --git a/editedfile b/editedfile
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1411
  1 hunks, 3 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1412
  examine changes to 'editedfile'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1413
  
18953
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1414
  @@ -1,3 +1,3 @@
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1415
  -This is the first line
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1416
  -This change will be committed
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1417
  -This is the third line
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1418
  +This change will not be committed
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1419
  +This is the second line
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1420
  +This line has been added
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1421
  record this change to 'editedfile'? [Ynesfdaq?] e
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1422
  
18953
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1423
  abort: error parsing patch: unhandled transition: range -> range
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1424
  [255]
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1425
25483
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1426
Exiting editor with status 1, ignores the edit but does not stop the recording
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1427
session
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1428
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1429
  $ HGEDITOR=false hg commit -i <<EOF
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1430
  > y
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1431
  > e
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1432
  > n
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1433
  > EOF
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1434
  diff --git a/editedfile b/editedfile
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1435
  1 hunks, 3 lines changed
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1436
  examine changes to 'editedfile'? [Ynesfdaq?] y
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1437
  
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1438
  @@ -1,3 +1,3 @@
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1439
  -This is the first line
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1440
  -This change will be committed
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1441
  -This is the third line
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1442
  +This change will not be committed
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1443
  +This is the second line
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1444
  +This line has been added
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1445
  record this change to 'editedfile'? [Ynesfdaq?] e
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1446
  
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1447
  editor exited with exit code 1
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1448
  record this change to 'editedfile'? [Ynesfdaq?] n
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1449
  
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1450
  no changes to record
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1451
fb04372d7b38 record: exiting editor with non-zero status should not stop recording session
Laurent Charignon <lcharignon@fb.com>
parents: 25382
diff changeset
  1452
18954
b1639e98e8a1 record: ignore trailing content when parsing patches - introduce 'other' lines
Mads Kiilerich <mads@kiilerich.com>
parents: 18953
diff changeset
  1453
random text in random positions is still an error
b1639e98e8a1 record: ignore trailing content when parsing patches - introduce 'other' lines
Mads Kiilerich <mads@kiilerich.com>
parents: 18953
diff changeset
  1454
18953
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1455
  $ cat > editor.sh << '__EOF__'
19080
5e4491c114b2 check-code: add a rule against a GNU sed-ism
Kevin Bullock <kbullock@ringworld.org>
parents: 18954
diff changeset
  1456
  > sed -e '/^@/i\
5e4491c114b2 check-code: add a rule against a GNU sed-ism
Kevin Bullock <kbullock@ringworld.org>
parents: 18954
diff changeset
  1457
  > other' "$1" > tmp
18953
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1458
  > mv tmp "$1"
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1459
  > __EOF__
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
  1460
  $ HGEDITOR="\"sh\" \"`pwd`/editor.sh\"" hg commit -i <<EOF
18953
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1461
  > y
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1462
  > e
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1463
  > EOF
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1464
  diff --git a/editedfile b/editedfile
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1465
  1 hunks, 3 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1466
  examine changes to 'editedfile'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1467
  
18953
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1468
  @@ -1,3 +1,3 @@
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1469
  -This is the first line
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1470
  -This change will be committed
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1471
  -This is the third line
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1472
  +This change will not be committed
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1473
  +This is the second line
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1474
  +This line has been added
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1475
  record this change to 'editedfile'? [Ynesfdaq?] e
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1476
  
18954
b1639e98e8a1 record: ignore trailing content when parsing patches - introduce 'other' lines
Mads Kiilerich <mads@kiilerich.com>
parents: 18953
diff changeset
  1477
  abort: error parsing patch: unhandled transition: file -> other
18953
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1478
  [255]
e4ae397595e8 record: abort on malformed patches instead of crashing
Mads Kiilerich <madski@unity3d.com>
parents: 18266
diff changeset
  1479
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1480
  $ hg up -C
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1481
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1482
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1483
With win32text
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1484
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1485
  $ echo '[extensions]' >> .hg/hgrc
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1486
  $ echo 'win32text = ' >> .hg/hgrc
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1487
  $ echo '[decode]' >> .hg/hgrc
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1488
  $ echo '** = cleverdecode:' >> .hg/hgrc
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1489
  $ echo '[encode]' >> .hg/hgrc
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1490
  $ echo '** = cleverencode:' >> .hg/hgrc
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1491
  $ echo '[patch]' >> .hg/hgrc
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1492
  $ echo 'eol = crlf' >> .hg/hgrc
8811
8b35b08724eb Make mq, record and transplant honor patch.eol
Patrick Mezard <pmezard@gmail.com>
parents: 7718
diff changeset
  1493
12843
8aeb6184b008 tests: test/silence win32text deprecation warning
Martin Geisler <mg@lazybytes.net>
parents: 12328
diff changeset
  1494
Ignore win32text deprecation warning for now:
8aeb6184b008 tests: test/silence win32text deprecation warning
Martin Geisler <mg@lazybytes.net>
parents: 12328
diff changeset
  1495
8aeb6184b008 tests: test/silence win32text deprecation warning
Martin Geisler <mg@lazybytes.net>
parents: 12328
diff changeset
  1496
  $ echo '[win32text]' >> .hg/hgrc
8aeb6184b008 tests: test/silence win32text deprecation warning
Martin Geisler <mg@lazybytes.net>
parents: 12328
diff changeset
  1497
  $ echo 'warn = no' >> .hg/hgrc
8aeb6184b008 tests: test/silence win32text deprecation warning
Martin Geisler <mg@lazybytes.net>
parents: 12328
diff changeset
  1498
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1499
  $ echo d >> subdir/f1
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
  1500
  $ hg commit -i -d '24 0' -mw1 <<EOF
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1501
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1502
  > y
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1503
  > EOF
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1504
  diff --git a/subdir/f1 b/subdir/f1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1505
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1506
  examine changes to 'subdir/f1'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1507
  
27411
c84a07530040 record: turn on showfunc
timeless <timeless@mozdev.org>
parents: 26863
diff changeset
  1508
  @@ -3,3 +3,4 @@ a
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1509
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1510
   b
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1511
   c
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1512
  +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: 20580
diff changeset
  1513
  record this change to 'subdir/f1'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1514
  
8811
8b35b08724eb Make mq, record and transplant honor patch.eol
Patrick Mezard <pmezard@gmail.com>
parents: 7718
diff changeset
  1515
25759
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1516
  $ hg status -A subdir/f1
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1517
  C subdir/f1
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1518
  $ hg tip -p
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
  1519
  changeset:   30:* (glob)
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1520
  tag:         tip
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1521
  user:        test
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1522
  date:        Thu Jan 01 00:00:24 1970 +0000
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1523
  summary:     w1
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1524
  
16899
8149ff405c78 tests: convert some 'hghave execbit' to #if
Mads Kiilerich <mads@kiilerich.com>
parents: 16338
diff changeset
  1525
  diff -r ???????????? -r ???????????? subdir/f1 (glob)
16324
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1526
  --- a/subdir/f1	Thu Jan 01 00:00:23 1970 +0000
46b991a1f428 record: allow splitting of hunks by manually editing patches
A. S. Budden <abudden@gmail.com>
parents: 15623
diff changeset
  1527
  +++ b/subdir/f1	Thu Jan 01 00:00:24 1970 +0000
12074
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1528
  @@ -3,3 +3,4 @@
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1529
   a
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1530
   b
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1531
   c
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1532
  +d
35c143e85b1b tests: unify test-record
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 11238
diff changeset
  1533
  
24235
79fceed67676 record: allow editing new files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 23435
diff changeset
  1534
79fceed67676 record: allow editing new files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 23435
diff changeset
  1535
20171
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1536
Test --user when ui.username not set
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1537
  $ unset HGUSER
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1538
  $ echo e >> subdir/f1
24279
7cf9a9e0cf89 record: add new tests for commit interactive (same tests as record)
Laurent Charignon <lcharignon@fb.com>
parents: 24235
diff changeset
  1539
  $ hg commit -i  --config ui.username= -d '8 0' --user xyz -m "user flag" <<EOF
20171
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1540
  > y
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1541
  > y
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1542
  > EOF
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1543
  diff --git a/subdir/f1 b/subdir/f1
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1544
  1 hunks, 1 lines changed
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1545
  examine changes to 'subdir/f1'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1546
  
27411
c84a07530040 record: turn on showfunc
timeless <timeless@mozdev.org>
parents: 26863
diff changeset
  1547
  @@ -4,3 +4,4 @@ a
20171
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1548
   b
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1549
   c
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1550
   d
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1551
  +e
22589
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1552
  record this change to 'subdir/f1'? [Ynesfdaq?] y
9ab18a912c44 ui: show prompt choice if input is not a tty but is forced to be interactive
Mads Kiilerich <madski@unity3d.com>
parents: 20580
diff changeset
  1553
  
25759
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1554
  $ hg status -A subdir/f1
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1555
  C subdir/f1
20171
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1556
  $ hg log --template '{author}\n' -l 1
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1557
  xyz
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1558
  $ HGUSER="test"
a765611e06dc record: --user/-u now works with record when ui.username not set (issue3857)
Prasoon Shukla <prasoon92.iitr@gmail.com>
parents: 19080
diff changeset
  1559
  $ export HGUSER
16913
f2719b387380 tests: add missing trailing 'cd ..'
Mads Kiilerich <mads@kiilerich.com>
parents: 16901
diff changeset
  1560
24235
79fceed67676 record: allow editing new files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 23435
diff changeset
  1561
24837
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1562
Moving files
24235
79fceed67676 record: allow editing new files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 23435
diff changeset
  1563
24837
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1564
  $ hg update -C .
25759
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1565
  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
24837
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1566
  $ hg mv plain plain3
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1567
  $ echo somechange >> plain3
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1568
  $ hg commit -i -d '23 0' -mmoving_files << EOF
24235
79fceed67676 record: allow editing new files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 23435
diff changeset
  1569
  > y
24837
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1570
  > y
24235
79fceed67676 record: allow editing new files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 23435
diff changeset
  1571
  > EOF
24837
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1572
  diff --git a/plain b/plain3
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1573
  rename from plain
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1574
  rename to plain3
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1575
  1 hunks, 1 lines changed
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1576
  examine changes to 'plain' and 'plain3'? [Ynesfdaq?] y
24235
79fceed67676 record: allow editing new files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 23435
diff changeset
  1577
  
27411
c84a07530040 record: turn on showfunc
timeless <timeless@mozdev.org>
parents: 26863
diff changeset
  1578
  @@ -11,3 +11,4 @@ 8
24837
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1579
   9
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1580
   10
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1581
   11
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1582
  +somechange
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1583
  record this change to 'plain3'? [Ynesfdaq?] y
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1584
  
24861
15d7f435108a test-commit-interactive: stablize output for no-execbit platforms
Matt Harbison <matt_harbison@yahoo.com>
parents: 24845
diff changeset
  1585
The #if execbit block above changes the hash here on some systems
25759
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1586
  $ hg status -A plain3
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1587
  C plain3
24837
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1588
  $ hg tip
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
  1589
  changeset:   32:* (glob)
24837
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1590
  tag:         tip
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1591
  user:        test
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1592
  date:        Thu Jan 01 00:00:23 1970 +0000
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1593
  summary:     moving_files
edf907bd8144 record: fix record with change on moved file crashes (issue4619)
Laurent Charignon <lcharignon@fb.com>
parents: 24279
diff changeset
  1594
  
24845
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1595
Editing patch of newly added file
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1596
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1597
  $ hg update -C .
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1598
  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1599
  $ cat > editor.sh << '__EOF__'
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1600
  > cat "$1"  | sed "s/first/very/g"  > tt
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1601
  > mv tt  "$1"
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1602
  > __EOF__
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1603
  $ cat > newfile << '__EOF__'
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1604
  > This is the first line
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1605
  > This is the second line
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1606
  > This is the third line
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1607
  > __EOF__
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1608
  $ hg add newfile
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1609
  $ HGEDITOR="\"sh\" \"`pwd`/editor.sh\"" hg commit -i -d '23 0' -medit-patch-new <<EOF
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1610
  > y
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1611
  > e
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1612
  > EOF
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1613
  diff --git a/newfile b/newfile
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1614
  new file mode 100644
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1615
  examine changes to 'newfile'? [Ynesfdaq?] y
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1616
  
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1617
  @@ -0,0 +1,3 @@
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1618
  +This is the first line
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1619
  +This is the second line
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1620
  +This is the third line
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1621
  record this change to 'newfile'? [Ynesfdaq?] e
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1622
  
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1623
  $ hg cat -r tip newfile
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1624
  This is the very line
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1625
  This is the second line
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1626
  This is the third line
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1627
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1628
  $ cat newfile
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1629
  This is the first line
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1630
  This is the second line
8133494accf1 record: edit patch of newly added files (issue4304)
Laurent Charignon <lcharignon@fb.com>
parents: 24844
diff changeset
  1631
  This is the third line
24866
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1632
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1633
Add new file from within a subdirectory
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1634
  $ hg update -C .
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1635
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1636
  $ mkdir folder
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1637
  $ cd folder
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1638
  $ echo "foo" > bar
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1639
  $ hg add bar
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1640
  $ hg commit -i -d '23 0' -mnewfilesubdir  <<EOF
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1641
  > y
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1642
  > y
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1643
  > EOF
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1644
  diff --git a/folder/bar b/folder/bar
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1645
  new file mode 100644
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1646
  examine changes to 'folder/bar'? [Ynesfdaq?] y
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1647
  
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1648
  @@ -0,0 +1,1 @@
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1649
  +foo
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1650
  record this change to 'folder/bar'? [Ynesfdaq?] y
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1651
  
24884
d7778b88838c test-commit-interactive: add more globs for no-execbit platforms
Matt Harbison <matt_harbison@yahoo.com>
parents: 24866
diff changeset
  1652
The #if execbit block above changes the hashes here on some systems
24866
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1653
  $ hg tip -p
27412
14b184263846 record: fix hunk handling to remember the current function
timeless <timeless@mozdev.org>
parents: 27411
diff changeset
  1654
  changeset:   34:* (glob)
24866
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1655
  tag:         tip
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1656
  user:        test
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1657
  date:        Thu Jan 01 00:00:23 1970 +0000
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1658
  summary:     newfilesubdir
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1659
  
24884
d7778b88838c test-commit-interactive: add more globs for no-execbit platforms
Matt Harbison <matt_harbison@yahoo.com>
parents: 24866
diff changeset
  1660
  diff -r * -r * folder/bar (glob)
24866
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1661
  --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1662
  +++ b/folder/bar	Thu Jan 01 00:00:23 1970 +0000
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1663
  @@ -0,0 +1,1 @@
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1664
  +foo
e1ec3d075c67 record: fix adding new file with record from within a subdir (issue4626)
Laurent Charignon <lcharignon@fb.com>
parents: 24861
diff changeset
  1665
  
16913
f2719b387380 tests: add missing trailing 'cd ..'
Mads Kiilerich <mads@kiilerich.com>
parents: 16901
diff changeset
  1666
  $ cd ..
25759
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1667
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1668
  $ hg status -A folder/bar
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1669
  C folder/bar
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1670
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1671
Clear win32text configuration before size/timestamp sensitive test
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1672
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1673
  $ cat >> .hg/hgrc <<EOF
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1674
  > [extensions]
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1675
  > win32text = !
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1676
  > [decode]
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1677
  > ** = !
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1678
  > [encode]
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1679
  > ** = !
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1680
  > [patch]
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1681
  > eol = strict
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1682
  > EOF
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1683
  $ hg update -q -C null
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1684
  $ hg update -q -C tip
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1685
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1686
Test that partially committed file is still treated as "modified",
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1687
even if none of mode, size and timestamp is changed on the filesystem
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1688
(see also issue4583).
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1689
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1690
  $ cat > subdir/f1 <<EOF
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1691
  > A
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1692
  > a
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1693
  > a
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1694
  > b
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1695
  > c
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1696
  > d
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1697
  > E
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1698
  > EOF
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1699
  $ hg diff --git subdir/f1
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1700
  diff --git a/subdir/f1 b/subdir/f1
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1701
  --- a/subdir/f1
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1702
  +++ b/subdir/f1
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1703
  @@ -1,7 +1,7 @@
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1704
  -a
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1705
  +A
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1706
   a
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1707
   a
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1708
   b
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1709
   c
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1710
   d
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1711
  -e
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1712
  +E
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1713
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1714
  $ touch -t 200001010000 subdir/f1
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1715
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1716
  $ cat >> .hg/hgrc <<EOF
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1717
  > # emulate invoking patch.internalpatch() at 2000-01-01 00:00
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1718
  > [fakepatchtime]
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1719
  > fakenow = 200001010000
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1720
  > 
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1721
  > [extensions]
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1722
  > fakepatchtime = $TESTDIR/fakepatchtime.py
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1723
  > EOF
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1724
  $ hg commit -i -m 'commit subdir/f1 partially' <<EOF
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1725
  > y
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1726
  > y
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1727
  > n
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1728
  > EOF
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1729
  diff --git a/subdir/f1 b/subdir/f1
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1730
  2 hunks, 2 lines changed
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1731
  examine changes to 'subdir/f1'? [Ynesfdaq?] y
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1732
  
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1733
  @@ -1,6 +1,6 @@
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1734
  -a
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1735
  +A
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1736
   a
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1737
   a
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1738
   b
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1739
   c
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1740
   d
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1741
  record change 1/2 to 'subdir/f1'? [Ynesfdaq?] y
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1742
  
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1743
  @@ -2,6 +2,6 @@
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1744
   a
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1745
   a
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1746
   b
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1747
   c
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1748
   d
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1749
  -e
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1750
  +E
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1751
  record change 2/2 to 'subdir/f1'? [Ynesfdaq?] n
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1752
  
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1753
  $ cat >> .hg/hgrc <<EOF
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1754
  > [extensions]
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1755
  > fakepatchtime = !
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1756
  > EOF
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1757
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1758
  $ hg debugstate | grep ' subdir/f1$'
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1759
  n   0         -1 unset               subdir/f1
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1760
  $ hg status -A subdir/f1
ff11c1565c04 cmdutil: apply dirstate.normallookup on (maybe partially) committed files
FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
parents: 25483
diff changeset
  1761
  M subdir/f1