tests/test-mq-qpush-exact.t
author Idan Kamara <idankk86@gmail.com>
Fri, 24 Jun 2011 19:36:44 +0300
branchstable
changeset 14743 84a680daa4b2
parent 14732 e9ed3506f066
child 16913 f2719b387380
permissions -rw-r--r--
dispatch: pass the correct ui to runcommand For commands that take a repo, repo.ui is passed as the ui to runcommand. This restores that behaviour when the request has a repo.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
13033
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
     1
  $ echo "[extensions]" >> $HGRCPATH
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
     2
  $ echo "mq=" >> $HGRCPATH
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
     3
  $ echo "graphlog=" >> $HGRCPATH
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
     4
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
     5
make a test repository that looks like this:
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
     6
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
     7
o    2:28bc7b1afd6a
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
     8
|
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
     9
| @  1:d7fe2034f71b
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    10
|/
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    11
o    0/62ecad8b70e5
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    12
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    13
  $ hg init r0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    14
  $ cd r0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    15
  $ touch f0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    16
  $ hg ci -m0 -Aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    17
  $ touch f1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    18
  $ hg ci -m1 -Aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    19
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    20
  $ hg update 0 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    21
  $ touch f2
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    22
  $ hg ci -m2 -Aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    23
  $ hg update 1 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    24
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    25
make some patches with a parent: 1:d7fe2034f71b -> p0 -> p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    26
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    27
  $ echo cp0 >> fp0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    28
  $ hg add fp0
14170
31ec4d7eb63f mq: strip extra whitespace from node ids in header (issue2790)
Kevin Bullock <kbullock@ringworld.org>
parents: 13033
diff changeset
    29
  $ hg ci -m p0 -d "0 0"
31ec4d7eb63f mq: strip extra whitespace from node ids in header (issue2790)
Kevin Bullock <kbullock@ringworld.org>
parents: 13033
diff changeset
    30
  $ hg export -r. > p0
31ec4d7eb63f mq: strip extra whitespace from node ids in header (issue2790)
Kevin Bullock <kbullock@ringworld.org>
parents: 13033
diff changeset
    31
  $ hg strip -qn .
31ec4d7eb63f mq: strip extra whitespace from node ids in header (issue2790)
Kevin Bullock <kbullock@ringworld.org>
parents: 13033
diff changeset
    32
  $ hg qimport p0
31ec4d7eb63f mq: strip extra whitespace from node ids in header (issue2790)
Kevin Bullock <kbullock@ringworld.org>
parents: 13033
diff changeset
    33
  adding p0 to series file
31ec4d7eb63f mq: strip extra whitespace from node ids in header (issue2790)
Kevin Bullock <kbullock@ringworld.org>
parents: 13033
diff changeset
    34
  $ hg qpush
31ec4d7eb63f mq: strip extra whitespace from node ids in header (issue2790)
Kevin Bullock <kbullock@ringworld.org>
parents: 13033
diff changeset
    35
  applying p0
31ec4d7eb63f mq: strip extra whitespace from node ids in header (issue2790)
Kevin Bullock <kbullock@ringworld.org>
parents: 13033
diff changeset
    36
  now at: p0
13033
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    37
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    38
  $ echo cp1 >> fp1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    39
  $ hg add fp1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    40
  $ hg qnew p1 -d "0 0"
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    41
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    42
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    43
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    44
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    45
qpush --exact when at the parent
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    46
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    47
  $ hg update 1 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    48
  $ hg qpush -e
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    49
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    50
  now at: p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    51
  $ hg parents -qr qbase
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    52
  1:d7fe2034f71b
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    53
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    54
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    55
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    56
  $ hg qpush -e p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    57
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    58
  now at: p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    59
  $ hg parents -qr qbase
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    60
  1:d7fe2034f71b
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    61
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    62
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    63
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    64
  $ hg qpush -e p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    65
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    66
  applying p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    67
  now at: p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    68
  $ hg parents -qr qbase
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    69
  1:d7fe2034f71b
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    70
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    71
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    72
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    73
qpush --exact when at another rev
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    74
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    75
  $ hg update 0 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    76
  $ hg qpush -e
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    77
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    78
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    79
  now at: p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    80
  $ hg parents -qr qbase
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    81
  1:d7fe2034f71b
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    82
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    83
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    84
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    85
  $ hg update 0 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    86
  $ hg qpush -e p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    87
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    88
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    89
  now at: p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    90
  $ hg parents -qr qbase
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    91
  1:d7fe2034f71b
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    92
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    93
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    94
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    95
  $ hg update 0 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    96
  $ hg qpush -e p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    97
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    98
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
    99
  applying p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   100
  now at: p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   101
  $ hg parents -qr qbase
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   102
  1:d7fe2034f71b
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   103
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   104
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   105
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   106
  $ hg update 0 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   107
  $ hg qpush -ea
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   108
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   109
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   110
  applying p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   111
  now at: p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   112
  $ hg parents -qr qbase
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   113
  1:d7fe2034f71b
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   114
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   115
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   116
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   117
qpush --exact while crossing branches
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   118
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   119
  $ hg update 2 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   120
  $ hg qpush -e
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   121
  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   122
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   123
  now at: p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   124
  $ hg parents -qr qbase
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   125
  1:d7fe2034f71b
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   126
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   127
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   128
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   129
  $ hg update 2 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   130
  $ hg qpush -e p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   131
  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   132
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   133
  now at: p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   134
  $ hg parents -qr qbase
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   135
  1:d7fe2034f71b
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   136
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   137
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   138
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   139
  $ hg update 2 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   140
  $ hg qpush -e p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   141
  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   142
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   143
  applying p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   144
  now at: p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   145
  $ hg parents -qr qbase
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   146
  1:d7fe2034f71b
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   147
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   148
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   149
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   150
  $ hg update 2 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   151
  $ hg qpush -ea
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   152
  1 files updated, 0 files merged, 1 files removed, 0 files unresolved
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   153
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   154
  applying p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   155
  now at: p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   156
  $ hg parents -qr qbase
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   157
  1:d7fe2034f71b
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   158
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   159
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   160
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   161
qpush --exact --force with changes to an unpatched file
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   162
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   163
  $ hg update 1 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   164
  $ echo c0 >> f0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   165
  $ hg qpush -e
14732
e9ed3506f066 backout of d04ba50e104d: allow to qpop/push with a dirty working copy
Idan Kamara <idankk86@gmail.com>
parents: 14256
diff changeset
   166
  abort: local changes found
e9ed3506f066 backout of d04ba50e104d: allow to qpop/push with a dirty working copy
Idan Kamara <idankk86@gmail.com>
parents: 14256
diff changeset
   167
  [255]
13033
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   168
  $ hg qpush -ef
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   169
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   170
  now at: p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   171
  $ cat f0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   172
  c0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   173
  $ rm f0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   174
  $ touch f0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   175
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   176
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   177
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   178
  $ hg update 1 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   179
  $ echo c0 >> f0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   180
  $ hg qpush -e p1
14732
e9ed3506f066 backout of d04ba50e104d: allow to qpop/push with a dirty working copy
Idan Kamara <idankk86@gmail.com>
parents: 14256
diff changeset
   181
  abort: local changes found
e9ed3506f066 backout of d04ba50e104d: allow to qpop/push with a dirty working copy
Idan Kamara <idankk86@gmail.com>
parents: 14256
diff changeset
   182
  [255]
13033
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   183
  $ hg qpush -e p1 -f
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   184
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   185
  applying p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   186
  now at: p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   187
  $ cat f0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   188
  c0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   189
  $ rm f0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   190
  $ touch f0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   191
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   192
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   193
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   194
qpush --exact --force with changes to a patched file
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   195
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   196
  $ hg update 1 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   197
  $ echo cp0-bad >> fp0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   198
  $ hg add fp0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   199
  $ hg qpush -e
14191
e1c34ce39fae mq: don't suggest to refresh when qpushing with no applied patches
Idan Kamara <idankk86@gmail.com>
parents: 14170
diff changeset
   200
  abort: local changes found
13033
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   201
  [255]
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   202
  $ hg qpush -ef
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   203
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   204
  file fp0 already exists
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   205
  1 out of 1 hunks FAILED -- saving rejects to file fp0.rej
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   206
  patch failed, unable to continue (try -v)
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   207
  patch failed, rejects left in working dir
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   208
  errors during apply, please fix and refresh p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   209
  [2]
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   210
  $ cat fp0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   211
  cp0-bad
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   212
  $ cat fp0.rej
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   213
  --- fp0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   214
  +++ fp0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   215
  @@ -0,0 +1,1 @@
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   216
  +cp0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   217
  $ hg qpop -aqf
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   218
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   219
  $ rm fp0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   220
  $ rm fp0.rej
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   221
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   222
  $ hg update 1 -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   223
  $ echo cp1-bad >> fp1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   224
  $ hg add fp1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   225
  $ hg qpush -e p1
14191
e1c34ce39fae mq: don't suggest to refresh when qpushing with no applied patches
Idan Kamara <idankk86@gmail.com>
parents: 14170
diff changeset
   226
  abort: local changes found
13033
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   227
  [255]
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   228
  $ hg qpush -e p1 -f
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   229
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   230
  applying p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   231
  file fp1 already exists
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   232
  1 out of 1 hunks FAILED -- saving rejects to file fp1.rej
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   233
  patch failed, unable to continue (try -v)
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   234
  patch failed, rejects left in working dir
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   235
  errors during apply, please fix and refresh p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   236
  [2]
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   237
  $ cat fp1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   238
  cp1-bad
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   239
  $ cat fp1.rej
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   240
  --- fp1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   241
  +++ fp1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   242
  @@ -0,0 +1,1 @@
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   243
  +cp1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   244
  $ hg qpop -aqf
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   245
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   246
  $ rm fp1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   247
  $ rm fp1.rej
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   248
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   249
qpush --exact when already at a patch
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   250
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   251
  $ hg update 1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   252
  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   253
  $ hg qpush -e p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   254
  applying p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   255
  now at: p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   256
  $ hg qpush -e p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   257
  abort: cannot push --exact with applied patches
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   258
  [255]
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   259
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   260
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   261
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   262
qpush --exact --move should fail
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   263
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   264
  $ hg qpush -e --move p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   265
  abort: cannot use --exact and --move together
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   266
  [255]
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   267
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   268
qpush --exact a patch without a parent recorded
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   269
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   270
  $ hg qpush -q
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   271
  now at: p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   272
  $ grep -v '# Parent' .hg/patches/p0 > p0.new
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   273
  $ mv p0.new .hg/patches/p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   274
  $ hg qpop -aq
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   275
  patch queue now empty
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   276
  $ hg qpush -e
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   277
  abort: p0 does not have a parent recorded
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   278
  [255]
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   279
  $ hg qpush -e p0
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   280
  abort: p0 does not have a parent recorded
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   281
  [255]
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   282
  $ hg qpush -e p1
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   283
  abort: p0 does not have a parent recorded
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   284
  [255]
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   285
  $ hg qpush -ea
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   286
  abort: p0 does not have a parent recorded
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   287
  [255]
026053f691a4 mq: add an '-e/--exact' option to qpush
Steve Losh <steve@stevelosh.com>
parents:
diff changeset
   288