• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 228
  • Last Modified:

wget & text file

Lets say i have a text file full of links  like that:

http://myserver.com/myfile1.rar
http://myserver.com/myfile2.rar
http://myserver.com/myfile3.rar
http://myserver.com/myfile4.rar
http://myserver.com/myfile5.rar
http://myserver.com/myfile6.rar

and lets say the file's name is "list"

How can I run wget in a way that will proccess and download aautomaticaly all the files in the list,but
1 by 1, meaning, that it will download the first and after it finishes it will download the second and then the third, etc etc.

Any ideas?
0
MaRiOsGR
Asked:
MaRiOsGR
3 Solutions
 
ozoCommented:
while read url ; do wget $url; done < list
0
 
brettmjohnsonCommented:
From the wget man page:

"     -   You have a file that contains the URLs you want to download?  Use
           the -i switch:

                   wget -i I<file>
"
0
 
ahoffmannCommented:
wget `wget -O - http://dom.tld/list`
0

Featured Post

Prepare for your VMware VCP6-DCV exam.

Josh Coen and Jason Langer have prepared the latest edition of VCP study guide. Both authors have been working in the IT field for more than a decade, and both hold VMware certifications. This 163-page guide covers all 10 of the exam blueprint sections.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now