Converting epubs to Plain-Text?

Linux for blind general discussion blinux-list at redhat.com
Thu Nov 25 15:30:20 UTC 2021


Tim here.  If you have the "pandoc" package installed, you should be
able use it to convert epub to various formats such as plain-text,
markdown, or HTML.  To do a bunch of them in a loop, you can do
something like

  $ for f in *.epub ; do pandoc -f epub -t plain -o "${f%.epub}.txt"
  "$f" ; done

This will convert from EPUB to plain-text.  If you prefer HTML, you
can use

  $ for f in *.epub ; do pandoc -f epub -t html -o "${f%.epub}.html"
  "$f" ; done

or for Markdown (like plain-text with a bit of annotation):

  $ for f in *.epub ; do pandoc -f epub -t markdown_strict -o
  "${f%.epub}.md" "$f" ; done

Hope this helps,

-tim


On November 25, 2021, Linux for blind general discussion wrote:
> We interrupt these Fedora discussions to bring you a separate
> subject. I have several, maybe 18 ebooks in an epub format, from
> BookShare-and-Usenet. In looking around, an only tool I can find is
> "ebook-convert" part of a Calibre package to convert these.
> However, following cryptic instructions in its man-page, as well as
> what I see in duckduckgo, I am getting no where. Are their other
> better tools I need to grab in a Debian SID console? In addition, I
> really would like to convert all of these at once, in a batch.
> Thanks so much in advance for any-and-all guidance. We now resume
> our regularly scheduled programming Chime
> 
> _______________________________________________
> Blinux-list mailing list
> Blinux-list at redhat.com
> https://listman.redhat.com/mailman/listinfo/blinux-list
> 




More information about the Blinux-list mailing list