This is the mail archive of the
cygwin
mailing list for the Cygwin project.
1.7.7: PATH in Bash shells
- From: Gerry Reno <greno at verizon dot net>
- To: cygwin at cygwin dot com
- Date: Sun, 06 Feb 2011 13:33:37 -0500
- Subject: 1.7.7: PATH in Bash shells
What is the proper method to set the PATH variable on a system-wide
basis in Cygwin?
Right now in the Cygwin Bash shell the PATH is set to:
bash-4.1$ echo $PATH
/cygdrive/c/WINDOWS/system32:/cygdrive/c/WINDOWS:/cygdrive/c/WINDOWS/System32/Wb
em:/cygdrive/c/Program Files (x86)/Microsoft SQL
Server/90/Tools/binn/:/usr/bin
I think what I need is for the system-wide PATH to look something like this:
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/cygdrive/c/WINDOWS/system32:/cygdrive/c/WINDOWS:/cygdrive/c/WINDOWS/System32/Wbem:/cygdrive/c/Program
Files (x86)/Microsoft SQL Server/90/Tools/binn/
This is because I have some scripts that I bring over from my Linux
environment that fail under Cygwin because they cannot find executables
in places like /usr/sbin or /usr/local/bin or in the case of some
executables like 'find' they find the Windows version which breaks the
script.
The PATH in my Linux environments looks like this:
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
Is the PATH setting I'm looking for workable with Cygwin?
Or do the Windows paths need to come first for some reason?
I've read this: http://www.cygwin.com/cygwin-ug-net/setup-env.html
But it didn't provide a lot of guidance.
Is there some guiding document about setting PATH system-wide to better
support scripts from Linux?
Regards,
Gerry
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple