Nice thing Suraj, but I would simply do:
scp -r . remote.host:/path
Also, unlike the most popular belief tar doesn't restore permissions
unless the -p option is supplied.
On Tue, 2004-04-06 at 00:02 -0700, Suraj wrote:
Gopalarathnam V. wrote on Tue, Apr 06, 2004 at 11:15:01AM +0530:
,----
| For example, to copy all files (and directories) from /usr/src to
| /usr/local/src, you would do:
|
| (cd /usr/src && tar -cf - .) | (cd /usr/local/src && tar -xvpf -)
`----
Another thing I love doing is to move a directory and stuff underneath
it onto a remote machine:
tar -czf - . | ssh remote.host '(cd /path/to/destination/ && tar -xzf -)'
useful tip in my mind
cheers,
-Suraj
--
,-----------------[http://www.symonds.net/~suraj/]---o
| World War I broke out on August 4, 1914, after Archduke Franz Ferdinand,
heir
| to the Austro-Hungarian throne, was assassinated by a Serbian on June 28,
1914
| .
`------------------------------[suraj@xxxxxxxxxxx]---o