Skip to main content

Interactive Bible Reading

Project description

bibleit

Interactive Bible reading for the terminal, plus a lightweight live web viewer, built with Python, Textual, and libbibleit.

Features

  • Terminal Bible reader with keyboard-first navigation.
  • Multiple translations open side by side or stacked vertically.
  • Synchronized cursor across open translation panes.
  • Go-to navigation with g, supporting verse, chapter/verse, and fuzzy book names.
  • Text Find with Ctrl+F, result browsing, and visual translation toggles.
  • Strong's references with linked entries via Ctrl+G.
  • Live web viewer for sharing the active verse with viewers.
  • Live viewer controls for light/dark theme, font size, presentation mode, and translation selection.
  • Persistent local config for live URL/token and theme.
  • Docker and Fly.io deployment support.

Requirements

  • Python 3.11+
  • GNU Make

Installation

Clone the repository:

git clone https://github.com/mittel-labs/bibleit.git
cd bibleit/python

Install development dependencies:

make install

Install the package locally:

make local-install-test

Usage

Run the terminal application:

make run

Run the live web viewer:

make live

Then open:

http://localhost:8000

Run the installed package directly:

python -m bibleit

Read a verse from the command line:

bibleit -t NVIPT dani 9.2
python -m bibleit -t KJV "john 3:16"
python -m bibleit -t NVIPT,KJV dani 9:2-15
bibleit -t KJV --strongs genesis 1.1

With no arguments, bibleit and python -m bibleit open the terminal app. With a reference, they print matching verse text to stdout. Set a default translation with BIBLEIT_DEFAULT_TRANSLATION, BIBLEIT_TRANSLATION, or DEFAULT_TRANSLATION in ~/.bibleit/config.

Keyboard

Shortcut Action
/ Previous / next verse
g Go to verse, chapter, or book reference
Tab / Shift+Tab Next / previous open translation
Tab in Go To Cycle go-to matches
Ctrl+F Find verse text
/ in Find Switch Find translation
Ctrl+T Open translations
Ctrl+G Toggle Strong's
Ctrl+A / Ctrl+E Beginning / end of current chapter
< / > Previous / next chapter
Ctrl+W Close the active translation pane
Ctrl+M Maximize / restore the active translation pane
Ctrl+Tab Rotate translations
Ctrl+1-Ctrl+9 Select a translation while maximized
Esc Restore panes when a translation is maximized
F2 Toggle split layout
Ctrl+L Toggle live mode
Ctrl+D Toggle theme
Ctrl+P Open config
? Show shortcuts

At startup bibleit shows a small welcome screen with the most useful shortcuts. Press Enter, Esc, q, or ? to dismiss it.

Configuration

bibleit reads configuration from ~/.bibleit/config as TOML. Environment variables with the BIBLEIT_ prefix take precedence.

Config Environment variable Description
LIVE_URL BIBLEIT_LIVE_URL Live server URL used by the terminal app
LIVE_TOKEN BIBLEIT_LIVE_TOKEN Optional token used to protect live control requests
DEFAULT_TRANSLATION BIBLEIT_DEFAULT_TRANSLATION Default translation slug for CLI verse lookup
THEME BIBLEIT_THEME light or dark

Open the config screen with Ctrl+P.

Example:

LIVE_URL = "https://bibleit.example.com"
THEME = "dark"

Empty values are not written to the config file.

Live Mode

Start the live web server:

make live

Run the terminal app and point it at the live server:

BIBLEIT_LIVE_URL=http://localhost:8000 make run

Press Ctrl+L in the terminal app to publish the active verse to the web viewer. When live mode is off, the browser shows a waiting splash screen.

Development

Run with Textual development tools:

make run-dev

Open a Python shell inside the virtual environment:

make shell

Run tests:

make test

Run lint:

make lint

Format code:

make lint-fix

Build distribution packages:

make build

Install local wheel:

make install-local

Run the local installation test:

make local-install-test

Live server configuration

The live server supports the following environment variables:

Variable Default Description
BIBLEIT_LIVE_HOST 0.0.0.0 Bind address
BIBLEIT_LIVE_PORT 8000 Server port
BIBLEIT_LIVE_URL unset Public live server URL used by the terminal app
BIBLEIT_LIVE_TOKEN unset Optional token used to protect live control requests
BIBLEIT_LIVE_TITLE bibleit live Browser page title
BIBLEIT_FIND_INDEX_CACHE_SIZE 4 Max number of translation text indexes cached by Find

Example:

export BIBLEIT_LIVE_HOST=0.0.0.0
export BIBLEIT_LIVE_PORT=8000
export BIBLEIT_LIVE_URL=http://localhost:8000

make live

Docker

Build the image:

docker build -t bibleit .

Run terminal mode:

docker run -it bibleit

Run live web mode:

docker run -p 8000:8000 bibleit live

Then open:

http://localhost:8000

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bibleit-0.5.0.tar.gz (71.9 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

bibleit-0.5.0-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (81.8 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

bibleit-0.5.0-cp311-cp311-macosx_11_0_arm64.whl (69.2 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

File details

Details for the file bibleit-0.5.0.tar.gz.

File metadata

  • Download URL: bibleit-0.5.0.tar.gz
  • Upload date:
  • Size: 71.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for bibleit-0.5.0.tar.gz
Algorithm Hash digest
SHA256 f7c4bf053df5d82cc05f15adce3a774b8f7c1c914684a07ed2c12939532d3968
MD5 3748cecc69547bc746d34ba7ea8ee0ea
BLAKE2b-256 d5c3d3c24cbe7fecff5ef9460dbd8352ea707bdf1409f1040028cd4854daca40

See more details on using hashes here.

File details

Details for the file bibleit-0.5.0-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for bibleit-0.5.0-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 0689c11d4d3b09eae003112d2a7843a39bd39503ab9c440d0e0dc025b1847e8a
MD5 d937e83101e3d7480a31c895089ac7f5
BLAKE2b-256 6b63d54e49ea2033b293276545b563b7cd6e01eb95d13ac18047d75b2b110892

See more details on using hashes here.

File details

Details for the file bibleit-0.5.0-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for bibleit-0.5.0-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 c237289b29c5fd67bc478df70fd23c2343c2a3718baf709087e3a4f0ef2f6dd6
MD5 de2e31998eab8cac39697892d4c3000e
BLAKE2b-256 2dac3e2d842b4821e327c4613fd171255b3703cd4993bf8172227c79a2f451c5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page