Mail Archives: cygwin/2005/03/24/02:17:53
Here's something that stunned me: I see different contents of a
directory I want to be "empty-ish" (c:/cygwin/home), depending on how I
refer to it. I think it's because sometimes, "c:/cygwin" == "/".
$ cygpath -m /
C:/cygwin
$ ls c:/cygwin/home
00-THIS-DIRECTORY-SHOULD-BE-EMPTY.txt
$ cd c:/cygwin/home
$ ls # Doesn't produce: 00-THIS-DIRECTORY-SHOULD-BE-EMPTY.txt !!!
Administrator README.txt cameron luke temp
Guest aplsrv.log demos luke.okay test.prn
HelpAssistant aplsrv01.log desktop.ini raphael test.prn.pdf
James - xyz manipulation aplsrv02.log docs scotty
My Music aplsrv03.log hcp-tools share
My Pictures bad hcp-tools-old stephene
In other words, in c:/cygwin, ls ./home has produced a listing of
d:/home, aka /home. It's as if Cygwin's internal logic has said,
c:/cygwin is "/", therefore find "home" under "/".
Surely that's broken normal Unix file system semantics? If it's not a
bug, but a feature, can anyone explain it? To me it's mind-bogglingly
confusing.
By way of some background, we undo Cygwin's default setup of home to
achieve one thing.
We absolutely don't want home directories to be "inside" Cygwin, since
removing Cygwin would also remove the user files. We don't even want
the home directory on the C: drive, since re-installing Windows would
also remove the user files.
$ mount
C:\cygwin\bin on /usr/bin type system (textmode)
C:\cygwin\lib on /usr/lib type system (textmode)
C:\cygwin on / type system (textmode)
D:\home on /home type system (textmode)
c: on /cygdrive/c type system (textmode,noumount)
d: on /cygdrive/d type system (textmode,noumount)
l: on /cygdrive/l type system (textmode,noumount)
p: on /cygdrive/p type system (textmode,noumount)
u: on /cygdrive/u type system (textmode,noumount)
w: on /cygdrive/w type system (textmode,noumount)
x: on /cygdrive/x type system (textmode,noumount)
y: on /cygdrive/y type system (textmode,noumount)
This is with a new install of a very current Cygwin:
$ cygcheck -s | grep "^cygwin "
cygcheck: dump_sysinfo: GetVolumeInformation() failed: 67
cygwin 1.5.13-1
Have I misunderstood something?
Regards,
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/
- Raw text -