commit cb3e1e3f383d9c453200e6ad66232d6553c3ddd3
parent 7d6be44dd746e1f3eed62ddba8907b2451f46d60
Author: mjkloeckner <martinjkloeckner@gmail.com>
Date: Sat, 29 Apr 2023 20:22:20 -0300
do not replace ${toc} with \tableofcontents
this action was previously used for rendering table of contents in
vim's MarkdownPreview plugin, now is deprecated in favor of changing the
placeholder of the
[markdown-it-toc-done-right](https://github.com/nagaozen/markdown-it-toc-done-right)
(used by MarkdownPreview to render the table of contents)
```vim
" make MarkdownPreview's tableofcontents pattern same as latex (for use
" with pandoc)
let g:mkdp_preview_options = {
\ 'toc': { 'placeholder': '\\tableofcontents' }
\ }
```
Diffstat:
1 file changed, 0 insertions(+), 3 deletions(-)
diff --git a/md2pdf b/md2pdf
@@ -15,9 +15,6 @@ output="$filename.pdf"
echo "Input file not markdown" && \
usage && exit 2
-# replaces ${toc} (from https://github.com/nagaozen/markdown-it-toc-done-right)
-# with \tableofcontents
-sed 's/${toc}/\\tableofcontents/' "$filename".md |\
pandoc --pdf-engine=xelatex \
-V mainfont:"Helvetica" \
-V colorlinks=true \