![]() | md2pdfpandoc wrapper for converting markdown to pdf |
| Mode | Name | Size |
| -rw-r--r-- | README.md | 54L |
| -rw-r--r-- | fix-math.lua | 63L |
| -rwxr-xr-x | md2pdf | 85L |
| -rw-r--r-- | style.tex | 218L |
| -rw-r--r-- | tango-grey-bg.theme | 204L |
This is a markdown to pdf wrapper for pandoc, its main purpose is to generate a similar PDF to the one generated with Obsidian by default.

$ md2pdf
md2pdf [OPTIONS] <input>.md
OPTIONS:
-H, --style <file>.tex
-l, --lua-filter <file>.lua
-o, --output <file>
This is a Pandoc wrapper, so pandoc is the main dependency. For generating the PDF pandoc mainly uses latex packages, so having latex installed is required, in particular if you have Arch Linux the following latex packages are recommended for a general build without errors:
sudo pacman -S texlive-fontsextra texlive-fontsrecommended texlive-langother
texlive-latexextra texlive-binextra texlive-plaingeneric texlive-formatsextra
The included style.tex file uses external fonts, for the base text and
sections titles the font Inter is used (which
is similar to Helvetica) and Fira
math for the math fonts. Of course the
fonts are optional since latex already includes base fonts.
If you want to install this script to your system, copy the executable to
$HOME/.local/bin or to /usr/bin if you want to install it user-wide or
system-wide respectively.
$ cp ./md2pdf $HOME/.local/bin
# cp ./md2pdf /usr/bin