This is the mail archive of the
mailing list for the Cygwin project.
Re: Vim and cursor position
- From: Andrey Repin <anrdaemon at yandex dot ru>
- To: Gary Johnson <garyjohn at spocom dot com>, cygwin at cygwin dot com
- Date: Mon, 15 Feb 2016 00:22:57 +0300
- Subject: Re: Vim and cursor position
- Authentication-results: sourceware.org; auth=none
- References: <56C0AC94 dot 2040901 at gmail dot com> <20160214202433 dot GA3865 at phoenix>
- Reply-to: cygwin at cygwin dot com
Greetings, Gary Johnson!
> Recent releases of the Cygwin Vim package (starting with 7.4.1179-1,
> 2016-01-29) have included Red Hat's or Fedora's /etc/vimrc, which is
> loaded first when starting Vim. That file contains a BufReadPost
> autocommand to do what you observe.
> I don't like it, either, so I have this in my ~/.vimrc:
> " Remove the (annoying) /etc/vimrc autocommand that positions
> " the cursor " to the location it last had when the file was
> " closed.
> if exists("#fedora#BufRead#*")
> au! fedora BufRead *
> if exists("#redhat#BufRead#*")
> au! redhat BufRead *
> For Cygwin, you need only one of those, but I'm at home, my Cygwin
> installation is at work, and I don't remember whether Cygwin uses
> the Fedora or the Red Hat version of /etc/vimrc.
> You may want to take a look at /etc/vimrc and see if it makes any
> other settings you find undesirable and undo them in your ~/.vimrc
> as well.
It may be worthwhile to do this only for certain names of files.
Overall, I find having editor remember where I have been in the code useful.
With best regards,
Monday, February 15, 2016 00:21:34
Sorry for my terrible english...
Problem reports: http://cygwin.com/problems.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple