Git Product home page Git Product logo

book_tools's Introduction

Python library used on FBReader® book network (https://books.fbreader.org/) + some command line tools based on the library

Command line tools:
  ./create_opds.py:     OPDS catalog file creator (takes list of books + some metainfo)
  ./encrypt.py:         Marlin ePub encryptor

OPDS creation tool takes list of book urls (+some feed meta information) as input. Sample
catalog description can be found in ./sample/catalog.description. Supported book formats:
  ePub
  mobi (a.k.a. azw3)
  fb2
  fb2.zip

How to create sample OPDS catalog:
  ./create_opds.py ./sample/catalog.description
Catalog files will be created in './opds'. Run
  ./create_opds.py -h
for more information.

book_tools's People

Contributors

geometer avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

book_tools's Issues

Структура каталогов с книгами

Добрый день.

Хотелось бы получать в opds такую же структуру, как и на файловой системе. Как мне кажется - это более логично было бы и более удобно.

Заранее спасибо.

All strings must be XML compatible: Unicode or ASCII, no NULL bytes or control characters

Unexpected error:

$ ./create_opds.py samples/catalog.description 
Warning: feed "icon" attribute is not specified
Warning: feed "author_email" attribute is not specified
Traceback (most recent call last):
  File "./create_opds.py", line 221, in <module>
    create_opds(params.description_file, params.output_dir, working_dir)
  File "./create_opds.py", line 193, in create_opds
    add_entry(root, urls, output_dir, working_dir)
  File "./create_opds.py", line 127, in add_entry
    etree.SubElement(entry, etree.QName(NS_ATOM, 'summary'), type='html').text = book.description
  File "lxml.etree.pyx", line 953, in lxml.etree._Element.text.__set__ (src/lxml/lxml.etree.c:44956)
  File "apihelpers.pxi", line 677, in lxml.etree._setNodeText (src/lxml/lxml.etree.c:20273)
  File "apihelpers.pxi", line 1395, in lxml.etree._utf8 (src/lxml/lxml.etree.c:26485)
ValueError: All strings must be XML compatible: Unicode or ASCII, no NULL bytes or control characters

Content of description file:

[feed]
id = http://dmitriy.lyalyuev.info/books/
title = Personal library
subtitle = My family lybrary
author_name = Dmitriy Lyalyuev
author_uri = http://dmitriy.lyalyuev.info/

[book]
url = http://dmitriy.lyalyuev.info/books/Veyr_Marsianin.348577.fb2.zip

[book]
url = http://dmitriy.lyalyuev.info/books/Frei/Hroniki_Eho/Fray_Hroniki-Eho_8_Tuburskaya-igra.333061.fb2.zip

[book]
url = http://dmitriy.lyalyuev.info/books/Frei/Hroniki_Eho/Fray_Hroniki-Eho_6_Obzhora-hohotun-Istoriya-rasskazannaya-serom-Melifaro.202033.fb2.zip

[book]
url = http://dmitriy.lyalyuev.info/books/Frei/Hroniki_Eho/Fray_Hroniki-Eho_1_Chub-zemli-Tulanskiy-detektiv.173193.fb2.zip

[book]
url = http://dmitriy.lyalyuev.info/books/Frei/Hroniki_Eho/Fray_Hroniki-Eho_3_Neulovimyy-Habba-Hen.173195.fb2.zip

[book]
url = http://dmitriy.lyalyuev.info/books/Frei/Hroniki_Eho/Fray_Hroniki-Eho_7_Dar-Shavanaholy-Istoriya-rasskazannaya-serom-Maksom-iz-Eho.262444.fb2.zip

[book]
url = http://dmitriy.lyalyuev.info/books/Frei/Hroniki_Eho/Fray_Hroniki-Eho_2_Vlastelin-Mormory.173194.fb2.zip

[book]
url = http://dmitriy.lyalyuev.info/books/Frei/Hroniki_Eho/Fray_Hroniki-Eho_5_Gore-gospodina-Gro.173197.fb2.zip

[book]
url = http://dmitriy.lyalyuev.info/books/Frei/Hroniki_Eho/Fray_Hroniki-Eho_4_Vorona-na-mostu.173196.fb2.zip

[book]
url = http://dmitriy.lyalyuev.info/books/Dzhon_Perkins__Ispoved_ekonomicheskogo_ubiycy.fb2.zip

[book]
url = http://dmitriy.lyalyuev.info/books/Berezin_Voyna-2010_1_Voyna-2010-Ukrainskiy-front.177475.fb2.zip

[book]
url = http://dmitriy.lyalyuev.info/books/Stratoplan.Ru_Iron_Man.zip

[book]
url = http://dmitriy.lyalyuev.info/books/Roberts_Shantaram.203255.fb2.zip

[book]
url = http://dmitriy.lyalyuev.info/books/Zhvaneckiy_Yuzhnoe-leto-Chitat-na-Severe-.358710.fb2.zip

[book]
url = http://dmitriy.lyalyuev.info/books/Buntovskiyi_S._Nezavisimaya_Ukraina_Krah.fb2.zip

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.