LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   using wget (https://www.linuxquestions.org/questions/linux-software-2/using-wget-306940/)

bucovaina78 03-28-2005 06:02 AM

using wget
 
Hi,

I'm wanting to use wget, read the manual pages but not very clear.

Let's suppose I want to download all textfiles located on:
http://www.linuxmanuals.org/

The site is subdivided in

http://www.linuxmanuals.org/software
http://www.linuxmanuals.org/hardware
http://www.linuxmanuals.org/installation
http://www.linuxmanuals.org/security
...


So on the first page (homepage) there are not really textfiles i'm interested in but in the /software /hardware /installation and /security there are direct links to the textfiles.

So if I have figured it out rightly, I need to download all txt files, 1 link deep from http://www.linuxmanuals.org/


by the way is there anyway to save the files it downloads into a specified directory?

Now my question is how will my command look like? something like

wget -A txt -l 1 http://www.linuxmanuals.org/

or am I completely wrong?

Many thx

Wannes

uberNUT69 03-28-2005 06:24 AM

your example seems to work for me, but I'd suggest using -r and l 2

bucovaina78 03-28-2005 06:39 AM

-r option
 
what's the difference between the -A and -r option? the -r seems to work for me and -A not

uberNUT69 03-28-2005 07:02 AM

from the manpage for wget:
-A acclist --accept acclist
-R rejlist --reject rejlist
Specify comma-separated lists of file name suffixes or patterns to accept or reject (@pxref{Types of Files} for
more details).


-r is recursive!!!


All times are GMT -5. The time now is 12:52 PM.