What would you reccommend as makeprg
for compiling nroff
documents (for man pages)? I currently have it set to mandoc
because it works when I do it from the terminal: mandoc foo.1
When I run :make
, it escapes to the terminal and the output stream produced appears to be fine. However the content loaded into the quickfix window is messed up and has weird characters:
|| sstt [--aaiivv] [--cc _c_l_a_s_s] [--ff _f_o_n_t] [--gg _g_e_o_m_e_t_r_y] [--nn _n_a_m_e] [--oo _i_o_f_i_l_e] [--TT
|| _t_i_t_l_e] [--tt _t_i_t_l_e] [--ll _l_i_n_e] [--ww _w_i_n_d_o_w_i_d] [[--ee] _c_o_m_m_a_n_d [_a_r_g_u_m_e_n_t_s...]]
||
|| sstt [--aaiivv] [--cc _c_l_a_s_s] [--ff _f_o_n_t] [--gg _g_e_o_m_e_t_r_y] [--nn _n_a_m_e] [--oo _i_o_f_i_l_e] [--TT
|| _t_i_t_l_e] [--tt _t_i_t_l_e] [--ww _w_i_n_d_o_w_i_d] -l _l_i_n_e [_s_t_t_y___a_r_g_s...]
||
|| DDEESSCCRRIIPPTTIIOONN
|| sstt is a simple terminal emulator.
I tried using the -K
(encoding flag) with the available options like utf-8
, etc. But it does not seem to work. Any thoughts? It would be really nice to load the compiled man page in a separate split like you can load man pages using the ftplugin/man.vim
script and invoking :Man ...
(with all the nice syntax highlighting)
On a related note, the quickfix window does not open automatically and I have the following autocommand set (works in all other cases)
autocmd QuickFixCmdPost [^l]* cwindow
man
will work, but you need an appropriateerrorformat
! For the separate window, maybenew | read !mandoc # | set filetype=man
?