Skip to content

pkmetski/riffle

Repository files navigation

Riffle

ko-fi

Riffle lets you browse your library, read EPUB, PDF, and CBZ files, listen to audiobooks, and keep reading and listening progress in sync across devices — all from a clean, privacy-respecting Android app.

Screenshots

Books library home — Children of Dune in In Progress cover grid
Library — cover grid with book details
Children of Dune audiobook detail — listen, series & progress
Book detail — read, listen, series & progress
EPUB reader
Reader — clean, immersive reading
Reader in dark theme
Themes — light, dark, dim & sepia
Formatting controls
Formatting — fonts, sizing & spacing
Table of contents
Navigation — table of contents
In-book search
Search — full-text in-book search
Highlight with color picker and note
Highlights — colors & attached notes
Children of Dune audiobook player
Listening — full audiobook player
Settings screen
Server & sync — multi-server settings
Downloads manager
Offline — downloads & cache manager
Storyteller Readaloud in the reader
Readaloud — synced highlight & narration

Features

Reading

  • EPUB, PDF, and CBZ (Comic Book Archive) readers
  • Table of Contents navigation
  • Chapter navigation rail for jumping between sections
  • In-book text search
  • Chapter map progress indicator
  • Fullscreen immersive reading mode

Reading Display

  • Rich formatting controls (themes, fonts, sizing, spacing, margins, justification)
  • Auto theme that switches between configured day and night themes on a global clock schedule
  • Paginated and continuous scroll modes, with landscape double-page spread
  • Per-book formatting overrides
  • Volume-key page navigation (with optional inverted direction)
  • Keep screen on

Highlights, Notes & Bookmarks

  • Highlight passages in any color while reading
  • Attach notes to highlights for personal commentary
  • Bookmark pages for quick return
  • Search across all highlights, notes, and bookmarks in your library
  • Optional WebDAV keeps highlights, notes, and bookmarks in sync across devices — works out of the box for every server-backed source (Audiobookshelf, Komga, …); each account gets its own namespace on the same share.

Listening

  • Full audiobook player for any Audiobookshelf audiobook, streamed directly from your server — including audiobook-only items with no paired ebook
  • Transport controls: play/pause, skip 15s back / 30s forward, and previous/next chapter
  • Seekable chapter-map scrubber with chapter ticks, plus per-chapter and whole-book remaining time
  • Variable playback speed (0.5×–3.0×) with quick presets, remembered per book
  • Background playback with lock-screen, notification, and Bluetooth media controls
  • Download audiobooks for offline listening, with progress that reconciles when you reconnect
  • Audiobookshelf playlists surfaced as a dedicated tab on the audiobook library — play a playlist end-to-end with auto-advance that resumes each next item from its saved position, and add or remove items from the item detail sheet
  • Storyteller Readaloud in the reader: synced sentence highlight, auto-page-turn, "Play from here," and background playback
  • Listening and reading positions stay in sync for matched books — pick up in the reader exactly where you stopped listening, and vice versa

Sources

  • Audiobookshelf and Storyteller self-hosted servers — full read, listen, and sync
  • Komga self-hosted server — browse, read, and sync comics, manga, and ebooks (EPUB, PDF, CBZ) from any Komga instance with Basic-auth credentials; page-based reading progress syncs bidirectionally across devices
  • Chitanka (chitanka.info + gramofonche.chitanka.info) — anonymous, zero-config access to the Bulgarian public catalogue of EPUB ebooks and MP3 audiobooks; browsable by category, genre, and series
  • Project Gutenberg (via Gutendex) — anonymous, zero-config access to ~70,000 public-domain EPUBs; browsable by language, subject, and author
  • Local files — import EPUB, PDF, and CBZ files from device storage and read them alongside your server libraries, with the same reader, highlights, and progress tracking

Library

  • Multi-source support with per-library visibility and ordering controls
  • Browse by Home, To Read, Series, Collections, and All Books
  • Cover grid with book details
  • Read/unread and "To Read" toggles
  • Full-text library search

Downloads & Offline

  • Download for offline reading, plus automatic caching on open
  • Downloads manager with bulk removal
  • Offline detection and seamless offline reading

Server & Sync

  • Audiobookshelf and Storyteller login with secure token storage and insecure-connection warnings
  • Storyteller Readaloud Library: browse every completed readaloud as a single library
  • Automatic Storyteller↔Audiobookshelf matching with a Settings review queue: high-confidence pairs auto-confirm, fuzzy matches go to Pending Review, and a manual picker pairs anything the matcher can't place
  • Bidirectional progress sync with last-update-wins conflict resolution, unified across the ebook, audiobook, and readaloud of a matched book
  • Periodic auto-sync, offline queueing, and durable reconciliation of progress recorded while offline
  • Reading session time tracking

Requirements

  • Android 7.0 (API 24) or higher
  • One or more of: a running Audiobookshelf, Storyteller, or Komga server, internet access for Chitanka or Project Gutenberg, or EPUB, PDF, or CBZ files on your device

Distribution

Channel Status
Google Play Store Planned
F-Droid Planned
GitHub Releases CI-built signed APK

Architecture

Riffle follows a strict layered architecture designed for future Kotlin Multiplatform (KMP) migration:

app/                  # Android UI — Jetpack Compose + Hilt
core/domain/          # Pure Kotlin — entities, repository interfaces, domain logic
core/network/         # Pure Kotlin — OkHttp-based ABS API client
core/database/        # Android — Room database
core/data/            # Android — repository implementations, Keystore token storage

Development

Prerequisites

  • Android SDK (via Android Studio or sdkmanager)

Bootstrap

make bootstrap   # Install JDK 17, download Gradle wrapper, fetch bundled fonts

Build

make build       # Assemble debug APK
make test        # Run unit tests
make check       # Full CI check: build + lint + tests
make install     # Build and install debug APK on connected device

License

Riffle is licensed under the GNU Affero General Public License v3.0 or later (AGPL-3.0-or-later).

Commits up to and including 44d17c362 were also published under the Apache License 2.0. From the relicense commit onward, the project is AGPL-only. If you forked or copied Riffle before the relicense, your existing copy retains its Apache-2.0 grant; future updates are AGPL-3.0-or-later.

Glossary

See CONTEXT.md for the full domain glossary (Server, Library, Library Item, Cache, Download, Reading Session, Progress Sync, etc.).