Litescope Action
June 10, 2026 · View on GitHub
GitHub Action for Litescope — schema diff, migration validation, backup integrity check, and drift detection for SQLite, Turso, and Cloudflare D1.
Commands
| Command | Description | Tier |
|---|---|---|
diff | Schema diff between two sources | Free |
validate | Verify a migration matches a spec | Free |
check | Backup integrity check | Free |
monitor-check | One-shot schema drift detection | Free |
Usage
Schema diff on every PR
- uses: croc100/litescope-action@v1
with:
command: diff
source: before.db
target: after.db
format: markdown
comment-on-pr: "true"
Validate migration in CI
- uses: croc100/litescope-action@v1
with:
command: validate
source: before.db
target: after.db
expect: .litescope/migration.yaml
Exits 1 if the migration doesn't match the spec. Use litescope validate init to generate the spec file.
Backup integrity check
- uses: croc100/litescope-action@v1
with:
command: check
source: backup.db
target: production.db
Schema drift detection
- uses: croc100/litescope-action@v1
with:
command: monitor-check
source: turso://TOKEN@ORG/prod
baseline: .litescope/baseline.json
Exits 1 if drift is detected. Combine with on: schedule for automated drift monitoring.
Inputs
| Input | Description | Default |
|---|---|---|
command | Command to run (diff, validate, check, monitor-check) | diff |
source | Primary database (path, turso://, or d1:// DSN) | — |
target | Secondary database for diff/validate/check | — |
expect | Spec file path for validate | — |
baseline | Snapshot file path for monitor-check | — |
format | Output format: terminal, json, markdown | terminal |
comment-on-pr | Post result as a PR comment | false |
version | Litescope version to use | latest |
license | Pro/Cloud license key | — |
Outputs
| Output | Description |
|---|---|
has-diff | Whether schema differences were found (diff only) |
has-drift | Whether drift was detected (monitor-check only) |
result | Full command output |
Pro features
Set license input with your key for Pro/Cloud features:
- uses: croc100/litescope-action@v1
with:
command: monitor-check
source: turso://TOKEN@ORG/prod
baseline: .litescope/baseline.json
license: ${{ secrets.LITESCOPE_LICENSE }}
Get a license at litescope.dev/pricing.