This is gonna sound very simple for you guys but I've never installed cygwin and the tutorial I used gave no contingency plan for when something goes wrong. I added the path C:\cygwin\bin to my Path and when I try to run ls or pwd from cmd.exe nothing seems to work. What did I do wrong with this install?
2 Answers
You have a spurious extra space in your path setting just before the C:\cygwin\bin
entry: ...wsPowerShell\v1.0\; C:\cygwin\bin;C:\Program Files\Com...
. Do you see it now?
-
Okay thanks! I wasnt getting why it didn't work. Can you give an explanation of why this has to be set with no spaces? Dec 28, 2012 at 0:41
-
Because pathnames on Windows can have spaces and the parsing algorithm is really simple. It just assumes anything between semicolons must be a directory name, spaces and all. Dec 28, 2012 at 0:51
-
@user1669657 Glad I was able to help. If this answers your question, I'd appreciate an upvote and an accept. Dec 28, 2012 at 1:31
The Cygwin installer should be creating a shortcut for a Cygwin prompt. You shouldn't need to be changing your PATH or anything. Actually, if you're using a recent Cygwin, the default terminal program is now mintty
. If really necessary (though it shouldn't be), you can manually create a shortcut that runs C:\cygwin\bin\mintty.exe
.
-
True, but it should work fine if you put
C:\Cygwin\bin
on your path and run the Cygwin stuff fromcmd.exe
. You don't have to use their shortcut andbash
starts faster if you don't. Dec 27, 2012 at 23:29
cmd.exe
or whatever it was you were using to runls
so it could inherit the new path variable?set path
intocmd.exe
? Can you paste it here, please? I suspect you may have a typo that could be hard to spot.