devlanes is in beta and not ready for production use.Report an issue

Run every worktree at once, each on its own localhost.

Stop fighting over port 3000. Each worktree gets its own ports, hostnames and databases, even when it runs on a remote machine.

curl -fsSL https://devlanes.run/install.sh | sh
Car models by Kenney, CC0

Three worktrees up at once. One of them runs on a VPS.

Each is a lane: own ports, own hostnames, passed to every process. The VPS one still opens on your laptop.

~/dev/myapp
$ devlanes start
myapp@0 · main
✓ services  3 of 3 ready
  ✓  api     https://api.myapp.localhost
  ✓  web     https://myapp.localhost
  ✓  worker  http://127.0.0.1:20002
~/dev/myapp-checkout
$ devlanes start
myapp@1 · feat/checkout
✓ services  3 of 3 ready
  ✓  api     https://api.myapp1.localhost
  ✓  web     https://myapp1.localhost
  ✓  worker  http://127.0.0.1:20012
my-vps:~/myapp-perf
$ devlanes start
myapp@3 · agent/perf
✓ services  3 of 3 ready
  ✓  api     https://api.myapp3.localhost
  ✓  web     https://myapp3.localhost
  ✓  worker  http://127.0.0.1:20032

See what every lane and service costs, live.

Running devlanes opens a terminal view of every lane in the project, with the state of each service and its live output. The monitor shows CPU and memory per lane, per service and per container, with a minute of history, so you can tell which worktree is eating the memory. Open a unit to read its output, type into it, stop it or restart it.

This is the real TUI, running as a WebAssembly bundle on fake data. Click to interact.

devlanes
The TUI in the docs

One committed file describes the stack for every worktree.

devlanes.yaml sits at the root of the repository. lane.domain is myapp.localhost in lane 0 and myapp1.localhost in lane 1; a service only has to listen on $PORT, and presets for Vite, Next, Wrangler and others pass the right flags.

A database server runs once, with a database per lane inside it, so a migration in feat/checkout leaves main's data alone. Lanes that need their own containers get them.

More about lanes
devlanes.yaml
services:
  api:
    run: pnpm --filter api dev
    hosts: "api.${{ lane.domain }}"

  web:
    preset: vite
    env:
      VITE_API_URL: "${{ services.api.public_url }}"
    hosts: "${{ lane.domain }}"

infra:
  compose: docker-compose.yml

lanes:
  vars:
    db_name: "myapp_${{ lane.name }}"

global_env:
  DATABASE_URL: postgres://localhost:${{ infra.postgres.port }}/${{ lane.db_name }}

Run the lanes on a VPS, a container or a codespace. It opens no ports.

Pair once over ssh. Your laptop's daemon then mirrors the remote hostnames and ports, same names, same numbers, so the URL a service prints there is the one you open here, with the certificate you already trust.

Nothing is published, and the remote machine needs no forwarding enabled.

More about remote machines
on my-vps
$ devlanes daemon pair
pairing code: K7QM-3XWD
it works once and expires in 10 minutes
on your other machine, run:
  devlanes remote connect <box> --code K7QM-3XWD
on your laptop
$ devlanes remote connect my-vps --code K7QM-3XWD
$ devlanes url ls
HOST                      TARGET       PORT   STATE
api.myapp1.localhost  ->  myapp@1:api  20010  ready
myapp1.localhost      ->  myapp@1:web  20011  ready

Your agent tails the server you started in another terminal.

The daemon owns the processes, so the agent's shell reaches the stack you started in yours: it tails the logs and restarts a service. On its own branch it gets its own lane, and its shell can end without the stack dying.

More about agents
agent session

checkout 500s on my lane 1, see what the api says

devlanes logs myapp@1:api --tail 100
TypeError: Cannot read properties of undefined (reading 'id')
    at createOrder (src/checkout/order.ts:48:31)
    at POST /checkout (src/routes/checkout.ts:19:5)

Guest checkout has no cart.customer, and order.ts:48 reads .id off it. Added the guard, restarting api.

edited src/checkout/order.ts
devlanes restart myapp@1:api
ready api  https://api.myapp1.localhost

Checkout answers again on https://myapp1.localhost.

Free and open source

devlanes is Apache-2.0. It is a CLI and a daemon that run where your shell runs: no account, no hosted service, nothing phones home. Written in Rust, for macOS, Linux and Windows 11. The source, the issues and the releases are on GitHub.

Run your first lane

Install devlanes, describe your stack in a devlanes.yaml at the root of the repository, run devlanes start.

curl -fsSL https://devlanes.run/install.sh | sh

devlanes is in beta. Presets cover Vite, Next, Wrangler and Tauri; Compose files and plain containers work as infra. Lanes keep ports, hostnames and data apart; they are not a sandbox, every process runs as you. A remote connection never runs commands on the other machine.