babluboy / bookworm

A simple ebook reader for Elementary OS
GNU General Public License v3.0
1.32k stars 100 forks source link

UX: Clarify/document library workflow #258

Closed varac closed 5 years ago

varac commented 5 years ago

First of all thanks for bookworm! I'd like to migrate from calibre, but I'm super confused by the current workflow of library organising / adding books:

This is using bookworm 1.1.1-0~201810212138~ubuntu18.10.1 on ubuntu 19.04 (also: please add a disco/19.04 repo, thx!).

varac commented 5 years ago

Also:

babluboy commented 5 years ago

First of all thanks for bookworm! I'd like to migrate from calibre, but I'm super confused by the current workflow of library organising / adding books:

  • I added a dedicated, emty folder to scan for ebooks in the preferences
  • When I copy/move an ebbok there it won't get noticed/added by a running instance of bookworm
  • Discovery only works by restarting the app
  • Copying a .mobi file to the directory won't even be discovered by bookworm --discover, nor by restarting the app.

This is using bookworm 1.1.1-0~201810212138~ubuntu18.10.1 on ubuntu 19.04 (also: please add a disco/19.04 repo, thx!).

Thanks for using bookworm - still a lot of work to improve this app (as and when i find time!) As you might have found out, the discovery (import of books from a watched folder) only kicks in when bookworm is closed. Not very intuitive, but wanted to avoid an additional file watcher or scheduled process to trigger the import.

The process to run is com.github.babluboy.bookworm --discover. If this process is running already then another process will not be started. Maybe the process was running when you added the .mobi file and ran com.github.babluboy.bookworm --discover

Will add the disco/19.04 to launchpad and add it to the PPA

babluboy commented 5 years ago

Hopefully I have provided the answers you were looking for in-line below:

Also:

  • What exactly happens when adding a book - I noticed that for some books pdftohtml is running in the background, what for ? ----->pdftohtml is used to convert pdf books to html files. html is the base to which all formats are converted before bookworm displays the content.
  • Adding an existing library of ebooks and closing the app will start a long ass discovery - what takes so long, and is it safe to shutdown the laptop, and (when) will bookworm continue with the discovery ? ----->the discovery process takes the closure of bookworm to start a process which checks if any new books are in the "watched" directories and then converts them to html format and adds the meta data to bookworm database to show up in the library. if the laptop is shut when the discovery process is on-going, the next time when bookworm is opened and closed the remaining books will again be added by the discovery process which triggers off on the closure of the app
  • Where is (what) metadata stored, what happens when a book is move to a different directory when re-organising the library ? -----> The meta data of the book like title, author, last read page, etc is stored in a sqlite database located in ~/.local/share/com.github.babluboy.bookworm/ . This directory also stores the cached content of books and thumbnails.

If caching is not set then the covers and content are temporarily stored in /tmp and if the content is destroyed on close of the OS then bookworm attempts to find the ebook file in the original location when it was first added to the library.

So as you can make out, that if cache is set to true then it dosen't mater if the ebook file is moved to a different directory or delete as bookworm operates from the cached content. If caching is not enabled, and the original ebook file is moved then bookworm will not be able to load the book automatically if the content from /tmp is gone as well.

  • What happens when using "Open/selecting a book" from the main screen - is the book also added to the library ? -----> yes, whether you add a book via the + button on the library or via the import process from a watched folder, the contents are cached in the same place and the book is added to the library. When you remove a book from the library only the cached content is removed but not the original ebook file.
  • What's the (currently empty) ~/.config/books/ folder for ? -----> The is where I was storing the cache content of books earlier, now it is no longer used. Maybe it was created as part of an earlier bookworm version.
babluboy commented 5 years ago

The Bookworm PPA for Disco and Eoan is now built on Launchpad and can be used for installation.

The disco deb file is here on launchpad for the daily build: https://code.launchpad.net/~bablu-boy/+archive/ubuntu/bookworm-daily/+build/16678341

When I publish the next version, the stable build for Disco and Eoan will also be available.

varac commented 5 years ago

Thx for the answers!

pdftohtml is used to convert pdf books to html files

Where are these files stored ?

The meta data of the book like title, author, last read page, etc is stored in a sqlite database located in ~/.local/share/com.github.babluboy.bookworm/

This dir doesn't exist for me. I guess you mean ~/.config/bookworm/bookworm.db ?

In general it would be good to document this not here in a hidden github issue but rather in the bookworm documentation so other users can profit as well.

babluboy commented 5 years ago

Thx for the answers!

pdftohtml is used to convert pdf books to html files

Where are these files stored ?

The meta data of the book like title, author, last read page, etc is stored in a sqlite database located in ~/.local/share/com.github.babluboy.bookworm/

This dir doesn't exist for me. I guess you mean ~/.config/bookworm/bookworm.db ?

In general it would be good to document this not here in a hidden github issue but rather in the bookworm documentation so other users can profit as well.

I use the user_data_folder.get_path() method in Granite.Services.Paths here to set the location of the user data directory. The documentation says it defaults to defaults to xdg_data_home_folder/app_name

babluboy commented 5 years ago

Agree, I can document this on the Bookworm web site: https://babluboy.github.io/bookworm/ but normal users are not that concerned about how bookworm will cache the book data