Register
It is currently Tue Sep 16, 2014 9:28 am

copy files using atext file as input


All times are UTC - 6 hours


Post new topic Reply to topic  [ 4 posts ] 
Author Message
 PostPosted: Wed May 12, 2010 4:11 pm   

Joined: Sun Apr 04, 2010 11:44 am
Posts: 9
Hi,

I'd like to copy a list of files that are listed in a text file like this

Directory1/FileA.ext
Directory2/FileB.ext

etc.

Any idea how i can automate this?


Top
 Profile  
 PostPosted: Wed May 12, 2010 6:07 pm   

Joined: Mon Mar 02, 2009 3:03 am
Posts: 546
Hi,

rsync would do this.


Top
 Profile  
 PostPosted: Fri May 14, 2010 4:07 am   
Moderator
User avatar

Joined: Thu Oct 11, 2007 7:12 am
Posts: 229
Location: London - UK
Code:
rsync -av --files-from=SOURCEFILE . destinationdir/


That should do the trick :)
Weirdly the source is still needed even though it's ignored when using --files-from 8-}


Top
 Profile  
 PostPosted: Fri May 14, 2010 8:50 am   
User avatar

Joined: Tue Apr 27, 2010 2:28 pm
Posts: 172
Location: Czech Republic
DarthWavy wrote:
Code:
rsync -av --files-from=SOURCEFILE . destinationdir/


That should do the trick :)
Weirdly the source is still needed even though it's ignored when using --files-from 8-}

Doesn't it search for the files relatively to the source? :-/


Top
 Profile  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC - 6 hours


Who is online

Users browsing this forum: No registered users and 6 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  


BashScripts | Promote Your Page Too
Powered by phpBB © 2011 phpBB Group
© 2003 - 2011 USA LINUX USERS GROUP