Skip to content
d4mysusPublic

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

2 Commits

Folders and files

Repository files navigation

mdtomail

Convert Markdown files to rich HTML and copy to clipboard — ready to paste into Outlook or Gmail.

Why

Email clients expect rich text, not raw Markdown. mdtomail converts your .md files and writes the result to the Windows clipboard in CF_HTML format, so Ctrl+V in any email composer pastes rendered HTML with proper headings, bold, tables, and code blocks.

Requirements

  • Windows 10/11
  • Python 3.9+

Install

git clone https://github.com/YOUR_USERNAME/mdtomail.git
cd mdtomail
python -m venv .venv
.venv\Scripts\activate
pip install -r requirements.txt

Optional — call from anywhere: Add the mdtomail folder to your Windows PATH
(System Properties → Environment Variables → Path → Edit → New).

Usage

mdtomail.bat notes.md
mdtomail.bat doc1.md doc2.md
mdtomail.bat report.md --no-style
Argument Description
FILE.md [FILE.md ...] One or more Markdown files to convert
--no-style Skip inline CSS — outputs raw converted HTML

Multiple files are joined with a horizontal rule (<hr>) in the output.

How it works

  1. Converts Markdown to HTML using Python-Markdown (extra, nl2br, sane_lists extensions)
  2. Injects inline style="" attributes on all tags — required because Outlook strips <style> blocks
  3. Writes the result to the Windows clipboard using the CF_HTML clipboard format via pywin32

Dependencies

Package Purpose
markdown Markdown → HTML conversion
pywin32 Windows clipboard API (CF_HTML format)

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages