From 4cbecee3efa4fd81b5c7cd4efb85fe06ed927293 Mon Sep 17 00:00:00 2001 From: Simon Ruderich Date: Wed, 29 Jul 2009 15:48:41 +0200 Subject: [PATCH] vimrc: Go to last position of opened files. --- vimrc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/vimrc b/vimrc index 10f0620..5be58ef 100644 --- a/vimrc +++ b/vimrc @@ -228,6 +228,12 @@ if has('autocmd') augroup vimrc autocmd! +" Go to last position of opened files. Taken from :help last-position-jump. + autocmd BufReadPost * + \ if line("'\"") > 1 && line("'\"") <= line("$") | + \ execute "normal! g'\"" | + \ endif + " Use diff filetype for mercurial patches in patch queue. autocmd BufReadPost */.hg/patches/* set filetype=diff -- 2.44.2