Cut Branches: A Modern Git Branch Management Tool
Cut Branches is an application I developed to help developers manage and clean up Git branches efficiently. Built with Svelte 5, Pindoba, and Tauri, it provides a user-friendly interface for branch management while ensuring safety when cleaning up branches.
How it Started
During two years working on a project, I frequently fetched branches locally to conduct thorough code reviews. Over time, the accumulation of fetched and created branches became overwhelming, making manual deletion a tedious and error-prone process. Git’s native tools didn’t provide an efficient way to safely manage and clean up branches. I wanted to know before deleting a branch, when was the last time the branch was updated, who was the last author of the commit, if the branch was already merged into other branches and so on.
This frustration led me to develop Cut Branches - a focused solution for branch management. Rather than handling merges, commits, or pushes, the tool specifically addresses the challenge of maintaining a clean repository by providing a safe and efficient way to manage branches.
This was a good oportunity to have a personal project to work on and learn new technologies, other than the ones i use at work.
What is Cut Branches?
Cut Branches is a desktop application that simplifies the process of managing Git branches. It helps developers maintain clean repositories by providing an intuitive interface for viewing, selecting, and deleting branches. The application is particularly useful for teams working on large projects with many feature branches.
Key Features
Branch Management
- Branch Locking: Prevent accidental deletions by locking important branches
- Merge Status: Visual indication of whether a branch is fully merged into the current branch
- Branch Search: Quickly find specific branches using the search functionality
- Commit Information: View the last commit details including date, message, and author
- Branch Switching: Switch between branches with a single click
- Branch Restoration: Restore deleted branches (including multiple branches at once)
Technologies
Cut Branches is built using modern technologies:
- Frontend: Svelte 5 with Pindoba UI components
- Backend: Rust with Tauri
- Git Operations: git2 for Git operations
Development Status
While Cut Branches is still in its alpha stage, it’s under active development with regular updates and improvements. The latest version (v0.5.0) represents a significant step forward in terms of features and stability.
Where to get it
Cut Branches is available for download from the GitHub releases page. Currently, the macOS aarch64 (Apple Silicon) version has been thoroughly tested, with Windows, Linux, and macOS x86_64 builds also available, but not tested yet.
Future Plans
The development roadmap includes:
- End-to-end (e2e) tests for Windows and Linux
- Stash management
- Performance optimizations
Conclusion
Cut Branches aims to simplify Git branch management while ensuring safety and efficiency. Whether you’re working on a small project or managing a large codebase with multiple contributors.
The source code is available on GitHub, and contributions are welcome!