Mercurial > vim
diff runtime/ftplugin/man.vim @ 12826:f690da1b3c04
Update runtime files.
commit https://github.com/vim/vim/commit/7f2e9d7c9cdfc5201a899b7b610edf64bf80c45f
Author: Bram Moolenaar <Bram@vim.org>
Date: Sat Nov 11 20:58:53 2017 +0100
Update runtime files.
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Sat, 11 Nov 2017 21:00:05 +0100 |
parents | 523cd59d6db0 |
children | 371ceeebbdaa |
line wrap: on
line diff
--- a/runtime/ftplugin/man.vim +++ b/runtime/ftplugin/man.vim @@ -1,7 +1,7 @@ " Vim filetype plugin file " Language: man " Maintainer: SungHyun Nam <goweol@gmail.com> -" Last Change: 2017 Jan 18 +" Last Change: 2017 Nov 11 " To make the ":Man" command available before editing a manual page, source " this script from your startup vimrc file. @@ -15,12 +15,6 @@ if &filetype == "man" endif let b:did_ftplugin = 1 - " Ensure Vim is not recursively invoked (man-db does this) - " when doing ctrl-[ on a man page reference. - if exists("$MANPAGER") - let $MANPAGER = "" - endif - " allow dot and dash in manual page name. setlocal iskeyword+=\.,- @@ -176,7 +170,11 @@ func <SID>GetPage(...) let $MANWIDTH = winwidth(0) let unsetwidth = 1 endif - silent exec "r !man ".s:GetCmdArg(sect, page)." | col -b" + + " Ensure Vim is not recursively invoked (man-db does this) when doing ctrl-[ + " on a man page reference by unsetting MANPAGER. + silent exec "r !env -u MANPAGER man ".s:GetCmdArg(sect, page)." | col -b" + if unsetwidth let $MANWIDTH = '' endif