This is the mail archive of the
cygwin
mailing list for the Cygwin project.
A good way to test if Cygwin isn't installed?
- From: luke dot kendall at cisra dot canon dot com dot au
- To: cygwin at cygwin dot com
- Date: Fri, 1 Oct 2004 14:51:01 +1000 (EST)
- Subject: A good way to test if Cygwin isn't installed?
I just wanted to run an idea past the list.
I want to write a shell script to test if Cygwin has been installed on
the machine running the shell script.
I do this by running a shell (from a network install of Cygwin if
necessary).
If Cygwin is installed on the local machine, then "cygpath -w /"
returns something like "c:\cygwin". (Good for discovering what drive
Cygwin was installed on, right?) If Cygwin has not been installed,
"cygpath -w /" returns a plain old backslash.
That's fine - maybe even great. My question: is that a reliable way to
perform that test? It seems good to me.
I'm working my way towards a shell script that installs or upgrades
Cygwin on a machine that may or may not have Cygwin installed, and do
all our local post-install stuff (which is a lot of stuff), and also
test that at least the major packages from the install work properly.
luke
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/