---
title: "Git"
description: "A repository dashboard: a Next.js + shadcn/ui SPA that shells out to git. The same bundle runs live or static."
canonical_url: "https://devfra.me/add-ons/devframes/git"
---
# Git

> A repository dashboard: a Next.js + shadcn/ui SPA that shells out to git. The same bundle runs live or static.

A repository dashboard: a **Next.js + shadcn/ui** SPA that shells out to `git`. The same bundle runs live or static.

Package: `@devframes/plugin-git`

![Git devframe](https://devfra.me/screenshots/plugin-git-1.png)

*Status and graph*

## What it does

Read views are read-only; write mode adds staging, unstaging, and commits (gated by write permission).

## Standalone

```sh
pnpx @devframes/plugin-git         # dev server (live RPC over WebSocket)
pnpx @devframes/plugin-git --write # also enable staging / committing from the UI
pnpx @devframes/plugin-git build   # static deploy → dist-static/
```

## Programmatic

`createGitDevframe(options)` returns a definition for any adapter.

```ts
import { createGitDevframe } from '@devframes/plugin-git'
import { createCac } from 'devframe/adapters/cac'

await createCac(createGitDevframe({
  repoRoot: process.cwd()
})).parse()
```

| Option     | Default            | Description                           |
| ---------- | ------------------ | ------------------------------------- |
| `repoRoot` | the devframe `cwd` | Repo to inspect.                      |
| `port`     | `9710`             | Dev-server port.                      |
| `write`    | `false`            | Enable staging / unstaging / commits. |

## RPC

Namespaced `devframes:plugin:git:*`. Reads are `query` (`snapshot: true`): `status`, `log` (+ parent hashes), `branches` (ahead / behind), and `diff` (unified patch), live in dev, baked static, `isRepo: false` outside a repo. Write `stage` / `unstage` / `commit` are write-mode `action`s.

For a repo capability shared across devframes rather than this dashboard's own RPC, see the [`@devframes/service-git`](https://devfra.me/add-ons/services/git) wire service.

## Source

[`plugins/git`](https://github.com/devframes/devframe/tree/main/plugins/git)


## Sitemap

See the full [sitemap](https://devfra.me/sitemap.md) for all pages.
