This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: Renaming YELLER'S directories to something less aloud (Was: case sensitivity and filenames)


> From: cygwin-owner@cygwin.com [mailto:cygwin-owner@cygwin.com]On Behalf
> Of Larry Hall (RFK Partners, Inc.)

> >>Works fine for me.  Maybe you reset CYGWIN in an rc file?
> >>
> >
> >
> > $ cd ; pwd ; whoami ; ls -A; grep -i CYGWIN *
> > /home/Hannu
> > Hannu
<ls output+NOTHING FOUND>
--8<--
>
> Maybe check /etc too?
>
 Hmm... I've regarded /etc to be a bad place to change files.
With the exception of unavoidable stuff as e.g. /etc/{passwd,group} .

--8<--
>
>
> Actually, I should've checked some of these details before
> posting.  Cygwin
> mv renames a *file* just fine when the name only differs by case.
> Directories are still an issue.  AFAICS, this is the same as in DOS using
> 'move'.  It works fine in DOS if you use 'rename' but that's different
> command with different semantics.

 I downloaded "/usr/src/fileutils-4.1-1/src" and had a look... mv.c uses
functions from copy.c to copy files, then deletes/backups as it seems.
 There seems to be detection of "copy_to_self" on directories... but the
detection seems to be a bit odd; i.e. not very clear.
 Any changes not taking place in mv.c will affect cp.c too. <sigh>

> >    mv FILE File
> > should be have worked.
>
> Actually, the above does work in Cygwin if 'FILE' is a file.

 Yes, I noticed... I'd say there is a chance this works the same way on
other platforms too, in both cases.


Hannu:
> > "Testcase"
> >
> > $ mkdir -p TEST/OBJECT;cd TEST;mv OBJECT Object; \
> >   find -printf "%p\n"; cd ..; rm -rf TEST
> >
> > mv: cannot create directory
>
>`Object/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJE
CT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJ
ECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT/OBJECT':
File or path name too long
> > .
> > ./OBJECT
> > ./OBJECT/OBJECT
> > ./OBJECT/OBJECT/OBJECT
> > ./OBJECT/OBJECT/OBJECT/OBJECT
> > ...

Anyone running Linux/Unix here? Can we have the above test done? ;-)

/Hannu E K Nevalainen, Mariefred, Sweden
-- 60 km to Stockholm <- @ 59?17'N, 18?1'E --

--END OF MESSAGE--


--
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/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]