I'm using Cygwin on Windows because some commands in Windows's CMD are not working but working on terminal of OS X and Linux. When I type the wget
command and URL, it says command not found. Is there any suggestion to fix this.
2 Answers
The wget
command is not installed by default in Cygwin. To install wget
, re-run the Cygwin setup and select the wget
package:
If wget
is selected to install, the screen should look like this:
Click next to complete the installation and run wget
using the Cygwin Terminal
or Cygwin64 Terminal
(if you have installed the 64-bit version).
-
1you may find
wget
under Web instead of Net on newer versions of cygwin Mar 29, 2016 at 23:48 -
As of Windows 10 (version 1803), if you need a HTTP client, curl is now installed by default. On PowerShell, wget is also an alias for Invoke-WebRequest. Jun 21, 2018 at 15:22
Here is an alternative to yjwong's answer, even if it is not a direct answer to your Cygwin problem, it is a Cygwin alternative.
Usually, when i need to take advantage of the power of Linux commands under Windows environnement (for one shot purpose or batch scripting) i don't use an overkill such as Cygwin. I just use UnxUtils.
It provides a lot and main common used Linux commands. These commands run as stand-alone exe files, with no need to install anything on Windows machine.
This is also true if you only need the wget
command.
The download link is here.
Trying it often means adopting it, in most cases :)
-
-
what did you try ? open a
cmd
Windows, thencd
to UnxUtilswbin
folder, then typewget www.yahoo.com
Dec 26, 2013 at 15:02 -
2I realize this is old, but I'd just like to point out that if you'd like to be able to run one Linux command line tool on Windows, it's likely that over time you'll want to run others. And while UnxUtils has a fair number of tools, it's just a "very" small drop in the bucket compared to what Cygwin offers. While being native ports in principal makes them faster than the emulation of Cygwin, in practice I've never found performance to be an issue with Cygwin - and unlike UnxUtils, Cygwin offers very exact and complete fidelity with GNU/Linux. Jul 21, 2017 at 2:45
ls
, works fine ?curl
?