Copy everything bar one folder

Joel Bryan Juliano joelbryan.juliano at gmail.com
Tue Feb 27 23:05:17 UTC 2007


On 2/28/07, SteVe Cook <yorvik.ubunto at googlemail.com> wrote:
>
> I want to copy everything bar one very large folder from my current
> /home partition to another smaller partition and make this new partition
> /home.
>
> The only real problem I'm having is finding out how to copy all the
> files bar one. I could copy a few at a time I suppose but that seems
> rather long winded.
>
> Trawling round the web hasn't produced any answers.  Any body got any
> ideas
>
> SteVe



Does bar means excluded mate? :-)

Ok, supposed you have a bar directory,
we can lorry the other files and gotten them copied
to a destination directory.

rsync --exclude=/home/bar -a /home /newhome

You can always snuck in another --exclude= to rsync.

-- 
Stay away from Piracy, use Open Source.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20070228/663cd125/attachment.html>


More information about the ubuntu-users mailing list