Skip to content
| Marketplace
Sign in
Visual Studio Code>SCM Providers>Go RebaseNew to Visual Studio Code? Get it now.
Go Rebase

Go Rebase

kmarkussen-publisher

|
2 installs
| (0) | Free
Visualize a local patch stack and organize file changes across commits.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Go Rebase

Go Rebase is a VS Code extension for understanding and reorganizing the patches on a local branch. It presents commits in patch order and groups each commit's file changes into a compact visual stack.

Current features

  • Activity Bar container and Patch Stack sidebar
  • Patch-stack editor with commit metadata, changed files, and line statistics
  • Publication-aware patch discovery: upstream-only commits when tracking is configured, or full local history with an explicit warning when a remote exists without tracking
  • Collapsible patch/file trees, selectable ranges for modified text files, and whole-delta moves for non-text files
  • Drag/drop and keyboard staging of whole-file deltas or selected ranges, including direct dragging of individual selected hunks
  • Multi-file selection and atomic group moves between patches
  • Drag-to-create “New Patch” insertion zones with wheel and edge auto-scroll
  • Explainable file-lineage dependency highlighting
  • Dependency-group analysis with color-coded connected patch groups, editable persisted group names, and group-size badges
  • Group-level selection, collapse/expand, dependency-closure preview, and dependency-safe reordering
  • Dependency-group extraction into a new branch/worktree with group-only or dependency-closure modes
  • Explainable, confidence-scored split suggestions for commits mixing changes from separate path areas, with source-patch selection, expanded-patch split groups, and one-click staging into a new patch
  • Staged-plan preview, validation, undo/reset, progress, and read-only operation terminal
  • Failed-rebase inspection in a separate VS Code worktree window before cleanup
  • Workspace-persisted one-time setup and per-patch verification pipelines with selectable shells, ordered commands, and live timing/pass/fail status
  • Staged commit-message editing with multiline message support
  • Commit-message drafts persist across rerenders and save automatically when the editor loses focus
  • Basic adjacent-patch Fix up, Squash, and Drop operations with staged preview
  • Virtual new patches that can collect whole-file or selected-range deltas from existing patches
  • Automatically focuses and selects the default commit message when a new patch is staged
  • Drag-and-drop and keyboard patch reordering with dependency-inversion warnings
  • Multi-patch selection and single-drag group reordering
  • Isolated temporary-worktree rewriting with a recovery ref and guarded branch update

Rebase execution flow

Go Rebase does not run git rebase directly. It builds the staged plan in an isolated temporary worktree and changes the user's branch only after the complete plan succeeds.

  1. Review and confirmation — Go Rebase summarizes the branch, upstream boundary, staged operations, setup and verification commands, shell, warnings, and expected result. Execution begins only after confirmation.
  2. Safety preflight — The plan is checked for blocking diagnostics, a clean working tree, and unchanged HEAD/upstream state.
  3. Recovery point — A recovery ref is created before any branch update.
  4. Isolated replay — A temporary detached worktree is created from the first unaffected commit. Unchanged commits before the affected suffix are reused. The remaining patches are rebuilt in projected order, applying file/hunk moves, reorder, fixup, squash, drop, and new-patch operations.
  5. Setup and verification — After the first rebuilt patch is committed, one-time setup commands run in the configured shell. After each rebuilt patch, per-patch verification commands run in order. Their output appears in the read-only operation terminal, and each step reports progress, status, and elapsed time.
  6. Final validation — Unless a patch was intentionally dropped, the rewritten tree must match the original tree. The repository state is checked again before the update.
  7. Atomic update and cleanup — The branch ref is updated with an expected-old-HEAD guard, the working tree is synchronized, and the temporary worktree is removed. The recovery ref remains available.

If replay or verification fails, the original branch is left unchanged. The user can open the failed temporary worktree in a new VS Code window for inspection; cleanup waits until that window is closed.

Run locally

Install dependencies and compile the extension:

npm install
npm run build

Open this folder in VS Code and press F5. In the Extension Development Host, open a Git repository with local commits and select the Go Rebase icon in the Activity Bar.

Product direction

Dragging a file change between patches produces a staged preview. Modified text files may be split by selecting unified-diff ranges before staging. Applying a validated plan happens through a temporary worktree, preserves a recovery ref, rejects dirty or conflicted repositories, and updates the user's branch only after every rewritten commit succeeds.

Dependency visualization should start with explicit file relationships: show when a later patch modifies a path introduced or renamed by an earlier patch. These edges are evidence of ordering constraints, not a claim that the code compiles independently.

The detailed implementation roadmap and safety contract are in docs/implementation-plan.md.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft