Home

Awesome

Rebol-Mobi CI Gitter

Rebol/Mobi

MobiPocket/Kindle eBook mobi file codec for the Rebol (version 3.11.0 and newer) programming language.

Usage example

Import the module like:

import %mobi.reb ;; or just `mobi if the module is installed in the standard modules location

Than the simplest way to decode everything the decoder is capable of handling:

data: load %path/to/book.mobi

Instead of trying to decode everything as in the code above, it is possible to use a mobi scheme:

;; open a mobi port:
book: open [scheme: 'mobi path: %path/to/book.mobi]

;; get all metadata:
meta: query book

;; get complete text:
text: read/string book

;; close port when not needed!
close book

Screenshot