Skip to main content

local-preview

Test status Deploy Status Docs Go Reference PyPI

A local-first preview-deployment orchestrator: every commit of a registered git repository becomes a servable preview at its own subdomain (<sha>.<repo>.preview.localhost:8080), built once, deduplicated by content, and served from a single binary.

local-preview resolves each commit into a (frontend artifact, backend artifact) pair by content-addressing the relevant subtrees. Commits that don't touch the frontend (or backend) reuse the existing artifact — and the already-running backend process. Backend state follows git lineage: a new backend version forks its data from the nearest deployed ancestor, so previews feel continuous on a straight line of commits while divergent branches can never corrupt each other.

Install

uv tool install local-preview

This installs the binary to ~/.local/bin/preview. Make sure to have that on your PATH.

Run

preview serve

The server listens on :8080. Open http://localhost:8080/ for the dashboard.

Or with Docker:

docker compose up -d --build

Develop

# Backend on :8080 (wgo restarts on save; plain `go run` works too)
wgo run . serve

# Frontend on :5173, proxying /api to the backend
cd web && npm install && npm run dev

Docs site

The docs/ VitePress site deploys to GitHub Pages automatically: pushes to master that touch docs/** run .github/workflows/docs.yml, which builds the site and publishes it through the Pages Actions deploy (no gh-pages branch). Run it locally with:

cd docs && npm install && npm run docs:dev   # http://localhost:5175

See CLAUDE.md for the full development reference (tests, lint, E2E, docs conventions).

📖 Documentation

Full documentation lives at https://jmelahman.github.io/local-preview/:

  • Quickstart — register a repo, deploy a commit, open the preview.
  • Configuration — flags and env vars.
  • REST API — endpoints exposed by the running server.
  • CLIserve, repo, deploy, install-hook.

Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

local_preview-0.1.0-py3-none-manylinux_2_17_x86_64.whl (5.5 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ x86-64

local_preview-0.1.0-py3-none-manylinux_2_17_aarch64.whl (5.1 MB view details)

Uploaded Python 3manylinux: glibc 2.17+ ARM64

local_preview-0.1.0-py3-none-macosx_11_0_arm64.whl (5.3 MB view details)

Uploaded Python 3macOS 11.0+ ARM64

local_preview-0.1.0-py3-none-macosx_10_12_x86_64.whl (5.5 MB view details)

Uploaded Python 3macOS 10.12+ x86-64

local_preview-0.1.0-py3-none-any.whl (5.5 MB view details)

Uploaded Python 3

File details

Details for the file local_preview-0.1.0-py3-none-manylinux_2_17_x86_64.whl.

File metadata

  • Download URL: local_preview-0.1.0-py3-none-manylinux_2_17_x86_64.whl
  • Upload date:
  • Size: 5.5 MB
  • Tags: Python 3, manylinux: glibc 2.17+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.2 {"installer":{"name":"uv","version":"0.12.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for local_preview-0.1.0-py3-none-manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 84f173dc927d3885328d1255ec7e5eab2941712451ce091673c839504ce9b41f
MD5 d4840cfe2182401cf6faa8dd4b07e1cc
BLAKE2b-256 2a93e4a3684bdc2a3f9b33c5b443311986814c8cc6ed19b5b5af660fb91731ab

See more details on using hashes here.

File details

Details for the file local_preview-0.1.0-py3-none-manylinux_2_17_aarch64.whl.

File metadata

  • Download URL: local_preview-0.1.0-py3-none-manylinux_2_17_aarch64.whl
  • Upload date:
  • Size: 5.1 MB
  • Tags: Python 3, manylinux: glibc 2.17+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.2 {"installer":{"name":"uv","version":"0.12.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for local_preview-0.1.0-py3-none-manylinux_2_17_aarch64.whl
Algorithm Hash digest
SHA256 b6401e491e65a685c9600407e50a6072d8d9071e59d719cadafcd8488055e463
MD5 4e672c243c59f56a4f74b8be94f10cf9
BLAKE2b-256 315e36b5a2fdc843799d538ed4f2f6aa755f6dd3e605bd36712bbd989b32c973

See more details on using hashes here.

File details

Details for the file local_preview-0.1.0-py3-none-macosx_11_0_arm64.whl.

File metadata

  • Download URL: local_preview-0.1.0-py3-none-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 5.3 MB
  • Tags: Python 3, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.2 {"installer":{"name":"uv","version":"0.12.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for local_preview-0.1.0-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 f1531f7c9ba66ed5ea4698b268aba6b168507ca98a9e9e4110426c090cc648fa
MD5 75576e0f96a4030ac59caa7f9b3efb8c
BLAKE2b-256 73e26f1093c6a2a4bb4b13d195d096c6254381da52e7b5b55c93b96bc158c29b

See more details on using hashes here.

File details

Details for the file local_preview-0.1.0-py3-none-macosx_10_12_x86_64.whl.

File metadata

  • Download URL: local_preview-0.1.0-py3-none-macosx_10_12_x86_64.whl
  • Upload date:
  • Size: 5.5 MB
  • Tags: Python 3, macOS 10.12+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.2 {"installer":{"name":"uv","version":"0.12.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for local_preview-0.1.0-py3-none-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 d8c60731d066c34cc434bc693aa7623a5828155609f78dcb38027fd495ae08fe
MD5 3b59f064fe61cd3fb348d2d96439afdc
BLAKE2b-256 fb921c37821aded541c473ac71124265dc8d04c0b1f3582f89d623e1a58a6982

See more details on using hashes here.

File details

Details for the file local_preview-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: local_preview-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 5.5 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.2 {"installer":{"name":"uv","version":"0.12.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for local_preview-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 30dc672b96680dbb992cbc1e9dae826c5831362e203fa894262dfd4e3c20be55
MD5 bfd6d6d4bd3ff9477c1da23b35c3f0cb
BLAKE2b-256 3d9d995fe4cebd0af25946ba78d29fb6e12bf547d78d6fd49bc73eb52151b44c

See more details on using hashes here.

Release history Release notifications | RSS feed

0.23.0

5 files

0.22.0

5 files

0.21.0

5 files

0.20.0

5 files

0.19.0

5 files

0.18.2

5 files

0.18.1

5 files

0.18.0

5 files

0.17.1

5 files

0.17.0

5 files

0.16.0

5 files

0.15.0

5 files

0.14.3

5 files

0.14.2

5 files

0.14.1

5 files

0.14.0

5 files

0.13.2

5 files

0.13.1

5 files

0.13.0

5 files

0.12.0

5 files

0.11.1

5 files

0.11.0

5 files

0.10.2

5 files

0.10.1

5 files

0.10.0

5 files

0.9.0

5 files

0.8.2

5 files

0.8.1

5 files

0.8.0

5 files

0.7.0

5 files

0.6.0

5 files

0.5.0

5 files

0.4.0

5 files

0.3.0

5 files

0.2.2

5 files

0.2.0

5 files

0.1.8

5 files

0.1.7

5 files

0.1.4

5 files

0.1.3

5 files

0.1.2

5 files

0.1.1

5 files

This release

0.1.0 This release

5 files

Supported by

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