Bug 40469

Summary: viminfo is not being read
Product: [Retired] Red Hat Linux Reporter: Hal Burgiss <hburgiss>
Component: vimAssignee: Bernhard Rosenkraenzer <bero>
Status: CLOSED WORKSFORME QA Contact: David Lawrence <dkl>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.1   
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2001-05-14 04:45:50 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Hal Burgiss 2001-05-14 04:45:26 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux 2.4.2-2smp i686; en-US; rv:0.9+)
Gecko/20010507

Description of problem:
Vim is not saving/restoring the cursor position from ~/.viminfo 
data. It always goes to the top of the file. I don't think it is 
being read. I've tried on two machines, one stock, one slightly 
modified built from src.rpm (7.1 src.rpm). Same results on both, 
and same results with vim-X11 and enhanced-vim. Looking at .viminfo,
it is indeed being updated, just apparently not read when vim 
opens a file.


[hal@feenix hal]$ vim +version +q!  |grep viminfo
+vertsplit +virtualedit +visual +visualextra +viminfo +wildignore +wildmenu
+windows
[hal@feenix hal]$ grep viminfo .vimrc
set viminfo='25,h
[hal@feenix hal]$ strace -o /tmp/trace vim -g ~/.vimrc
[hal@feenix hal]$ grep viminfo /tmp/trace
<nada>

Sanity check:

[hal@feenix hal]$ grep \.vimrc /tmp/trace |wc -l
     15


How reproducible:
Always

Steps to Reproduce:
1.open file, move cursor down
2.close file
3.re-open file, and find cursor at top.
	

Actual Results:  As expected.

Expected Results:  Cursor should move to previous mark in file at the time
it was 
closed. At least, this is how it worked on previous versions 
(vim 5.7).

Additional info:

Comment 1 Bernhard Rosenkraenzer 2001-05-14 10:14:44 UTC
Works here... Make sure you aren't turning the feature off in your ~/.vimrc.

Also, vim-minimal doesn't have this feature.


Comment 2 Hal Burgiss 2001-05-14 14:22:43 UTC
Well, this clearly is not vim minimal. Anyway, through process of elimination 
I found that this was caused by 'autocmd!' in .vimrc. Commenting this 
out, solves problem. This line has been there through many versions of vim,
so not sure what the deal is with 6.0.