LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 03-03-2022, 10:54 AM   #1
littlebigman
Member
 
Registered: Aug 2008
Location: France
Posts: 660

Rep: Reputation: 35
Question [wget] Show progress when reading URLs from text?


Hello,

Is there a way for wget to show progress when reading an input file?

Code:
wget --config=wgetrc --content-disposition -i urls.txt
When using it to download hundreds of pages, I'd like to see how far it is from completion.

Thaknk you.
 
Old 03-03-2022, 05:09 PM   #2
teckk
LQ Guru
 
Registered: Oct 2004
Distribution: Arch
Posts: 5,156
Blog Entries: 6

Rep: Reputation: 1835Reputation: 1835Reputation: 1835Reputation: 1835Reputation: 1835Reputation: 1835Reputation: 1835Reputation: 1835Reputation: 1835Reputation: 1835Reputation: 1835
Plug wget in to a loop of some kind. And count it.

Simple example for progress bar.
Code:
for ((a = 0; a <= 50 ; a++)); do
    echo -n "[ "
    
    for ((i = 0 ; i <= a; i++)); do 
        echo -n "#"
    done
    
    for ((j = i ; j <= 50 ; j++)); do 
        echo -n " "
    done
    
    v=$((a * 2))
    echo -n " ] "
    echo -n "$v %" $'\r'
    
    sleep .1 #Doing something here.
done
echo -e "\nDownload complete"
 
Old 03-04-2022, 01:21 AM   #3
littlebigman
Member
 
Registered: Aug 2008
Location: France
Posts: 660

Original Poster
Rep: Reputation: 35
Thanks for the work-around.
 
  


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
[SOLVED] wget from text files containing urls in seperate lines. junomario Linux - Newbie 15 02-26-2022 06:55 AM
progress - to monitor progress of commands robertkwild CentOS 20 10-04-2017 06:35 PM
LXer: How to monitor progress of Linux commands using PV and Progress utilities LXer Syndicated Linux News 0 11-11-2016 07:01 PM
wget failing to download some URLs moob8 Linux - General 7 07-20-2011 06:50 AM
how to check urls and stop internet urls in network gface Linux - Networking 5 03-24-2005 09:48 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 03:32 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