LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 09-15-2010, 08:10 AM   #1
damgar
Senior Member
 
Registered: Sep 2009
Location: dallas, tx
Distribution: Slackware - current multilib/gsb Arch
Posts: 1,949
Blog Entries: 8

Rep: Reputation: 203Reputation: 203Reputation: 203
Need help with downloading from http site (Robby's packages) with file globbing


I've never figured out a good program to use with file globbing from http sites. Wget works with ftp sites and file globbing and for mirroring I use lftp, but I would really like to download just the files that start with "xf" from Robby's site. Any suggestions?
 
Click here to see the post LQ members have rated as the most helpful post in this thread.
Old 09-15-2010, 09:09 AM   #2
XavierP
Moderator
 
Registered: Nov 2002
Location: Kent, England
Distribution: Debian Testing
Posts: 19,192
Blog Entries: 4

Rep: Reputation: 475Reputation: 475Reputation: 475Reputation: 475Reputation: 475
Have you looked at wget? It's installed with Slackware and it's man page describes how to use globbing with it.
 
Old 09-15-2010, 09:18 AM   #3
damgar
Senior Member
 
Registered: Sep 2009
Location: dallas, tx
Distribution: Slackware - current multilib/gsb Arch
Posts: 1,949

Original Poster
Blog Entries: 8

Rep: Reputation: 203Reputation: 203Reputation: 203
Quote:
Originally Posted by XavierP View Post
Have you looked at wget? It's installed with Slackware and it's man page describes how to use globbing with it.
Wget globbing doesn't work for http, only ftp. I wound up using wget after I figured out that Robby has a mirror that has ftp access, but I would still like a way to do file globbing downloads from http sites.

Last edited by damgar; 09-15-2010 at 10:13 AM.
 
Old 09-15-2010, 10:11 AM   #4
Lufbery
Senior Member
 
Registered: Aug 2006
Location: Harrisburg, PA
Distribution: Slackware 64 14.2
Posts: 1,180
Blog Entries: 29

Rep: Reputation: 135Reputation: 135
lftp seems to work pretty well with file globbing.

I downloaded the XFCE stuff from Robby's site with lftp. The command was something like:

Code:
lftp -c "open http://rlworkman.net/pkgs/13.1/ ; mirror -e -n -I xfce* x86_64"
I'm not at home so I can't test it yet, but it should work.

Run it in the directory you want to download into, and it will create a local mirror of Robby's packages in the x86_64 directory.

Obviously, you'll want to change it to what you need.

Edit: I now recall that I ran it again for the Thunnar plugins using -I thunnar* in place of -I xfce*.

Regards,

Last edited by Lufbery; 09-15-2010 at 10:19 AM.
 
3 members found this post helpful.
Old 09-15-2010, 10:23 AM   #5
damgar
Senior Member
 
Registered: Sep 2009
Location: dallas, tx
Distribution: Slackware - current multilib/gsb Arch
Posts: 1,949

Original Poster
Blog Entries: 8

Rep: Reputation: 203Reputation: 203Reputation: 203
Quote:
Originally Posted by Lufbery View Post
lftp seems to work pretty well with file globbing.
Code:
lftp -c "open http://rlworkman.net/pkgs/13.1/ ; mirror -e -n -I xfce* x86_64"
Fantastic! I didn't realize that the lftp commands have individual switches. It was the -I switch that I was overlooking. Thank you.

Code:
lftp -c "open http://rlworkman.net/pkgs/13.1/ ; mirror -I xf* x86_64"
For completeness of record: the -I switch tells the mirror command to include only files matching the following glob-string when it mirrors the target directory.

Last edited by damgar; 09-15-2010 at 10:25 AM.
 
Old 09-15-2010, 11:37 AM   #6
Lufbery
Senior Member
 
Registered: Aug 2006
Location: Harrisburg, PA
Distribution: Slackware 64 14.2
Posts: 1,180
Blog Entries: 29

Rep: Reputation: 135Reputation: 135
Quote:
Originally Posted by damgar View Post
Fantastic! I didn't realize that the lftp commands have individual switches. It was the -I switch that I was overlooking. Thank you.

Code:
lftp -c "open http://rlworkman.net/pkgs/13.1/ ; mirror -I xf* x86_64"
For completeness of record: the -I switch tells the mirror command to include only files matching the following glob-string when it mirrors the target directory.
Yeah, LFTP is pretty cool. the -X switch is helpful too, because it excludes only files matching the glob string when mirroring. So if you wanted everything in Robby's directory except the XFCE stuff, you could use -X xf*.

Regards,
 
Old 09-15-2010, 02:53 PM   #7
XavierP
Moderator
 
Registered: Nov 2002
Location: Kent, England
Distribution: Debian Testing
Posts: 19,192
Blog Entries: 4

Rep: Reputation: 475Reputation: 475Reputation: 475Reputation: 475Reputation: 475
Quote:
Originally Posted by damgar View Post
Wget globbing doesn't work for http, only ftp. I wound up using wget after I figured out that Robby has a mirror that has ftp access, but I would still like a way to do file globbing downloads from http sites.
Apologies. Tiredness made me skip the http and focus on the ftp part of your post. That, and I usually get packages via ftp from Robby and Alien_Bob.
 
Old 09-15-2010, 03:27 PM   #8
damgar
Senior Member
 
Registered: Sep 2009
Location: dallas, tx
Distribution: Slackware - current multilib/gsb Arch
Posts: 1,949

Original Poster
Blog Entries: 8

Rep: Reputation: 203Reputation: 203Reputation: 203
Quote:
Originally Posted by XavierP View Post
Apologies. Tiredness made me skip the http and focus on the ftp part of your post. That, and I usually get packages via ftp from Robby and Alien_Bob.
No problem at all. Thanks for the reply.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
New site to search packages containing a file zerouno Slackware 45 06-12-2012 02:33 PM
File Globbing BlaqkStarSunday Linux - Newbie 5 09-13-2010 06:35 PM
Help downloading files recursively from an http site redir Linux - Newbie 5 04-08-2010 03:52 PM
Need Help With File Globbing jcofell Linux - Newbie 10 10-26-2009 08:22 PM
How does file downloading happen in HTTP and FTP seidren General 4 11-09-2003 08:59 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 04:12 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration