Email address obfuscation in effect -- please
click here to turn it off.
[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
- To: MLUG Members <EMAIL:PROTECTED>
- Subject: Re: [MLUG] copying many trees together
- From: Stephen Montgomery-Smith <EMAIL:PROTECTED>
- Date: Tue, 04 Sep 2007 23:33:45 -0500
- Delivery-date: Tue, 04 Sep 2007 23:34:34 -0500
- Envelope-to: EMAIL:PROTECTED
- In-reply-to: <EMAIL:PROTECTED>
- References: <EMAIL:PROTECTED>
- Reply-to: MLUG Members <EMAIL:PROTECTED>
- Sender: EMAIL:PROTECTED
- User-agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.8.1.6) Gecko/20070810 SeaMonkey/1.1.4
Mike Miller wrote:
Suppose I have a bunch of directory trees like these and there may be
files in any all of the directories:
A-- foo
`-- bar
B-- foo
`-- bar
`-- billy
`-- willy
C-- foo
`-- bar
`-- billy
`-- sue
D-- foo
`-- bar
`-- sally
`-- joe
E-- foo
`-- baz
`-- fun
`-- stuff
F-- foo
`-- baz
`-- unfun
`-- stuff
I want to put all of those directories, with the files into a single
tree like so:
X-- foo
|-- bar
| |-- billy
| | |-- sue
| | `-- willy
| `-- sally
| `-- joe
`-- baz
|-- fun
| `-- stuff
`-- unfun
`-- stuff
This could be done in succession with files from A copied first, then B,
then C, etc., and it would be fine to overwrite files because files with
the same name in the same position in the tree are always identical.
What's the best way to do this? Is there anything made for this? Does
rsync do this kind of thing? I wish cp could do it but I don't see an
option for it.
Mike
How about
mkdir X
rsync -av [A-F]/* X/.
_______________________________________________
members mailing list
EMAIL:PROTECTED
http://mlug.missouri.edu/mailman/listinfo/members