[A picture of private offices at Fog Creek Software] Alert! This ancient trifle retrieved from the Joel on Software archive is well-past its expiration date. Proceed with care.
Wanted: Senior Engineer at Dimagi (Charlestown, MA 02129). See this and other great job listings on the jobs page.

Joel on Software

Getting MarkDown and SmartyPants working with EditPad Pro

by Joel Spolsky
Tuesday, September 19, 2006

MarkDown is a simple processor that converts text to HTML. For example, it converts *text surrounded by asterisks* to italics.

SmartyPants replaces "straight quotes" with “curly quotes” and makes a few other typographic improvements.

EditPad Pro is a very respectable text editor for Windows. It’s fast and contains scrillions of useful features. It’s not the fanciest thing in the world, but if you’re still using Notepad for the occasional bits of text, it’s a fine drop-in replacement.

Here’s what it takes to get them all working together on a typical Windows setup:

  • Install Perl, if you don’t already have it. For Windows, the easiest way to do this is from ActiveState’s download page. Just download the Windows MSI package and run it. Make sure to choose the option to associate .pl files with Perl.
  • Go into c:\Perl and make a directory called markdown.
  • Download Markdown and SmartyPants. Open the ZIP files and put Markdown.pl and SmartyPants.pl in the directory you just made, c:\perl\Markdown.
  • Also in that directory, make a little batch file named md.bat:


@echo off
c:\perl\markdown\Markdown.pl %1 > "%~dpn1.tmp"
c:\perl\markdown\SmartyPants.pl "%~dpn1.tmp" > "%~dpn1.html"
del "%~dpn1.tmp" 
start "" "%~dpn1.html"


  • In EditPad Pro, choose Tools | Configure Tools. Click New. Set the Caption to “MarkDown”, and set the Command Line to c:\perl\markdown\md.bat "%FILE%". You may want to check the box in the Files tab that says “Save the current file if it has unsaved changes.”
  • Now you have a menu item Tools|Markdown which will save the file you’re working on and generate an HTML version of it (replacing the extension you used with .html), then it pops it up in a web browser so you can check it.

College students: my company has paid summer internships in New York City, including free housing, free lunch, and the chance to develop software people will really use, with great mentors on interesting projects. Don't miss this chance of a lifetime. We only have a few spaces and they always go fast, so apply today.

Want to know more?

You’re reading Joel on Software, stuffed with years and years of completely raving mad articles about software development, managing software teams, designing user interfaces, running successful software companies, and rubber duckies.



About the author.

I’m Joel Spolsky, founder of Fog Creek Software, a New York company that proves that you can treat programmers well and still be highly profitable. Programmers get private offices, free lunch, and work 40 hours a week. Customers only pay for software if they’re delighted. We make FogBugz, an enlightened project management system designed to help great teams develop brilliant software, and Fog Creek Copilot, which makes remote desktop access easy.

© 2000-2009 Joel Spolsky