Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .bb/plugins.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
"plugins": [
{ "name": "workstreams", "source": "./plugins/workstreams" },
{ "name": "kubernetes-provider", "source": "./plugins/kubernetes-provider" },
{ "name": "devbox-provider", "source": "./plugins/devbox-provider" }
{ "name": "devbox-provider", "source": "./plugins/devbox-provider" },
{ "name": "diff-explorer", "source": "./plugins/diff-explorer" }
]
}
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ Plugins for [bb](https://getbb.app), maintained by Bit Complete.
| [devbox-provider](plugins/devbox-provider) | Machine provider that creates devboxes in your Incus project on bertha, once you connect devbox |
| [thread-briefs](plugins/thread-briefs) | Gives every thread a durable goal / current state / next step brief, summarized outside the working chat |
| [multi-repo](plugins/multi-repo) | Gives a project a set of git repos and every thread a workspace holding a checkout of each |
| [diff-explorer](plugins/diff-explorer) | Scrollable diff of every changed file, with ⌘-click go to definition and Ctrl+- to go back |

Install one:

Expand Down
2 changes: 2 additions & 0 deletions plugins/diff-explorer/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules
dist
28 changes: 28 additions & 0 deletions plugins/diff-explorer/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
MIT License

Copyright (c) 2026 Arash Outadi

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

---

monaco/ is a build of monaco-editor 0.56.0, and scripts/multi-diff.js adapts
code from Visual Studio Code. Both are MIT licensed:
Copyright (c) 2016 - present Microsoft Corporation.
See monaco/LICENSE and monaco/ThirdPartyNotices.txt.
21 changes: 21 additions & 0 deletions plugins/diff-explorer/PLUGIN_OVERVIEW.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
## What you get

- One scrolling view of every changed file in the thread's workspace. Changed lines show in red and green, and unchanged regions fold away.
- A switch between **Uncommitted** changes and **All changes** since the merge base with the base branch.
- ⌘-click a symbol, or press F12, to open its definition. Do it again from there to go one level deeper.
- Press Ctrl+- to go back one level. The back button shows the current file, line, and depth.
- Open the panel from the button in the thread header, or with ⌘⇧D.

## How it works

The panel uses the Monaco editor and the VS Code multi-file diff view. Only the files on screen get an editor, so a large change set stays responsive.

Definitions come from the language server for the file's language. The server runs on the machine that holds the workspace. It starts when the panel loads, so it can index the project before your first click.

## Requirements

- TypeScript and JavaScript: Node.js with `npx`. The first use downloads `typescript-language-server`.
- Go: `gopls`. Rust: `rust-analyzer`. Python: `pyright-langserver`. C and C++: `clangd`. Swift: `sourcekit-lsp`. Each must be on your PATH.
- Files in other languages show the diff without go to definition.
- Binary files and files too large to diff are skipped.
- Tested on macOS. The plugin uses experimental BB plugin APIs.
46 changes: 46 additions & 0 deletions plugins/diff-explorer/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# Diff Explorer

A [BB](https://getbb.app) plugin. Review a thread's changes, and jump into the code behind them.

![Diff view](screenshots/diff.png)

## What it does

- Shows every changed file in one scrolling view.
- Switches between **Uncommitted** and **All changes** since the base branch.
- ⌘-click a symbol (or press F12) to open its definition.
- Jump again to go deeper. Press **Ctrl+-** to go back one level.
- Opens from the thread header button, or with **⌘⇧D**.

![Go to definition](screenshots/go-to-definition.png)

## Install

```sh
bb plugin install git:https://github.com/arashout/bb-plugin-diff-explorer.git
```

## Go to definition needs a language server

| Language | Server (on your PATH) |
|---|---|
| TypeScript, JavaScript | `npx` (downloads `typescript-language-server` on first use) |
| Go | `gopls` |
| Rust | `rust-analyzer` |
| Python | `pyright-langserver` |
| C, C++ | `clangd` |
| Swift | `sourcekit-lsp` |

Other languages still show the diff.

## Develop

```sh
npm install
npm run build:monaco # only after changing scripts/multi-diff.js or the Monaco version
bb plugin install .
```

## License

MIT. Bundles Monaco and code adapted from VS Code (both MIT, © Microsoft).
Loading
Loading