aboutsummaryrefslogtreecommitdiff
path: root/vim/autoload/select_old_files.vim
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2019-06-16 17:16:17 +1200
committerTom Ryder <tom@sanctum.geek.nz>2019-06-16 17:16:17 +1200
commit55dcfa3c363739cce2a792de8052d55bf46ca9e1 (patch)
tree975f9f4720f69c77b9283de2302afe2d70e46178 /vim/autoload/select_old_files.vim
parentMerge branch 'release/v6.14.0' (diff)
parentBump VERSION (diff)
downloaddotfiles-55dcfa3c363739cce2a792de8052d55bf46ca9e1.tar.gz
dotfiles-55dcfa3c363739cce2a792de8052d55bf46ca9e1.zip
Merge branch 'release/v6.15.0'v6.15.0
* release/v6.15.0: Spruce up mapping comments Set target dependencies on install-vim-autoload Adapt :browse :oldfiles mapping into plugin Add <Leader>,o mapping to :browse :oldfiles Map Backspace to CTRL-^ (:edit alt buffer) in Vim Use "written" not "saved" in vimrc comments Conform reloading vimrc message comment to truth
Diffstat (limited to 'vim/autoload/select_old_files.vim')
-rw-r--r--vim/autoload/select_old_files.vim7
1 files changed, 7 insertions, 0 deletions
diff --git a/vim/autoload/select_old_files.vim b/vim/autoload/select_old_files.vim
new file mode 100644
index 00000000..518b98d4
--- /dev/null
+++ b/vim/autoload/select_old_files.vim
@@ -0,0 +1,7 @@
+function! select_old_files#() abort
+ let oldfiles = v:oldfiles
+ let limit = get(g:, 'select_old_files_limit', &lines - 1)
+ let v:oldfiles = v:oldfiles[:limit-2]
+ browse oldfiles
+ let v:oldfiles = oldfiles
+endfunction