md-typ-pdf

Crates.iomd-typ-pdf
lib.rsmd-typ-pdf
version0.1.1
created_at2025-11-07 18:59:12.570689+00
updated_at2025-11-20 18:52:41.609559+00
descriptionConvert markdown files to PDF using typst
homepage
repositoryhttps://github.com/Magi3r/md-typ-pdf
max_upload_size
id1922006
size17,521
(Magi3r)

documentation

README

Markdown to PDF Converter

A simple command-line tool written in Rust that converts Markdown (.md) files into clean PDF documents using using typst and the cmarker package.

Features

  • Converts Markdown files (.md) into PDFs (.pdf)
  • Uses typst for lightweight conversion
  • Automatically determines the output filename if not specified
  • Math rendering with mitex

Requirements

Before running, make sure you have Typst CLI installed and available in your $PATH. You can check if Typst is installed with:

typst --version

Usage

Very basic usage:

md-typ-pdf input.md

This generates input.pdf.

You can also specify the output file name:

md-typ-pdf input.md output.pdf

Why?

I was annoyed by the looks of pandocs markdown to pdf conversion (especially the insanely large default margins) and the need to install Gigabytes of latex... Also I was annoyed to open another program like VSCode (for this great extension) or Obsidian (that generate html out of them first and use chromium webrendering for the PDF), just to generate pleasing PDF files for submissions of assignements for my lectures. So I created this: A very lightweight tool (including dependencies!) to do the simple task of converting my markdown files to PDF files that look fine for submission of exercises.

Commit count: 0

cargo fmt