Today’s browser can fulfill the downloading needs for an average internet user but when it comes to more customized downloading requirements, lets say downlaod all videos stored on a website, they all pretty much suck. Every now and then I encounter broken file downlaods and it gives me so much pain when I see them start downloading from the scratch again. So here, I am going to equip you all with a tool that will give you total control on almost everything you would ever want to downlaod from the internet.
First let me tell you what “wget” is!!
Wget, stands for web get, is basically a command line tool that has hundreds of customizable options giving you total access over what, how and when you want to download something. You need to write just one single command and Boom! You have one less thing to worry about in the world.
For me, the format of the command that we need to write is probably easier than writing Arnold Schwarzenegger’s name and goes like this
wget [options]… [Web URL]…
And before diving into what and how to get things done using wget, lets go over the installation procedure.
For Linux users:
- Just open a terminal window using Ctrl+Alt+T and paste in the following command
sudo apt-get install wget
Type in your password and hit enter.
For Windows users:
- Head over to the following link to downlaod the installer .exe file, run and install it.
- We need to do one more thing that is to include the wget.exe path in the System PATH variable, to do that
- Copy the path of the directory where wget.exe is located in installation directory, which should look something like this
- Paste this path in system’s PATH variable. If some paths are already present then put a semicolon at the end of the whole text in PATH variable and then paste this copied path.
- Press Windows+R to open ‘Run’ dialog box. Type in cmd and press Enter. This should open the command prompt.
- Type in the following and press Enter.
set PATH=%PATH%;C:\Program Files(x86)\GnuWin32\bin
Say you want to downlaod the file filename.pdf with the same name in your current working directory. Use
Now say, you wan’t it to be saved under a different name, use the following instead
wget –output-document=newname.pdf sitename.com/filename.pdf
the option “–output-document=newname.pdf” tells wget to store the downloaded file with the name newname.pdf
Say, your above download got interuppted, to resume the downlaod at any later time use
wget –continue –output-document=newname.pdf sitename.com/filename.pdf
Here the “–continue” option is the one telling wget to resume the download.
These wget commands are very basic and are only the tip of the iceburg, so to say, but can save you a lot of time. To know more about the custom uses and explore more powerful options of this tool, click on the following link to head over to my other article where I discuss more advanced uses of wget.
Image Source: lintut.com