tests/test-mq-header-date
author Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
Wed, 02 Jan 2008 16:24:13 +0100
changeset 5788 4107e823dc2c
child 5822 38b592536a58
permissions -rwxr-xr-x
mq: add --currentdate and --date options to qnew and qrefresh These options make qnew add and qrefresh update a "# Date "-style header line. This allows proper recording of creation / last modification dates of patches in patch queues. Note that `qrefresh -D` only updates existing header lines. It never adds them, and does not warn about this. This is because I expect people to have `[default] qrefresh -D` in their .hgrc so patches with tracked dates get updated, others are left unchanged. The suggested setup in .hgrc is, in fact, [default] qnew = -D -U qrefresh = -D I tried to not mix header styles, so `qnew -D -U` now writes the user in "# User "-style, while `qnew -U` still writes it "From: "-style. Also, if `qrefresh -U` must add the user, it does so in "# User "-style if the header contains a "# HG changeset patch" line. (This is caused by mq not supporting the "Date: "-style header line at all - a reasonable choice given its standard date format.)
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
5788
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
     1
#!/bin/sh
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
     2
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
     3
echo "[extensions]" >> $HGRCPATH
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
     4
echo "mq=" >> $HGRCPATH
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
     5
echo "[diff]" >> $HGRCPATH
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
     6
echo "nodates=true" >> $HGRCPATH
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
     7
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
     8
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
     9
catpatch() {
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    10
    cat .hg/patches/$1.patch | sed -e "s/^diff \-r [0-9a-f]* /diff -r ... /"
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    11
}
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    12
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    13
catlog() {
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    14
    catpatch $1
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    15
    hg log --template "{rev}: {desc} - {author}\n"
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    16
}
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    17
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    18
catlogd() {
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    19
    catpatch $1
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    20
    hg log --template "{rev}: {desc} - {author} - {date}\n"
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    21
}
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    22
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    23
drop() {
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    24
    hg qpop
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    25
    hg qdel $1.patch
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    26
}
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    27
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    28
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    29
echo ==== init
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    30
hg init a
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    31
cd a
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    32
hg qinit
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    33
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    34
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    35
echo ==== qnew -d
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    36
hg qnew -d '3 0' 1.patch
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    37
catlogd 1
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    38
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    39
echo ==== qref
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    40
echo "1" >1
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    41
hg add
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    42
hg qref
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    43
catlogd 1
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    44
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    45
echo ==== qref -d
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    46
hg qref -d '4 0'
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    47
catlogd 1
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    48
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    49
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    50
echo ==== qnew
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    51
hg qnew 2.patch
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    52
echo "2" >2
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    53
hg add
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    54
hg qref
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    55
catlog 2
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    56
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    57
echo ==== qref -d
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    58
hg qref -d '5 0'
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    59
catlog 2
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    60
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    61
drop 2
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    62
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    63
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    64
echo ==== qnew -d -m
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    65
hg qnew -d '6 0' -m "Three" 3.patch
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    66
catlogd 3
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    67
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    68
echo ==== qref
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    69
echo "3" >3
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    70
hg add
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    71
hg qref
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    72
catlogd 3
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    73
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    74
echo ==== qref -m
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    75
hg qref -m "Drei"
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    76
catlogd 3
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    77
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    78
echo ==== qref -d
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    79
hg qref -d '7 0'
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    80
catlogd 3
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    81
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    82
echo ==== qref -d -m
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    83
hg qref -d '8 0' -m "Three (again)"
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    84
catlogd 3
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    85
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    86
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    87
echo ==== qnew -m
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    88
hg qnew -m "Four" 4.patch
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    89
echo "4" >4
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    90
hg add
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    91
hg qref
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    92
catlog 4
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    93
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    94
echo ==== qref -d
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    95
hg qref -d '9 0'
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    96
catlog 4
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    97
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    98
drop 4
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
    99
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   100
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   101
echo ==== qnew with HG header
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   102
hg qnew 5.patch
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   103
hg qpop
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   104
echo "# HG changeset patch" >>.hg/patches/5.patch
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   105
echo "# Date 10 0" >>.hg/patches/5.patch
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   106
# Drop patch specific error line
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   107
hg qpush 2>&1 | grep -v garbage
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   108
catlogd 5
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   109
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   110
echo ==== hg qref
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   111
echo "5" >5
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   112
hg add
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   113
hg qref
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   114
catlogd 5
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   115
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   116
echo ==== hg qref -d
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   117
hg qref -d '11 0'
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   118
catlogd 5
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   119
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   120
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   121
echo ==== qnew -u
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   122
hg qnew -u jane 6.patch
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   123
echo "6" >6
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   124
hg add
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   125
hg qref
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   126
catlog 6
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   127
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   128
echo ==== qref -d
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   129
hg qref -d '12 0'
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   130
catlog 6
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   131
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   132
drop 6
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   133
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   134
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   135
echo ==== qnew -d
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   136
hg qnew -d '13 0' 7.patch
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   137
echo "7" >7
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   138
hg add
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   139
hg qref
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   140
catlog 7
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   141
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   142
echo ==== qref -u
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   143
hg qref -u john
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   144
catlogd 7
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   145
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   146
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   147
echo ==== qnew
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   148
hg qnew 8.patch
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   149
echo "8" >8
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   150
hg add
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   151
hg qref
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   152
catlog 8
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   153
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   154
echo ==== qref -u -d
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   155
hg qref -u john -d '14 0'
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   156
catlog 8
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   157
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   158
drop 8
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   159
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   160
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   161
echo ==== qnew -m
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   162
hg qnew -m "Nine" 9.patch
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   163
echo "9" >9
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   164
hg add
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   165
hg qref
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   166
catlog 9
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   167
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   168
echo ==== qref -u -d
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   169
hg qref -u john -d '15 0'
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   170
catlog 9
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   171
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   172
drop 9
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   173
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   174
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   175
echo ==== "qpop -a / qpush -a"
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   176
hg qpop -a
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   177
hg qpush -a
4107e823dc2c mq: add --currentdate and --date options to qnew and qrefresh
Peter Arrenbrecht <peter.arrenbrecht@gmail.com>
parents:
diff changeset
   178
hg log --template "{rev}: {desc} - {author} - {date}\n"