Git Compare File With Branch
Quickly compare your current file with the same file from any Git branch directly in VS Code.
Features
- Single Command: Access everything through one simple command:
Git Compare File With Branch...
- Branch Selection: Choose from all available branches (local and remote) via an intuitive quick pick menu
- Side-by-Side Diff: Opens VS Code's native diff view to compare your current file with the version from the selected branch
- Smart Error Handling: Clear error messages when files don't exist in the selected branch or other issues occur
- Works with Large Files: Supports files up to 10MB
Usage
- Open any file in a Git repository
- Open the Command Palette (
Cmd+Shift+P on macOS, Ctrl+Shift+P on Windows/Linux)
- Type and select:
Git Compare File With Branch...
- Select the branch you want to compare with from the list
- View the side-by-side comparison in VS Code's diff viewer
Requirements
- Git must be installed and available in your PATH
- Your file must be in a Git repository
Extension Settings
This extension does not contribute any settings. It works out of the box!
Known Issues
- Large files (>10MB) may cause performance issues
- Binary files are not supported for comparison
Release Notes
1.0.2
1.0.1
- Fix links in README
- Remove noise from README
- Update name in LICENSE
1.0.0
Initial release of Git Compare File With Branch:
- Compare current file with any branch
- Quick branch selection interface
- Side-by-side diff view
- Support for local and remote branches
Contributing
Found a bug or have a feature request? Please open an issue on GitHub.
License
MIT
Enjoy!
| |