diff options
author | Matthieu Coudron <mattator@gmail.com> | 2020-07-19 21:55:12 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-07-19 21:55:12 +0200 |
commit | e1d1c413f7c42ba36dfe49bfd9db977045bff66a (patch) | |
tree | 31ee7ceadeb6f3f6d79b81e2bc04a4d63d21453a /runtime/ftplugin | |
parent | 6fcbcf72c37b35713debc8c304182699d0e85b2e (diff) | |
parent | e8ccd0f2347feb26071e8667d24f3281db79ede3 (diff) | |
download | rneovim-e1d1c413f7c42ba36dfe49bfd9db977045bff66a.tar.gz rneovim-e1d1c413f7c42ba36dfe49bfd9db977045bff66a.tar.bz2 rneovim-e1d1c413f7c42ba36dfe49bfd9db977045bff66a.zip |
Merge pull request #12480 from nhooyr/mansect-trim
man.vim: Refactor verify_exists to unset $MANSECT as needed
Diffstat (limited to 'runtime/ftplugin')
-rw-r--r-- | runtime/ftplugin/man.vim | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/runtime/ftplugin/man.vim b/runtime/ftplugin/man.vim index 081181cfe9..0416e41368 100644 --- a/runtime/ftplugin/man.vim +++ b/runtime/ftplugin/man.vim @@ -6,7 +6,7 @@ if exists('b:did_ftplugin') || &filetype !=# 'man' endif let b:did_ftplugin = 1 -let s:pager = get(s:, 'pager', 0) || !exists('b:man_sect') +let s:pager = !exists('b:man_sect') if s:pager call man#init_pager() @@ -26,7 +26,7 @@ if !exists('g:no_plugin_maps') && !exists('g:no_man_maps') nnoremap <silent> <buffer> j gj nnoremap <silent> <buffer> k gk nnoremap <silent> <buffer> gO :call man#show_toc()<CR> - if 1 == bufnr('%') || s:pager + if s:pager nnoremap <silent> <buffer> <nowait> q :lclose<CR>:q<CR> else nnoremap <silent> <buffer> <nowait> q :lclose<CR><C-W>c |