runtime(pandoc): update YAML metadata block parsing in compiler runtime Commit: https://github.com/vim/vim/commit/1aa68dffbf2a80d143ee0e659289dbbc430606af Author: Alexander Abrosimov <alexander.n.abrosi...@gmail.com> Date: Thu May 15 20:06:29 2025 +0200
runtime(pandoc): update YAML metadata block parsing in compiler runtime Previously the incorrect regexp forced title to be a single letter because of using '+' instead of the '\+' regexp modifier. closes: #17321 Signed-off-by: Alexander Abrosimov <alexander.n.abrosi...@gmail.com> Signed-off-by: Christian Brabandt <c...@256bit.org> diff --git a/runtime/compiler/pandoc.vim b/runtime/compiler/pandoc.vim index 5d90a518c..40d2d0263 100644 --- a/runtime/compiler/pandoc.vim +++ b/runtime/compiler/pandoc.vim @@ -2,6 +2,7 @@ " Compiler: Pandoc " Maintainer: Konfekt " Last Change: 2024 Nov 19 +" 2025 May 15 Update the title regex for CompilerSet #17321 " " Expects output file extension, say `:make html` or `:make pdf`. " Passes additional arguments to pandoc, say `:make html --self-contained`. @@ -51,7 +52,7 @@ endfunction execute 'CompilerSet makeprg=pandoc'..escape( \ ' --standalone'.. - \ (s:PandocFiletype(&filetype) ==# 'markdown' && (getline(1) =~# '^%\s\+\S\+' || (search('^title:\s+\S+', 'cnw') > 0)) ? + \ (s:PandocFiletype(&filetype) ==# 'markdown' && (getline(1) =~# '^%\s\+\S\+' || (search('^title:\s\+\S\+', 'cnw') > 0)) ? \ '' : ' --metadata title=%:t:r:S').. \ ' '..s:PandocLang().. \ ' --from='..s:PandocFiletype(&filetype).. -- -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php --- You received this message because you are subscribed to the Google Groups "vim_dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscr...@googlegroups.com. To view this discussion visit https://groups.google.com/d/msgid/vim_dev/E1uFd6q-00CYXQ-NA%40256bit.org.