{"id":"git-tree","repo":"ZFhuang/paseo-git-tree","url":"https://github.com/ZFhuang/paseo-git-tree","name":"git-tree","description":"Git branch tree panel for Paseo: a lane-based commit graph (git log --graph) as a workspace tab, with branch actions, search, and commit diffs","categories":["git","productivity"],"platforms":[],"caveats":[],"images":[],"health":{"manifestValid":true,"hasReadme":true,"hasLicense":true,"hasTests":true,"hasTypecheckScript":true,"updatedRecently":true},"scannedAt":"2026-09-15T12:53:59.118Z","addedAt":"2026-09-15T13:32:55+03:00","version":"0.1.0","security":{"status":"passed","blockingFindings":0,"advisoryFindings":0,"scannedAt":"2026-09-15T12:52:08.853Z","commit":"8c99642eff41e3d8d338e9181d0bcec8d86ba5d2"},"license":"MIT","paseoVersionRequirement":">=0.8.0","manifest":{"id":"git-tree","requirements":{"paseo":">=0.8.0"}},"repoMeta":{"stars":1,"defaultBranch":"main","pushedAt":"2026-09-11T03:27:06Z"},"owner":{"login":"ZFhuang","avatarUrl":"https://avatars.githubusercontent.com/u/22721612?v=4"},"installNotesHtml":"<pre><code class=\"language-bash\">git clone https://github.com/ZFhuang/paseo-git-tree.git\ncd paseo-git-tree\nnpm install\n</code></pre>","readmeText":"# paseo-git-tree\n\n**A git branch tree for Paseo — `git log --graph` as a panel tab.**\n\n[English](README.md) · [简体中文](README.zh-CN.md)\n\nA [Paseo](https://paseo.sh) plugin that draws the current workspace's branch history as a lane-based commit graph.\n\n## Features\n\n| Feature | Description |\n|---------|-------------|\n| **Workspace tab** | Branch tree as a panel tab; also allowed in the explorer sidebar pane. |\n| **Windowed graph** | Lane-based topology rendering — 500 commits by default, up to 2000 — with dot and line positions that stay put when a card expands. |\n| **Branch picker** | Current-branch dropdown in the header: left-click to preview a branch's history (no checkout), right-click or ⋯ for checkout / merge / rebase / push / pull / fetch / rename / delete. |\n| **Branch chips** | On-graph branch chips: left-click previews, right-click opens the same branch menu as the header. Right-click a commit for create branch / checkout / cherry-pick / revert / merge / rebase / reset / tag. |\n| **Commit cards** | Subject, author, relative time, ref decorations (HEAD / branch names / tags), with branch names sharing one color system between chips and the dropdown. |\n| **Scope switch** | Branch (checked-out branch only), Local (all local branches), All (local + remotes + tags). |\n| **Search** | Client-side match on message / author / hash prefix / branch name; `f: <path>` switches to a server-side `git log -- <path>` filter. |\n| **Compare** | Ctrl/Cmd-click two commits to diff them; expands to a per-file diff view. |\n| **Uncommitted row** | Working-tree summary at the top: changed + untracked file counts and ± line counts. |\n| **Expandable cards** | Click a commit to expand full detail (author, date, parents, message body, per-file diff). Expanded cards refresh in place on fetch/reload. |\n| **Rename-aware files** | File lists show R status with old ⟶ new paths. |\n| **Manual refresh** | ↻ button in the panel header. |\n\n## Install\n\n```bash\ngit clone https://github.com/ZFhuang/paseo-git-tree.git\ncd paseo-git-tree\nnpm install\n\n# Install into Paseo\npaseo plugin install /absolute/path/to/paseo-git-tree\n\n# Verify it's running\npaseo plugin ls\n```\n\nRequirements:\n\n- Paseo 0.8.0 or newer (runtime plugin entries; verified against the bundled `paseo` CLI)\n- `pluginsEnabled: true` in the daemon's `config.json` (Settings → Plugins in the desktop app)\n\n## Usage\n\n### Opening the panel\n\nThe panel registers both the `explorer` and `workspace` locations. Paseo's explorer sidebar only renders its own built-in Files / Changes / Pull request tabs, so plugin panels are not appended there. Open Git Tree from the new-tab menu:\n\n1. Open a workspace.\n2. Click **+ (New tab)** on the tab strip at the top of the main area.\n3. Pick **Git Tree** from the dropdown. It is listed after the built-in tabs, in the plugin group.\n\nIt opens as a regular workspace tab. To open it inside the explorer sidebar pane instead, right-click the sidebar's tab rail and choose **New tab** — that runs the new-tab launcher inside the sidebar, where Git Tree is listed too. Send a sidebar tab back to the main area with its context menu → **Move to main panel**.\n\n### Header controls\n\nLeft to right: title + commit count, current-branch chip, scope filter, search, pull, push, refresh.\n\n| Control | What it does |\n|---------|--------------|\n| **Current branch chip** | Opens the branch list. |\n| **Scope (Filter icon)** | Switch refs: **Branch** (checked-out branch only), **Local** (all local branches), **All** (local + remotes + tags). |\n| **🔍** | Toggles the search input. |\n| **↓ / ↑** | Pull / push the current branch. Push is hidden when the repo has no remotes; both are hidden when HEAD is detached. |\n| **↻** | Reload. Runs `git fetch --all --prune` first when the repo has remotes. |\n\n### Rows\n\nClick a commit to expand it: author, date, parents, message body, and a per-file diff. Hovering shows a tooltip with the full commit message.\n\nWhen the worktree is dirty, the top row is an **Uncommitted changes** pseudo-commit with the short hash `WT`. Expanding it lists the working-tree files.\n\nRight-click or long-press a row for the commit menu: create branch, checkout (detached), cherry-pick, revert, merge, rebase, reset (mixed / hard), add tag, copy message / hash. Uncommitted rows only offer the copy actions.\n\n### Comparing two commits\n\nCtrl/Cmd/Alt-click a commit to set it as the base. The row is badged `⇔ base`. Ctrl/Cmd/Alt-click a second commit to expand the per-file diff between the two; that row is badged `⇔ target`. Ctrl-click the base again to cancel.\n\n### Search\n\nType to match subject, author, hash prefix, or branch name. The graph is re-laid out over the matches.\n\nPrefix the query with `f:` to filter by file instead — for example `f: src/foo.ts`. This runs `git log -- <path>` on the server, so it covers history beyond the loaded window. Input is debounced by 250 ms.\n\n### Branch menu\n\nClick the colored current-branch chip, or right-click a branch chip on the graph to open that ref's actions directly.\n\nThe list has a filter box and a `+ Create branch…` entry, which can check the new branch out immediately. Left-clicking a branch previews its history without moving HEAD; click it again to cancel the preview.\n\nRight-click, long-press, or ⋯ opens that branch's actions:\n\n- **Checkout** — remotes use `git checkout --track`, or switch to the existing local branch of the same name.\n- **Merge / rebase** into the current branch.\n- **Pull / fetch** for remotes.\n- **Push**, or force push with `--force-with-lease`.\n- **Rename**, **copy name**, **delete**.\n\nRebase, force push, and delete ask for a second confirming click.\n\n### File rows\n\nRight-click a file for **Filter commits by this file** (fills in `f: <path>`) or **Copy path**.\n\n## Plugin structure\n\n```\npaseo-git-tree/\n├── paseo-plugin.json        # Manifest (id: \"git-tree\")\n├── index.client.tsx         # Client entry: workspace panel registration\n├── index.server.ts          # Server entry: RPC handler registration\n├── client/git-tree-panel.tsx # Panel UI (React Native) — client bundle\n├── server/git-tree.ts       # git subprocess wrapper — server bundle\n├── shared/git-tree.ts       # Zod RPC contracts + pure graph/layout algorithms\n├── shared/git-tree.test.ts  # Logic tests (node:test) incl. seeded random cases\n├── package.json\n├── tsconfig.json\n├── LICENSE\n└── README.md / README.zh-CN.md\n```\n\n`client/`, `server/`, and `shared/` are compiler boundaries in Paseo 0.8: the client\nbundle compiles only `client/` + `shared/`, the server bundle only `server/` + `shared/`.\n\n## Testing\n\n```bash\nnpm test\n```\n\nPure logic tests on the node built-in test runner, with no UI dependencies:\n\n- Hand-picked edge cases: empty graph, single root, linear chains, fork/merge/octopus merges, multi-child convergence, ref parsing and scope rules, list-geometry round-trips.\n- Programmatically generated cases: a seeded PRNG (mulberry32) builds random commit DAGs, ref decorations, and list-geometry parameters, then checks structural invariants — lane continuity, color assignment, `itemOffset`/`indexAtY` inversion, window coverage.\n- Reproducing a failure: test names carry `seed=N`. Edit the seed arrays in `git-tree.shared.test.ts` to replay one generation.\n\n## Development\n\n```bash\n# Type-check after changes\nnpm run typecheck\n\n# Reload the plugin\npaseo plugin reload git-tree\n\n# Check logs\npaseo plugin logs git-tree\n```\n\n## License\n\nMIT — see [LICENSE](./LICENSE).\n"}