This project merges two efforts:
- Exirel's epub.
- timtanbin's original python-epub-builder as well as JohannesBuchner's fork.
The revision histories for all three sources are preservied in git.
In all honesty, both project seem to be a bit of a mess; I'm just trying to put something together that suites my needs. This code needs a lot of work.
You can use pip to install the Epub library:
$ pip install https://github.com/oubiwann/epub/archive/master.zipOr, you could clone the git repo:
$ git clone https://github.com/oubiwann/epub.git
$ cd epub
$ python setup.py installfrom epub.reader import content
mybook = content.open_epub('path/to/my/book.epub')
for item in mybook.opf.manifest.values():
# read the content
data = mybook.read_item(item)from epub.writer import book
(more soon ...)