<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic wget plus regex in Operating System - Linux</title>
    <link>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727203#M43053</link>
    <description>Hi there &lt;BR /&gt;I need to know why the following comman does not work.&lt;BR /&gt;(ERROR 404: Not Found)&lt;BR /&gt;&lt;BR /&gt;wget -q -O- &lt;A href="http://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/install-x86-minimal-[1-9].iso" target="_blank"&gt;http://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/install-x86-minimal-[1-9].iso&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
    <pubDate>Thu, 16 Dec 2010 05:37:35 GMT</pubDate>
    <dc:creator>Piotr Kirklewski</dc:creator>
    <dc:date>2010-12-16T05:37:35Z</dc:date>
    <item>
      <title>wget plus regex</title>
      <link>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727203#M43053</link>
      <description>Hi there &lt;BR /&gt;I need to know why the following comman does not work.&lt;BR /&gt;(ERROR 404: Not Found)&lt;BR /&gt;&lt;BR /&gt;wget -q -O- &lt;A href="http://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/install-x86-minimal-[1-9].iso" target="_blank"&gt;http://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/install-x86-minimal-[1-9].iso&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 16 Dec 2010 05:37:35 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727203#M43053</guid>
      <dc:creator>Piotr Kirklewski</dc:creator>
      <dc:date>2010-12-16T05:37:35Z</dc:date>
    </item>
    <item>
      <title>Re: wget plus regex</title>
      <link>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727204#M43054</link>
      <description>Hello.&lt;BR /&gt;&lt;BR /&gt;You want to use the "{..}" construct if you want shell to generate arguments (note that this doesn't work with all the shells):&lt;BR /&gt;&lt;BR /&gt;wget -q -O- &lt;A href="http://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/install-x86-minimal-{1..9}.iso" target="_blank"&gt;http://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/install-x86-minimal-{1..9}.iso&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Goran</description>
      <pubDate>Thu, 16 Dec 2010 06:02:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727204#M43054</guid>
      <dc:creator>Goran Koruga</dc:creator>
      <dc:date>2010-12-16T06:02:00Z</dc:date>
    </item>
    <item>
      <title>Re: wget plus regex</title>
      <link>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727205#M43055</link>
      <description>&lt;!--!*#--&gt;&amp;gt; wget [...]&lt;BR /&gt;&lt;BR /&gt;      wget --version&lt;BR /&gt;      uname -a&lt;BR /&gt;&lt;BR /&gt;&amp;gt; I need to know why the following comman&lt;BR /&gt;&amp;gt; does not work.&lt;BR /&gt;&amp;gt; [...]&lt;BR /&gt;&lt;BR /&gt;I'd need to know what you expected it to do.&lt;BR /&gt;&lt;BR /&gt;Whom were you expecting to expand your&lt;BR /&gt;regular expression?  Your shell?  Wget?  The&lt;BR /&gt;(remote) HTTP server?&lt;BR /&gt;&lt;BR /&gt;If you're interested in learning what wget&lt;BR /&gt;tried to do, then you might try adding "-d"&lt;BR /&gt;to your wget command.&lt;BR /&gt;&lt;BR /&gt;Did you look at what's available in:&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/" target="_blank"&gt;http://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;???&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&amp;gt; wget -q -O- [...]&lt;BR /&gt;&lt;BR /&gt;Opinion:&lt;BR /&gt;&lt;BR /&gt;The "-O" option in wget may be particularly&lt;BR /&gt;unwise if you were planning to fetch multiple&lt;BR /&gt;files.&lt;BR /&gt;&lt;BR /&gt;What, exactly, are you trying to do?</description>
      <pubDate>Thu, 16 Dec 2010 06:48:16 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727205#M43055</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2010-12-16T06:48:16Z</dc:date>
    </item>
    <item>
      <title>Re: wget plus regex</title>
      <link>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727206#M43056</link>
      <description>GNU Wget 1.11.4&lt;BR /&gt;Linux pxe001bri 2.6.18-194.el5 #1 SMP Fri Apr 2 14:58:14 EDT 2010 x86_64 x86_64 x86_64 GNU/Linux&lt;BR /&gt;&lt;BR /&gt;wget -O- &lt;A href="http://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/install-x86-minimal-20101123.iso" target="_blank"&gt;http://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/install-x86-minimal-20101123.iso&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;The 20101123 bit of the URL is a subject to frequent changes I do not want to modify this bit every time I need to update my pxe.&lt;BR /&gt;</description>
      <pubDate>Thu, 16 Dec 2010 13:28:20 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727206#M43056</guid>
      <dc:creator>Piotr Kirklewski</dc:creator>
      <dc:date>2010-12-16T13:28:20Z</dc:date>
    </item>
    <item>
      <title>Re: wget plus regex</title>
      <link>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727207#M43057</link>
      <description>I'm trying to  download the most current minimal installation iso for gentoo.&lt;BR /&gt;&lt;BR /&gt;{1..9} does not work either.&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 16 Dec 2010 13:32:04 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727207#M43057</guid>
      <dc:creator>Piotr Kirklewski</dc:creator>
      <dc:date>2010-12-16T13:32:04Z</dc:date>
    </item>
    <item>
      <title>Re: wget plus regex</title>
      <link>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727208#M43058</link>
      <description>Goran assumed you wanted to retrieve these 9 files:&lt;BR /&gt;install-x86-minimal-1.iso&lt;BR /&gt;install-x86-minimal-2.iso&lt;BR /&gt;install-x86-minimal-3.iso&lt;BR /&gt;install-x86-minimal-4.iso&lt;BR /&gt;install-x86-minimal-5.iso&lt;BR /&gt;install-x86-minimal-6.iso&lt;BR /&gt;install-x86-minimal-7.iso&lt;BR /&gt;install-x86-minimal-8.iso&lt;BR /&gt;install-x86-minimal-9.iso&lt;BR /&gt;&lt;BR /&gt;From your reply, I see that is not correct - but that was not obvious from your original post.&lt;BR /&gt;&lt;BR /&gt;Wget does not use regexps in download URLs: only shell-style wildcards. Even those are available only if wget can download a directory listing, i.e. with the FTP protocol only.&lt;BR /&gt;&lt;BR /&gt;(When you browse to "&lt;A href="http://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/" target="_blank"&gt;http://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/&lt;/A&gt;", what you see is an autogenerated index in HTML format. There is no standard way to programmatically identify it as such, and thus it cannot be processed as a directory listing.)&lt;BR /&gt;&lt;BR /&gt;You'll also want the wildcards interpreted by wget, not the shell, so you must quote the wildcard-containing parameters.&lt;BR /&gt;&lt;BR /&gt;You also forgot to include 0 in your wildcard expression: [0-9] instead of [1-9].&lt;BR /&gt;&lt;BR /&gt;Because the filename format is "install-x86-minimal-YYYYMMDD.iso", you must repeat the [0-9] part the appropriate number of times. (Or you might use * instead.)&lt;BR /&gt;&lt;BR /&gt;This will dump the latest ISO to standard output:&lt;BR /&gt;&lt;BR /&gt;wget -q -O- '&lt;A href="ftp://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/install-x86-minimal-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9].iso'" target="_blank"&gt;ftp://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/install-x86-minimal-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9].iso'&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;But you might want to do something like this instead:&lt;BR /&gt;&lt;BR /&gt;wget -O gentoo.iso '&lt;A href="ftp://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/install-x86-minimal-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9].iso'" target="_blank"&gt;ftp://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/install-x86-minimal-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9].iso'&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;This will cause the ISO to be downloaded and saved as "gentoo.iso" in the current directory.&lt;BR /&gt;&lt;BR /&gt;MK</description>
      <pubDate>Thu, 16 Dec 2010 15:06:13 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727208#M43058</guid>
      <dc:creator>Matti_Kurkela</dc:creator>
      <dc:date>2010-12-16T15:06:13Z</dc:date>
    </item>
    <item>
      <title>Re: wget plus regex</title>
      <link>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727209#M43059</link>
      <description>Hello.&lt;BR /&gt;&lt;BR /&gt;I did not want to download anything, it was the original poster who did.&lt;BR /&gt;&lt;BR /&gt;I merely pointed out how he should use the {..} construct to generate URL-s with the help of shell.&lt;BR /&gt;&lt;BR /&gt;But since he failed to tell us how the actual files are named, the proposed solution obviously failed.&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Goran</description>
      <pubDate>Fri, 17 Dec 2010 06:08:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727209#M43059</guid>
      <dc:creator>Goran Koruga</dc:creator>
      <dc:date>2010-12-17T06:08:38Z</dc:date>
    </item>
    <item>
      <title>Re: wget plus regex</title>
      <link>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727210#M43060</link>
      <description>&lt;!--!*#--&gt;Another HTTP possibility to explore might&lt;BR /&gt;look something like:&lt;BR /&gt;&lt;BR /&gt;      wget -r -e robots=off -A .html,.iso \&lt;BR /&gt;       &lt;A href="http://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/" target="_blank"&gt;http://mirrors.kernel.org/gentoo/releases/x86/autobuilds/current-iso/&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;That is, a recursive download on the&lt;BR /&gt;".../current-iso/" index page, accepting only&lt;BR /&gt;(the original) ".html" listing and the one&lt;BR /&gt;".iso" file to be found there.  (Being sure&lt;BR /&gt;to ignore the "robots.txt" file, which&lt;BR /&gt;doesn't want you doing things like this.)&lt;BR /&gt;&lt;BR /&gt;Again, use of "-O" could wreck this whole&lt;BR /&gt;plan, and if anyone ever puts another ".iso"&lt;BR /&gt;file in there, then you'd get that, too.</description>
      <pubDate>Fri, 17 Dec 2010 08:33:08 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/wget-plus-regex/m-p/4727210#M43060</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2010-12-17T08:33:08Z</dc:date>
    </item>
  </channel>
</rss>

