bugGNU Wget - Bugs: bug #20517, wildcard documentation of -X

 
 

bug #20517: wildcard documentation of -X

Submitter:  Noël Köthe <nok>
Submitted:  Wed 18 Jul 2007 06:57:32 PM UTC
   
 
Category:  Documentation Severity:  3 - Normal
Priority:  5 - Normal Status:  Cannot Reproduce
Privacy:  Public Assigned to:  None
Originator Name:  Open/Closed:  Closed
Release:  1.10.2 Operating System:  GNU/Linux
Reproducibility:  None Fixed Release:  None
Planned Release:  1.11 Regression:  None
Work Required:  0 - Hours Patch Included:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Fri 14 Jan 2011 02:35:08 PM UTC, comment #4: 

I give up - I will attach my comment as a file if you want to read it. To summarise I experimented and found the wildcards work in some case but not others (where non-wildcard versions do). So currently the documentation is inadequate but if the software is fixed it might not be so bad.

Jim Wright <jimwrightbe>
Fri 14 Jan 2011 02:31:40 PM UTC, comment #3: 

This simplified version quickly excludes a file under /contact (try it without /contac*) but fails to exclude a file under /music/detail.

$ wget -Ahtml -r -X '/contac*,/music/deta*' http://comhaltas.ie/shop/detail/foinn_seisiun_cd_volume_2/index.html

... stuff removed here

2011-01-14 14:41:23 (56.8 KB/s) - `comhaltas.ie/music/detail/garrett_barrys_jig/index.html' saved [16485]

--2011-01-14 14:41:23--  http://comhaltas.ie/music/detail/michael_hynes/
Connecting to comhaltas.ie|217.115.117.192|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/html]
Saving to: `comhaltas.ie/music/detail/michael_hynes/index.html'
+verbatim+

Jim Wright <jimwrightbe>
Fri 14 Jan 2011 02:29:16 PM UTC, comment #2: 

What is it that works for you? I am trying to use wildcards in:

  • GNU Wget 1.11.4 Red Hat modified
  • GNU Wget 1.12 under Fedora 14

and failing. The title of this bug mentions documentation and part of the problem here and in the docs is that it is not clear what is supposed to work (hence difficult to say if there is a software bug).

BTW Potential software issues are covered by bug #28776.
This wildcard example from bug #28776 does not work for me under Fedora:

wget -A html,mp3 -r -l3 -k -nc -I '/music/detail,/audio' -X '/music/detail/*/lang' http://comhaltas.ie/shop/detail/foinn_seisiun_cd_volume_2/index.html
+verbatim+
E.g.:
+verbatim+
2011-01-14 14:16:05 (54.2 KB/s) - `comhaltas.ie/music/detail/longford_collector/lang/en/index.html' saved [16198]
+verbatim+
This simplified version quickly excludes a file under /contact (try it without /contac*) but fails to exclude a file under /music/detail.
+verbatim+
$ wget -Ahtml -r -X '/contac*,/music/deta*' http://comhaltas.ie/shop/detail/foinn_seisiun_cd_volume_2/index.html

... stuff removed here

2011-01-14 14:41:23 (56.8 KB/s) - `comhaltas.ie/music/detail/garrett_barrys_jig/index.html' saved [16485]

--2011-01-14 14:41:23--  http://comhaltas.ie/music/detail/michael_hynes/
Connecting to comhaltas.ie|217.115.117.192|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/html]
Saving to: `comhaltas.ie/music/detail/michael_hynes/index.html'
+verbatim+


What is it that works for you? I am trying to use wildcards in:
* GNU Wget 1.11.4 Red Hat modified
* GNU Wget 1.12 under Fedora 14

After much experimentation I can do what I want but I seem to be working around bugs. However, the title of this bug mentions "documentation" and without examples (in the docs or above) it is difficult to know what is a bug. So I suggest this ticket is and should be first of all about the documentation problem.

Potential software issues are covered by bug #28776.
This wildcard example from bug #28776 does not work for me under Fedora:
+verbatim+
wget -A html,mp3 -r -l3 -k -nc -I '/music/detail,/audio' -X '/music/detail/*/lang' http://comhaltas.ie/shop/detail/foinn_seisiun_cd_volume_2/index.html
+verbatim+
E.g.:
+verbatim+
2011-01-14 14:16:05 (54.2 KB/s) - `comhaltas.ie/music/detail/longford_collector/lang/en/index.html' saved [16198]
+verbatim+
This simplified version quickly excludes a file under /contact (try it without /contac*) but fails to exclude a file under /music/detail.
+verbatim+
$ wget -Ahtml -r -X '/contac*,/music/deta*' http://comhaltas.ie/shop/detail/foinn_seisiun_cd_volume_2/index.html

... stuff removed here

2011-01-14 14:41:23 (56.8 KB/s) - `comhaltas.ie/music/detail/garrett_barrys_jig/index.html' saved [16485]

--2011-01-14 14:41:23--  http://comhaltas.ie/music/detail/michael_hynes/
Connecting to comhaltas.ie|217.115.117.192|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/html]
Saving to: `comhaltas.ie/music/detail/michael_hynes/index.html'
+verbatim+
i.e. this use of wildcards:
+verbatim+
/music/deta*
+verbatim+
does not match /music/detail/michael_hynes but both of these do!
+verbatim+
/music/detail
/music/detai*/*
+verbatim+
Strange but true (buggy, presumably).

Jim Wright <jimwrightbe>
Sat 15 Sep 2007 01:02:06 AM UTC, comment #1: 

Works for me, both with Debian's 1.10.2 and the current trunk.

Micah Cowan <micahcowan>
Wed 18 Jul 2007 06:57:32 PM UTC, original submission:  

Hello,

a forwarded Debian bug: http://bugs.debian.org/215128

"One of the options to wget is -X followed by a list of directories to exclude when following links.  In the man page and in the "Recursive Accept/Reject Options" section of the info file it says that wildcards can be used in this list.  In the more detailed "Following Links/Directory-Based Limits" no mention is made of wildcards.  I tried -X "/Tmp/has*comma" in order to exclude a directory named /Tmp/has,comma, but the contents of /Tmp/has,comma were downloaded and saved anyway.
"

I checked the info page and there is no info how to use wildcards where the manpage says "Elements of list may contain wildcards."

thx.

Noël Köthe <nok>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #22410:  jimwrightcomment.txt added by jimwrightbe (2KiB - text/plain - What I intended instead of comments 2, 3 and 4)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by jimwrightbe (Posted a comment)
  • -email is unavailable- added by micahcowan (Updated the item)
  • -email is unavailable- added by nok (Submitted the item)
  •  

    Follow 6 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2011-01-14 jimwrightbe Attached File- Added jimwrightcomment.txt, #22410
    2007-09-15 micahcowan StatusNeeds Discussion Cannot Reproduce
        Open/ClosedOpen Closed
    2007-09-13 micahcowan StatusNone Needs Discussion
    2007-07-20 micahcowan Planned ReleaseNone 1.11
        Work RequiredNone 0 - Hours

    Back to the top

    Powered by Savane 3.13-0329.
    Corresponding source code