Skip to content

Commit

Permalink
Vim: make <Ctrl-^> go to last file, not to netrw
Browse files Browse the repository at this point in the history
It has long annoyed me that once I've started to explore the directory
of a file using vim-vinegar's `-` mapping, I can't easily get back to
the file with `<space><space>` (ie. `<leader><leader>`) or `<C-^>`.
Thanks to @wincent [0], I have found a workaround:

  tpope/vim-vinegar#25

Unfortunately, this doesn't fix my other annoyance of netrw polluting
the jumplist. Looking at `:help netrw` it looks like `g:netrw_keepj`
intends to do this and it is defaulted to "keepj" (on), but it isn't
quite as good as I would like.

[0]: wincent/wincent@337792ff
  • Loading branch information
lencioni committed Feb 21, 2016
1 parent 461fb9b commit 7e8cb3d
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions .vim/plugin/netrw.vim
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
let g:netrw_altfile = 1 " Make <Ctrl-^> go to the last file, not to netrw

0 comments on commit 7e8cb3d

Please sign in to comment.