update: This software has a new version and a new name. Go see the Self Publish a Book page for more info.
Ok, so a while ago I got all excited about a piece of publishing software that could make my life a little easier. The software was called Jaguar PS. Basically, it is a tool for authors who want to easily convert their works to useful formats, like pdf, epub or kindle. What a great idea – have one source file for any work of fiction I write, then run it through a program that spits out all the formats that I want. I can upload them to the various distributers, or I can sell them /give them away directly.
The author of the software put up a testing release and I played with it a bit. Long story short, it required a couple of extra steps before the files were actually ready to go. Plus, it’s been a while since the author posted anything.
So I set out to make my own.
As it ends up, there are already some tools out there that make file conversion like this easy. The problem is that most of these are either command line, or they only work with one format.
“Hmm,” I said to myself. “What if someone made a program that streamlined the use of these tools, you know, so that anyone could use them?”
This is what I came up with:
Pandoc ePress
Right now, my program takes a specially formatted text file (more on this in a minute) and produces ready-to-go .mobi (kindle) and epub files. You can also include a cover in the file, if you have one.
The actual conversion work is done by two other programs, which you’ll have to install separately, Pandoc & kindlegen (scroll down a bit if you don’t see it when you go there).
This is the first time I’ve ever tried to write something in c#, so it’s not perfect. Also, It’s windows only. Sorry.
Installation
1. Download Pandoc & run the installer. When the installation asks you if it should put Pandoc on your Path, say yes. Or check the box. I can’t remember which just now.
2. Download & install kindlegen. Kindlegen doesn’t have a real installer, so you’ll have to do a little work. Just unzip the kindlegen files somewhere, I suggest c:\Program Files\kindlegen or something similar, and then manually put that directory that holds kindlegen.exe on your Path. If you don’t know how to do this, you’ll have to wait a while until I have time to write a more full tutorial.
3. Download Pandoc ePress & run the installer.
Usage
Here’s the hard part. You have to get your work into a plain text file that is very, very similar to markdown.
Basically, your file will look like this:
% Book Title % Author Name # Chapter Title Chapter text here. You must put two lines for the program to recognize a new paragraph. If there are is just a single line break, like there is in this paragraph, the text will be treated as a single paragraph. Just like this. If you want something in italics, you put underscores around it _like this_. If you want something bold, you put two asterisks around it **like this**. If you have a block quote, you can do that by putting a greater than symbol before your paragraph. > This is an example of a block quote. # Chapter The Second blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah, blah,
Once you have your text file done, you just run the program, select your text and cover files, then hit “go to press” The program just drops your epub and mobi files in the same directory as your master text file.
If you don’t like the formatting of the epub (paragraph spacing and the like), feel free to edit the epub.css file in the Resources directory of your Pandoc ePress installation.
Example
Okay, so here’s a real text file and the results I got from running the program.
Text file: The Man that Corrupted Hadleyburg, by Mark Twain
Cover file: Hadleyburg cover
And here’s what the program produced.
epub: The Man that Corrupted Hadleyburg
.mobi (kindle): The Man that Corrupted Hadleyburg
The Future
If there’s any interest, I’ll be adding features to this as time goes on. My two main targets are a print ready pdf for createspace paperback publishing, and a .doc file that meets smashwords specifications. And if there’s no interest, this’ll be the last you hear of it, and I’ll just build anything else into it for my own use.