Skip to content

dutifuldev/verge

Repository files navigation

Verge

Verge is an evidence-based CI/CD control plane.

Instead of treating CI as a fixed list of workflows that only end in pass or fail, Verge records structured evidence about repository health over time. It decides what to run, what can be reused, what can be resumed, and what parts of a repository are still stale or unknown.

The current MVP runs Verge on the Verge repository itself.

What Exists Today

The repository currently includes:

  • a root verge.config.ts that defines the Verge repo's own steps
  • a workspace verge CLI for API, worker, sync, and process discovery commands
  • a Fastify API in apps/api
  • a React + Vite dashboard in apps/web
  • a long-running worker in apps/worker
  • shared contracts, planning logic, and persistence packages in packages/*
  • Postgres-backed persistence via Kysely
  • local filesystem-backed artifact and checkpoint storage
  • GitHub webhook ingestion
  • manual run creation
  • process reuse
  • checkpoint-based resume for cooperative steps
  • GitHub Actions CI that validates the repo and runs a self-hosted smoke test

Core Model

The main runtime shape is:

run -> step -> process -> observation

In plain terms:

  • a run is one commit-level, PR-level, or manual evaluation
  • a step is a major check inside a run, like test or build
  • a process is the smallest meaningful thing Verge tracks as its own result
  • an observation is the recorded result

A process should not be an execution chunk or grouping convenience. It should be the real unit of evidence, such as one test, one lint target, one build target, or one document check.

Workspace Layout

apps/
  api/
  web/
  worker/
packages/
  contracts/
  core/
  db/
infra/
  local/
scripts/
docs/

Tooling

This repo is TypeScript-first and uses:

  • pnpm
  • vite
  • vitest
  • oxlint
  • oxfmt

The repo now also has a typed config and CLI boundary:

  • verge.config.ts as the repository contract
  • pnpm exec verge ... as the operational entry point

Local Development

Prerequisites

  • Node.js 22+
  • pnpm
  • PostgreSQL

You can use the included Compose file for local Postgres:

pnpm db:up
pnpm db:migrate

By default the local database URL is:

postgres://verge:verge@127.0.0.1:54329/verge

Install

pnpm install

Run Everything

pnpm dev

This starts:

  • the API on http://127.0.0.1:8787
  • the worker
  • the Vite web app

Useful Commands

pnpm exec verge sync
pnpm exec verge api
pnpm exec verge worker
pnpm lint
pnpm format:check
pnpm typecheck
pnpm test
pnpm build
pnpm docs:validate
pnpm test:integration
pnpm test:smoke

Self-Hosting

Verge is intended to validate itself.

The self-hosted steps currently cover:

  • format-check
  • lint
  • typecheck
  • test
  • build
  • docs:validate

The test step now materializes one process per individual Vitest test. The smoke test boots the API and worker, creates a manual run against this repo, executes the self-hosted steps, and verifies checkpoint-based resume on the test step.

CI

GitHub Actions runs the following on pull requests and on main:

  • formatting
  • lint
  • typecheck
  • docs validation
  • build
  • unit tests
  • DB-backed integration tests
  • self-host smoke test

The workflow lives at .github/workflows/ci.yml.

Storage

The current MVP uses filesystem-backed artifact storage. Logs and checkpoints are written under .verge-artifacts by default.

This is a local-development and early-deployment choice. The storage model is intentionally abstract enough to move to object storage later.

Deployment Shape

The clean deployment shape for the current MVP is:

  • one web service for apps/api
  • one background worker for apps/worker
  • one static site for apps/web
  • one Postgres instance
  • one persistent storage location for artifacts and checkpoints

The repo also includes a single-host Docker Compose deployment path with Caddy, Postgres, API, worker, and the built web UI:

Documentation

Design and planning docs live in docs/:

Current Status

This is an MVP control plane, not a finished platform. The important thing it proves today is the full loop:

event in -> plan -> run -> record evidence -> query repository health

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors