up vote 1 down vote favorite
share [g+] share [fb]

I installed Cygwin on my Windows XP machine. How can I add c:\cygwin\bin to the %PATH% in such a way that it persists?

My autoexec.bat is empty, and I assume it's no longer the right place for that. Where's the best place to do this?

link|improve this question

52% accept rate
feedback

2 Answers

up vote 8 down vote accepted

Right click on my computer and select properties. Theres a section in there for environment variables on the advanced tab. The path variable is in there, just add a semicolon and then the cygwin path to the end of the existing value.

link|improve this answer
2  
It's the Advanced tab. – random Aug 22 '09 at 7:35
Thx I just went blank on that and haven't got my windows pc switched on. – Col Aug 22 '09 at 7:48
feedback

To add to your user profile path you can do the following from the command line using the setx command which is built into Windows Vista and above. In earlier versions of Windows you can use the Windows Resource Kit to get it.

Say Cygwin in installed in c:\cygwin, do:

SETX path c:\cygwin;c:\cygwin\bin;%path%

Or for you, as user only:

SETX -m path c:\cygwin;c:\cygwin\bin;%path%
link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.