How to Make an eBook, Part 2: Converting your Files

Wel­come to part two of our self-pub­lish­ing series, How to Make an eBook. If you need to catch up, take a look at part one, which will teach you how to cre­ate an eBook-con­ver­sion-friend­ly manuscript:

In this tuto­r­i­al, we’re going to cov­er how to con­vert your com­plet­ed Mark­down man­u­script into eBook for­mats using a free eBook appli­ca­tion called Calibre.

Ready to get start­ed? Read On!

Self-Publishing 101: How to Make an eBook

For­mat­ting and pub­lish­ing your own eBook can be an intim­i­dat­ing expe­ri­ence for a novice self-pub­lish­er. That’s why ser­vices like Smash­words are so pop­u­lar: they can take a stan­dard Word doc­u­ment, con­vert it into all pop­u­lar eBook for­mats, and pub­lish them to a bunch of venues for you. They take the has­sle out of inde­pen­dent publishing.

But, for those of us who want bit more con­trol over their pub­lish­ing expe­ri­ence, for­mat­ting and cre­at­ing eBooks by hand can be a reward­ing expe­ri­ence. Why would you want to do this by hand, when there are ser­vices out there that can do it for you?

  • Microsoft Word is a pain. Basi­cal­ly, it is overkill for the eBook writ­ing process. Most Word fea­tures are either not need­ed in an eBook (e.g., mar­gins, padding, page num­ber­ing), or won’t trans­late dur­ing the eBook con­ver­sion (e.g., font selec­tions and foot­notes). And, your Word doc­u­ment has to be metic­u­lous­ly for­mat­ted for it to con­vert clean­ly. (If you’ve glanced over the Smash­words style guide, you know what I’m talk­ing about.) Most peo­ple default to Word because it’s what they’re used to using, but I find that oth­er options are much sim­pler, ele­gant, and con­ducive to the writ­ing process.
  • For­mat­ting by hand gives you greater con­trol over the look of your final eBook. I’m a typog­ra­phy snob, and I love the con­trol that for­mat­ting eBooks by hand gives me. I can embed fonts, change the way that para­graphs and head­ings are for­mat­ted, even include drop caps into my open­ing para­graphs. While there is a bit of a learn­ing curve involved in tweak­ing eBook out­put, I find the result to be well worth the effort.

In this three-part series I’m going to go over writ­ing and for­mat­ting your eBook file, con­vert­ing it to pop­u­lar eBook for­mats like ePub and MOBI, and tweak­ing the out­put with a bit of styling. You’re result­ing eBook files will be ready to upload to pop­u­lar out­lets like Ama­zon and Barnes & Noble for sale and distribution.

Ready to dive in with me?

Read More!

A Bash script to batch extract audio from YouTube videos

I’m work­ing on a pod­cast­ing project that requires me to extract the audio from mul­ti­ple YouTube videos. So, I put togeth­er a lit­tle script that allows me to batch extract the audio from a com­ma-sep­a­rat­ed list of YouTube urls.

In case some­one else might find this func­tion­al­i­ty use­ful, I’ve put togeth­er the instruc­tions for cre­at­ing and exe­cut­ing the script here. It requires that you’re a bit com­fort­able with the com­mand-line, and assumes you’re on a UNIX-based sys­tem (such as Lin­ux or OS X).

The script requires a com­mand-line pro­gram called youtube-dl. You can down­load it here. (And make sure to fol­low the instal­la­tion instruc­tions in order to make it executable.)

Once that is down­loaded, cre­ate a text file and name it

for i in $(echo $1 | sed “s/,/ /g”)doyoutube-dl — extract-audio — audio-format=mp3 -t $idone

Once you’ve cre­at­ed the script, make it exe­cutable with the following:

sudo chmod a+rx

Then, you can move it to /usr/local/bin so that it’s exe­cutable from anywhere:

mv /usr/local/bin

Now you can exe­cute run the script by pass­ing to it a com­ma-sep­a­rat­ed list (no spaces), eg.:,,

It will cycle through each video, extract the audio, and con­vert it to an mp3 for you.

It’s a sim­ple script, but I’m new to Bash-script­ing, so I was quite impressed with myself. I hope some­one can find it useful!