Official

git

Built-in git UI (JavaScript UI plugin).

The app opens the listing; nothing installs until an agent in your Plugins workspace has read the files and you enable the plugin. In a terminal: dvg install divergence/git@0.3.1

Permissions in 0.3.1

  • Run git commands git.writeHighRuns any git command.Stage, commit, switch branches and sync with the remote
  • Use your agents' models models.useHighRuns prompts through the agents you enabled.Write commit messages and pull requests with the cheapest model of your agents, on your own account
  • Read chats chats.readMediumReads your transcripts and chat lists.Refresh when an agent finishes a turn
  • Run named programs processMediumStarts the listed programs.Find and open the branch's pull request with the GitHub CLIPrograms: gh
  • Read git status and diffs git.readLowReads git status and diffs.Show the repository's status and diffs, and follow its changes
  • Show panels ui.slotsAlways grantedShows views in the listed parts of the window.Show the source control button and panelSlots: railright

Files

main.ts2.1 KB
// Register the source-control command and views synchronously, then follow event streams.
// Repository effects follow the view lifecycle; render modules remain pure.
import * as Effect from "effect/Effect";
import * as Stream from "effect/Stream";
import { App, Commands, Events, Views, runPlugin } from "divergence/effect";
import { Git } from "./controller.ts";
import { runFinished } from "./status.ts";
import { renderRail, renderPanel } from "./views/panel.tsx";

const program = Effect.gen(function* () {
  const git = yield* Git;
  const commands = yield* Commands;
  const views = yield* Views;
  const app = yield* App;
  // Opened by its key, the panel's message box takes the keyboard (the
  // rail's button only shows it).
  yield* commands.register(
    "git.toggle",
    Effect.gen(function* () {
      const opening = (yield* app.state).shared?.rightPanel !== "git";
      yield* git.toggle;
      if (opening) yield* views.focus("git-message");
    }),
  );
  git.views.push(
    yield* views.add("rail", { slot: "rail", render: (ctx) => {
        ctx.run(git.show(ctx.app.workspaceId));
        return renderRail(ctx, git);
      }, on: ["app_state"], order: 20 }),
  );
  git.views.push(
    yield* views.add("right", { slot: "right", render: (ctx) => renderPanel(ctx, git), on: ["app_state"], order: 20, title: "Source Control" }),
  );
  const events = yield* Events;
  const refreshOn = <A>(stream: Stream.Stream<A>) =>
    stream.pipe(
      Stream.runForEach(() => Effect.forkScoped(git.refresh(), { startImmediately: true })),
      Effect.forkScoped({ startImmediately: true }),
    );
  yield* refreshOn(events.stream("git_changed").pipe(Stream.filter((event) => event.workspaceId === git.state.workspaceId)));
  // Every streamed word is an agent event: only finished runs are asked
  // for (an older runtime sends them all, which `runFinished` sorts out).
  yield* refreshOn(events.stream("agent", { kinds: ["run_finished"] }).pipe(Stream.filter((event) => runFinished(event.kind))));
  yield* refreshOn(events.stream("workspaces_changed"));
});

export default runPlugin(Git.layer, program);

Versions

VersionPublishedPlugin APISizePermissionsStatus
0.3.3latestNov 21, 2026>=5 <630.8 KB6 permissionsListed
0.3.2Nov 16, 2026>=5 <630.4 KB6 permissionsListed
0.3.1Nov 11, 2026>=5 <630.2 KB6 permissionsListed
0.3.0Nov 9, 2026>=5 <629.2 KB6 permissionsListed
0.2.1Oct 27, 2026>=2 <413.6 KB4 permissionsListed

Reviews and comments

0 threads · 0 reviews

No comments yet.