(let [book-file (first *command-line-args*)
title (first (split book-file #"\."))
txtz-file (str title ".txtz")
(let [book-file (first *command-line-args*)
title (first (split book-file #"\."))
txtz-file (str title ".txtz")
mp3-file (str title ".mp3")]
(println "Converting to text...")
(run-cmd ["ebook-convert" book-file txtz-file])
mp3-file (str title ".mp3")]
(println "Converting to text...")
(run-cmd ["ebook-convert" book-file txtz-file])
(println "Converting text to audio. Don't hold your breath!")
(run-cmd ["say" "-f" txt-file "-o" aiff-file])
(println "Creating mp3 file...")
(run-cmd ["ffmpeg" "-i" aiff-file mp3-file])
(println "Cleaning up...")
(println "Converting text to audio. Don't hold your breath!")
(run-cmd ["say" "-f" txt-file "-o" aiff-file])
(println "Creating mp3 file...")
(run-cmd ["ffmpeg" "-i" aiff-file mp3-file])
(println "Cleaning up...")