print only first level directory name when copying files

Fourhundred Thecat via rsync <[email protected]> Fri, 4 Aug 2023 04:27:58 +0200
Newsgroups gmane.network.rsync.general
Message-ID <[email protected]>
Hello,

I am copying /mnt/foo to /mnt/bar/

   rsync --info=name1,del2 -rl /mnt/foo /mnt/bar/

/mnt/foo contains deep directory structure, ie:

   /mnt/foo/aaa/
   /mnt/foo/aaa/somestuff/
   /mnt/foo/aaa/somestuff/file1

   /mnt/foo/bbb/
   /mnt/foo/bbb/someotherstuff/
   /mnt/foo/bbb/someotherstuff/file2

I am not interested in details which individual files were copied, just
the main directory. Is it somehow possible for rsync to only report the
first level directory?

ie, to have output like this when copying:

   /mnt/foo/aaa/
   /mnt/foo/bbb/


thanks,

-- 
Please use reply-all for most replies to avoid omitting the mailing list.
To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html