Litescope
Features Pricing Docs GitHub ↗

Litescope Docs

SQLite production operations — diff, validate, migrate, monitor, and fleet management from one binary.

Installation

macOS (Homebrew)

brew install croc100/tap/litescope

Linux

Download the latest binary from Releases, extract, and move to your PATH:

curl -fsSL https://github.com/croc100/litescope-dist/releases/latest/download/litescope_Linux_x86_64.tar.gz | tar xz
sudo mv litescope /usr/local/bin/

Windows

Download litescope_*_windows_amd64.zip from Releases, extract the .exe, and add its directory to PATH.

Verify

litescope --version

Activate Pro license

After purchasing, you'll receive a license key by email (lsc_pro_…). Activate it in one of two ways:

Option A — environment variable

export LITESCOPE_LICENSE=lsc_pro_your_key_here

Add this to your shell profile (~/.zshrc, ~/.bashrc) to persist it.

Option B — license file

mkdir -p ~/.litescope
echo "lsc_pro_your_key_here" > ~/.litescope/license

Verify activation

litescope license
Online verification. Litescope verifies your key against the license server on each run. An offline grace period applies — if the server is unreachable, the last known tier is used.

diff free

Compare schema and data between two SQLite databases.

litescope diff <old.db> <new.db> [flags]
FlagDefaultDescription
--formattextOutput format: text, json, markdown, html
--datafalseInclude row-level data diff in addition to schema
--output, -ostdoutWrite output to file

Examples

# Human-readable schema diff
litescope diff prod-before.db prod-after.db

# JSON output for CI
litescope diff old.db new.db --format json

# Include data diff
litescope diff old.db new.db --data

# Save HTML report
litescope diff old.db new.db --format html -o report.html

check free

Validate a backup database against a reference. Runs PRAGMA integrity check, compares schema, and optionally verifies row counts.

litescope check <backup.db> <reference.db> [flags]
FlagDefaultDescription
--datafalseAlso compare row counts per table
--formattextOutput format: text, json

Examples

# Basic integrity + schema check
litescope check backup.db prod.db

# Include row count comparison
litescope check backup.db prod.db --data

# Use in CI (exits 1 on failure)
litescope check backup.db prod.db && echo "backup OK"

migrate free

Generate a migration SQL from a diff, then apply it safely with an automatic backup and rollback on failure.

generate

litescope migrate generate <old.db> <new.db> [flags]
FlagDefaultDescription
--output, -ostdoutWrite SQL to file

apply

litescope migrate apply <db> <migration.sql> [flags]
FlagDefaultDescription
--dry-runfalsePreview what would run without writing to disk
--backup-dirsame dir as dbWhere to store the automatic pre-migration backup

Examples

# Generate SQL
litescope migrate generate old.db new.db -o migration.sql

# Preview before applying
litescope migrate apply prod.db migration.sql --dry-run

# Apply (creates backup automatically)
litescope migrate apply prod.db migration.sql
Safety. apply always creates a timestamped backup before writing. If any statement fails, the entire migration is rolled back.

monitor pro

Baseline a known-good schema, then check for drift. The watch subcommand runs continuously and can alert on changes.

snapshot

litescope monitor snapshot <db> [flags]
FlagDefaultDescription
--output, -obaseline.jsonPath to write the baseline snapshot

check

litescope monitor check <db> [flags]
FlagDefaultDescription
--baseline, -bbaseline.jsonPath to the baseline snapshot
--formattextOutput format: text, json

watch

litescope monitor watch <db> [flags]
FlagDefaultDescription
--baseline, -bbaseline.jsonPath to the baseline snapshot
--interval30sPoll interval (e.g. 10s, 1m, 5m)
--webhookSlack or Discord webhook URL for drift alerts

Examples

# Baseline
litescope monitor snapshot prod.db -o baseline.json

# One-off check
litescope monitor check prod.db -b baseline.json

# Continuous watch with Slack alert
litescope monitor watch prod.db -b baseline.json \
  --interval 1m \
  --webhook $SLACK_WEBHOOK_URL

fleet pro

Discover and operate an entire Turso org or Cloudflare D1 account in parallel — baseline, drift-check, and migrate every database at once.

check

litescope fleet check [flags]
FlagDefaultDescription
--providerturso or d1
--orgTurso org slug or Cloudflare account ID
--tokenPlatform API token (Turso management token or CF API token)
--db-tokenTurso database token (for connecting to each DB)
--concurrency8Max parallel workers
--formattextOutput format: text, json

snapshot

litescope fleet snapshot [flags]

Same flags as check. Takes a baseline snapshot of every database in the fleet.

Examples

# Baseline entire Turso org
litescope fleet snapshot \
  --provider turso \
  --org my-org \
  --token $TURSO_TOKEN \
  --db-token $TURSO_DB_TOKEN

# Drift check all at once
litescope fleet check \
  --provider turso \
  --org my-org \
  --token $TURSO_TOKEN \
  --db-token $TURSO_DB_TOKEN

# Cloudflare D1
litescope fleet check \
  --provider d1 \
  --org $CF_ACCOUNT_ID \
  --token $CF_API_TOKEN
Baselines are stored at ~/.litescope/fleet/baselines/ keyed by database name.

Desktop GUI

The GUI app bundles all CLI operations in a visual interface. It ships as part of the same binary download — run litescope gui to launch, or double-click the .app on macOS.

Named connections

Add databases by clicking + Add in the sidebar. Free tier supports up to 3 named connections; Pro is unlimited.

Tools

  • Diff — visual schema and data diff between two databases
  • Explorer — browse tables and query rows
  • Check — validate a backup against a reference
  • Migrate — generate and apply migrations with dry-run preview
  • Monitor (Pro) — snapshot, check drift, run continuous watch
  • Fleet (Pro) — discover and check Turso / D1 databases

Activating Pro in the GUI

Open Settings → License and paste your lsc_pro_… key, or set the LITESCOPE_LICENSE environment variable before launching.

Changelog

v0.2.0 2026-06-16

  • GUI: Monitor Watch — continuous drift detection with live event feed
  • GUI: Fleet panel — Turso and D1 discover, snapshot, parallel check
  • GUI: Free/Pro tier — 3-connection limit, Pro gate on Monitor and Fleet
  • Lemon Squeezy payment integration — $89/year Pro subscription
  • Online license verification via Cloudflare Worker
  • Binary releases via litescope-dist + Homebrew tap

v0.1.0 2026-05-01

  • Initial release: diff, check, migrate, monitor, fleet CLI
  • GUI desktop app (Wails/Go + React)
  • Named connections sidebar