diff options
Diffstat (limited to 'runtime/autoload/man.vim')
-rw-r--r-- | runtime/autoload/man.vim | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/runtime/autoload/man.vim b/runtime/autoload/man.vim index dab88fde23..486ed99e3f 100644 --- a/runtime/autoload/man.vim +++ b/runtime/autoload/man.vim @@ -13,8 +13,6 @@ function! man#init() abort try " Check for -l support. call s:get_page(s:get_path('', 'man')) - catch /E145:/ - " Ignore the error in restricted mode catch /command error .*/ let s:localfile_arg = v:false endtry @@ -436,8 +434,11 @@ function! man#goto_tag(pattern, flags, info) abort let l:structured = [] for l:path in l:paths - let l:n = s:extract_sect_and_name_path(l:path)[1] - let l:structured += [{ 'name': l:n, 'path': l:path }] + let [l:sect, l:name] = s:extract_sect_and_name_path(l:path) + let l:structured += [{ + \ 'name': l:name, + \ 'title': l:name . '(' . l:sect . ')' + \ }] endfor if &cscopetag @@ -448,7 +449,7 @@ function! man#goto_tag(pattern, flags, info) abort return map(l:structured, { \ _, entry -> { \ 'name': entry.name, - \ 'filename': 'man://' . entry.path, + \ 'filename': 'man://' . entry.title, \ 'cmd': '1' \ } \ }) |