VIM - Vi IMproved 6.4 (2005 Oct 15, compiled Oct 17 2005 11:54:34

Igor Pechtchanski pechtcha@cs.nyu.edu
Fri Nov 4 00:49:00 GMT 2005


On Fri, 4 Nov 2005, Michael Schaap wrote:

> On 20-Oct-2005 16:42, Christopher Faylor wrote:
> > On Thu, Oct 20, 2005 at 04:15:34PM +0200, Christoph Jeksa wrote:
> >
> >> there is a bug in this version:
> >>
> >> Supposed, you have a file X.sh ( exactly in this spelling ).  If you
> >> enter:
> >>
> >> vim x.sh ( also exactly in this spelling )
> >>
> >> and write it back after any modification, the file will be renamed even
> >> to x.sh.  This behavior is very nasty if such file is used by programs
> >> which are case-sensitive for file names, example: SCM program perforce.
> >
> > This isn't a vim problem.  Windows filename handling is case-insensitive.
> >
> > I suppose that there could be a vim option to deal with this case but
> > that would require modifying vim, i.e., PTC* by the upstream vim
> > developers.
>
> Actually, there already is such an option...
>
>     $ touch X
>     $ ls -l
>     total 0
>     -rw-r--r--  1 mscha None 0 Nov  4 01:29 X
>     $ vim x
>     :wq!
>     $ ls -l
>     total 0
>     -rw-r--r--  1 mscha None 0 Nov  4 01:30 x
>     $ rm x
>     $ touch X
>     $ vim -c 'set backupcopy=yes' x
>     :wq!
>     $ ls -l
>     total 0
>     -rw-r--r--  1 mscha None 0 Nov  4 01:30 X
>
> See ":help backupcopy" for details.  It defaults to "auto", which is
> kinda unpredictable.  Set it to "yes", and it might be a bit slower, but
> won't mess with your case.  :-)

More interestingly, ":help backupcopy" says:

(Vi default for Unix: "yes", otherwise: "auto")

This means that VIm treats Cygwin as non-Unix.  Shouldn't the Cygwin
default be the same as for Unix?
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_		pechtcha@cs.nyu.edu
ZZZzz /,`.-'`'    -.  ;-;;,_		igor@watson.ibm.com
     |,4-  ) )-,_. ,\ (  `'-'		Igor Pechtchanski, Ph.D.
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

If there's any real truth it's that the entire multidimensional infinity
of the Universe is almost certainly being run by a bunch of maniacs. /DA

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



More information about the Cygwin mailing list