public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: Gary Johnson <garyjohn@spocom.com>
To: cygwin@cygwin.com
Subject: Re: 1.7.35: possible backspace key and arrow keys bug
Date: Fri, 10 Apr 2015 20:35:00 -0000	[thread overview]
Message-ID: <20150410203520.GB13043@phoenix> (raw)
In-Reply-To: <mg999s$hm9$1@ger.gmane.org>

On 2015-04-10, René Berber wrote:
> On 4/10/2015 2:21 PM, Gary Johnson wrote:
> > On 2015-04-09, René Berber wrote:
> 
> >> Why vim on Cygwin doesn't install, or use if you add one, /etc/vimrc?
> > 
> > Executing
> >     $ vim --version
> > shows
> >        system vimrc file: "$VIM/vimrc"
> >          user vimrc file: "$HOME/.vimrc"
> >      2nd user vimrc file: "~/.vim/vimrc"
> >           user exrc file: "$HOME/.exrc"
> >       fall-back for $VIM: "/etc"
> >      f-b for $VIMRUNTIME: "/usr/share/vim/vim74"
> > From within vim,
> >     :echo $VIM
> > shows
> >     /usr/share/vim
> ...
> > So, Cygwin's vim looks for the system vimrc at /usr/share/vim/vimrc,
> > not /etc/vimrc.
> ...
> > Personally, I really like that Cygwin does not include a system
> > vimrc in its vim package.
> 
> Two points:
> 
> 1. Users expect things to work out-of-the-box.  As shown by this thread
> vim is not.

It does work out of the box.  It just may not be configured as you'd
like.  But your point is well taken.  If vim is pre-configured on
Red Hat or Ubuntu systems, then for most users it should probably be
pre-configured on Cygwin.  I can work around it.

> 2. If there is a standard, it should be used.  Moving from Linux to
> Cygwin should be transparent, but in the former there is an /etc/vimrc,
> in the later there isn't, and even more confusing: if you add one it
> doesn't work (for the reason you showed).

The Red Hat standard is /etc/vimrc.  The Ubuntu standard is
/usr/share/vim/vimrc.

> > I don't understand what you mean that the 5th line doesn't work and
> > has to be commented.
> 
> It means that if you leave it, vim will complain when you start it:
> 
> "Error detected while processing /etc/virc:
> line    5:
> E319: Sorry, the command is not available in this version: syntax on"

In most distributions, vi is vim-small or vim-tiny.  In Fedora and
Cygwin, vi is vim-small.  In Ubuntu, the vim version installed as vi
apparently depends on which vim package(s) you have installed and
may be vim-tiny or vim-huge.

The tiny and small versions do not support syntax highlighting.  See
the output of ":version".  Also see ":help :version" for a list of
which features are supported in which versions.  You should not
expect "syntax on" or any other vim command not found in the
original vi to work in /etc/virc.

> The point is: why does it work when in ~/.vimrc, and not on /etc/virc
> (not a typo, /etc/vimrc is not used at all, another deviation from the
> standard?).

Which configuration files are read depends on whether you execute
"vi" or "vim".

Regards,
Gary


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

      reply	other threads:[~2015-04-10 20:35 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-08 13:42 George jiang
2015-04-08 19:38 ` JAS gmail
2015-04-08 22:09   ` Adam Dinwoodie
2015-04-08 22:16 ` Adam Dinwoodie
2015-04-09 16:55   ` Weston Turner
2015-04-09 17:28     ` David Macek
2015-04-09 17:34     ` Corinna Vinschen
2015-04-09 18:53       ` René Berber
2015-04-09 19:25         ` Corinna Vinschen
2015-04-10 19:22         ` Gary Johnson
2015-04-10 19:46           ` René Berber
2015-04-10 20:35             ` Gary Johnson [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150410203520.GB13043@phoenix \
    --to=garyjohn@spocom.com \
    --cc=cygwin@cygwin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).