Mailinglist Archive: opensuse (3644 mails)

< Previous Next >
Re: [SLE] Need help with wget options
  • From: Eddie Howson <eddie@xxxxxxxxxxxxx>
  • Date: Mon, 11 Mar 2002 09:50:35 +0000
  • Message-id: <200203110950.g2B9obw10467@xxxxxxxxxxxxxxxxxxxxx>
Hi jw

I've just tried it using ". . . --accept=rpm . . ." and it worked for
grabbing rpm's. Hope that helps.


On Saturday 09 March 2002 11:50 pm, JW wrote:

I see that wget has the following options:

jw@fluorite:/work/dl/na > wget --help

Recursive retrieval:
-r, --recursive recursive web-suck -- use with care!.
-l, --level=NUMBER maximum recursion depth (0 to unlimit).
--delete-after delete downloaded files.
-k, --convert-links convert non-relative links to relative.
-m, --mirror turn on options suitable for mirroring.
-nr, --dont-remove-listing don't remove `.listing' files.

Recursive accept/reject:
-A, --accept=LIST list of accepted extensions.
-R, --reject=LIST list of rejected extensions.
-D, --domains=LIST list of accepted domains.
--exclude-domains=LIST comma-separated list of rejected
domains. -L, --relative follow relative links only.
--follow-ftp follow FTP links from HTML documents.
-H, --span-hosts go to foreign hosts when recursive.
-I, --include-directories=LIST list of allowed directories.
-X, --exclude-directories=LIST list of excluded directories.
-nh, --no-host-lookup don't DNS-lookup hosts.
-np, --no-parent don't ascend to the parent directory.

What I'm trying to do is recursively downlaod all images from portaions of
web sites, but _not_ anything else - no htm html php asp js ccs or anything
else. I was thinking that if I used -A or --accept that i could tell wget
to download .jpg .jpeg .gif .png .tif and .tiff but for the life of me I
cna't get it to work. A few examples (please excuse the wretched

wget -m -L -np -A jpg

wget -r -l 5 -L -np -A jpg

wget -r -l 5 -L -np -A .jpg

wget -r -l 5 -L -np -Ajpg

wget -r -l 5 -L -np -A.jpg

wget -r -l 5 -L -np -A ".jpg"

wget -r -l 5 -L -np -A "jpg"

Cananyone tell me the proper way to get _only_ the iamges without a lot of

P.S. yes, I know there are other download managers, but I'd really like to
find out how to use wget properly. I suppose curl would be an ok
replacement if it can be set to only d/l images.



< Previous Next >