tests/test-rename.out
author Thomas Arendsen Hein <thomas@intevation.de>
Thu, 17 Nov 2005 19:18:33 +0100
changeset 1553 4aeba581990b
parent 1514 faf46d810a85
child 1565 4bcbc126b80b
permissions -rw-r--r--
Merge with mercurial/crew
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1512
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
     1
# rename a single file
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
     2
A d2/c
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
     3
R d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
     4
# move a single file to an existing directory
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
     5
A d2/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
     6
R d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
     7
# rename directory d1 as d3
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
     8
copying d1/a to d3/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
     9
copying d1/b to d3/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    10
copying d1/ba to d3/ba
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    11
copying d1/d11/a1 to d3/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    12
removing d1/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    13
removing d1/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    14
removing d1/ba
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    15
removing d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    16
A d3/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    17
A d3/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    18
A d3/ba
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    19
A d3/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    20
R d1/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    21
R d1/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    22
R d1/ba
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    23
R d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    24
# move directory d1/d11 to an existing directory d2 (removes empty d1)
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    25
copying d1/d11/a1 to d2/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    26
removing d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    27
A d2/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    28
R d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    29
# move directories d1 and d2 to a new directory d3
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    30
copying d1/a to d3/d1/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    31
copying d1/b to d3/d1/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    32
copying d1/ba to d3/d1/ba
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    33
copying d1/d11/a1 to d3/d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    34
copying d2/b to d3/d2/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    35
removing d1/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    36
removing d1/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    37
removing d1/ba
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    38
removing d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    39
removing d2/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    40
A d3/d1/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    41
A d3/d1/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    42
A d3/d1/ba
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    43
A d3/d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    44
A d3/d2/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    45
R d1/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    46
R d1/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    47
R d1/ba
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    48
R d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    49
R d2/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    50
# move everything under directory d1 to existing directory d2, do not
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    51
# overwrite existing files (d2/b)
1513
5c3b93b244aa copy & rename don't overwrite unless --force is specified
Robin Farine <robin.farine@terminus.org>
parents: 1512
diff changeset
    52
d2/b: not overwriting - file exists
1512
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    53
copying d1/d11/a1 to d2/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    54
removing d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    55
A d2/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    56
A d2/ba
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    57
A d2/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    58
R d1/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    59
R d1/ba
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    60
R d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    61
1c1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    62
< d1/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    63
---
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    64
> d2/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    65
# attempt to move potentially more than one file into a non-existent
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    66
# directory
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    67
abort: with multiple sources, destination must be an existing directory
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    68
# move every file under d1 to d2/d21 (glob)
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    69
copying d1/a to d2/d21/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    70
copying d1/b to d2/d21/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    71
copying d1/ba to d2/d21/ba
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    72
copying d1/d11/a1 to d2/d21/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    73
removing d1/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    74
removing d1/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    75
removing d1/ba
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    76
removing d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    77
A d2/d21/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    78
A d2/d21/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    79
A d2/d21/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    80
A d2/d21/ba
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    81
R d1/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    82
R d1/b
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    83
R d1/ba
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    84
R d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    85
# move every file under d1 starting with an 'a' to d2/d21 (regexp)
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    86
copying d1/a to d2/d21/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    87
copying d1/d11/a1 to d2/d21/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    88
removing d1/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    89
removing d1/d11/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    90
A d2/d21/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    91
A d2/d21/a1
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    92
R d1/a
53ad6ee6ede4 generalize copy/rename to handle more than one source directory
Robin Farine <robin.farine@terminus.org>
parents:
diff changeset
    93
R d1/d11/a1
1513
5c3b93b244aa copy & rename don't overwrite unless --force is specified
Robin Farine <robin.farine@terminus.org>
parents: 1512
diff changeset
    94
# attempt to overwrite an existing file
5c3b93b244aa copy & rename don't overwrite unless --force is specified
Robin Farine <robin.farine@terminus.org>
parents: 1512
diff changeset
    95
d1/ca: not overwriting - file exists
5c3b93b244aa copy & rename don't overwrite unless --force is specified
Robin Farine <robin.farine@terminus.org>
parents: 1512
diff changeset
    96
abort: no files to copy
5c3b93b244aa copy & rename don't overwrite unless --force is specified
Robin Farine <robin.farine@terminus.org>
parents: 1512
diff changeset
    97
? d1/ca
5c3b93b244aa copy & rename don't overwrite unless --force is specified
Robin Farine <robin.farine@terminus.org>
parents: 1512
diff changeset
    98
# forced overwrite of an existing file
5c3b93b244aa copy & rename don't overwrite unless --force is specified
Robin Farine <robin.farine@terminus.org>
parents: 1512
diff changeset
    99
A d1/ca
5c3b93b244aa copy & rename don't overwrite unless --force is specified
Robin Farine <robin.farine@terminus.org>
parents: 1512
diff changeset
   100
R d1/ba
5c3b93b244aa copy & rename don't overwrite unless --force is specified
Robin Farine <robin.farine@terminus.org>
parents: 1512
diff changeset
   101
# replace a symlink with a file
5c3b93b244aa copy & rename don't overwrite unless --force is specified
Robin Farine <robin.farine@terminus.org>
parents: 1512
diff changeset
   102
A d1/ca
5c3b93b244aa copy & rename don't overwrite unless --force is specified
Robin Farine <robin.farine@terminus.org>
parents: 1512
diff changeset
   103
R d1/ba
1514
faf46d810a85 avoid to copy more than one file to the same destination file
Robin Farine <robin.farine@terminus.org>
parents: 1513
diff changeset
   104
# do not copy more than one source file to the same destination file
faf46d810a85 avoid to copy more than one file to the same destination file
Robin Farine <robin.farine@terminus.org>
parents: 1513
diff changeset
   105
copying d1/d11/a1 to d3/d11/a1
faf46d810a85 avoid to copy more than one file to the same destination file
Robin Farine <robin.farine@terminus.org>
parents: 1513
diff changeset
   106
d3/b: not overwriting - d2/b collides with d1/b
faf46d810a85 avoid to copy more than one file to the same destination file
Robin Farine <robin.farine@terminus.org>
parents: 1513
diff changeset
   107
removing d1/d11/a1
faf46d810a85 avoid to copy more than one file to the same destination file
Robin Farine <robin.farine@terminus.org>
parents: 1513
diff changeset
   108
A d3/a
faf46d810a85 avoid to copy more than one file to the same destination file
Robin Farine <robin.farine@terminus.org>
parents: 1513
diff changeset
   109
A d3/b
faf46d810a85 avoid to copy more than one file to the same destination file
Robin Farine <robin.farine@terminus.org>
parents: 1513
diff changeset
   110
A d3/ba
faf46d810a85 avoid to copy more than one file to the same destination file
Robin Farine <robin.farine@terminus.org>
parents: 1513
diff changeset
   111
A d3/d11/a1
faf46d810a85 avoid to copy more than one file to the same destination file
Robin Farine <robin.farine@terminus.org>
parents: 1513
diff changeset
   112
R d1/a
faf46d810a85 avoid to copy more than one file to the same destination file
Robin Farine <robin.farine@terminus.org>
parents: 1513
diff changeset
   113
R d1/b
faf46d810a85 avoid to copy more than one file to the same destination file
Robin Farine <robin.farine@terminus.org>
parents: 1513
diff changeset
   114
R d1/ba
faf46d810a85 avoid to copy more than one file to the same destination file
Robin Farine <robin.farine@terminus.org>
parents: 1513
diff changeset
   115
R d1/d11/a1