How to rsync only directories, no files inside ?
Wayne Davison
wayned at samba.org
Mon Mar 1 18:43:58 GMT 2004
On Mon, Mar 01, 2004 at 02:11:32AM +0800, Steven Shiau wrote:
> I need to create a lot of directories, just the same with remote's /var,
> but I only need the directories, the files inside those sub-directories in
> /var/ are not necessary for me.
Simply include all dirs and exclude everything else, like this:
rsync -av --include='*/' --exclude='*' /var/ remotehost:/var
(Change the destination dir from "var", as needed.)
..wayne..
More information about the rsync
mailing list