Use Sublime Merge as a git mergetool. # A wrapper script to make sublimemerge work more nicely. # when used as a git-mergetool. In order for git mergetool to launch Sublime Merge to resolve the current git merge conflicts, you need to put/link the smerge command into your PATH as kebeda has shown, then edit your /.gitconfig to include: merge tool = 'Sublime Merge' mergetool 'Sublime Merge' cmd = smerge mergetool '$BASE' '$REMOTE' '$LOCAL' -o '$MERGED'. River 2 79. Kdiff3, P4Merge, and Beyond Compare are probably your best bets out of the 14 options considered. 'Free and open source' is the primary reason people pick Kdiff3 over the competition. This page is powered by a knowledgeable community that helps you make an informed decision.
Sublime Merge Command Line Usage
Sublime Merge includes a command line tool,
smerge
, to work with repositorieson the command line. This can be used to open repositories, search, and mergefiles.- All examples here assumes that Sublime Text binary is in your PATH. Here `subl` is used to refer to Sublime Text executable, but remember that under Windows this will be `sublimetext.exe`.
- If it was listed as valid, you have to define mergetool.p4merge.path in addition to merge.tool: git config -global mergetool.p4merge.path c:/Users/my-login/AppData.
Setup
Windows
Add
C:Program FilesSublime Merge
to your environment %PATH%
variable.macOS
You'll want to add a symlink (symbolic link) to
smerge
. Assuming you've placedSublime Merge in the Applications folder, and that you have a ~/bin
directoryin your path, you can run:Linux
smerge
should already be available by default. However, it won't be if you'reusing a tarball, so you'll want to add a symlink to sublime_merge
namedsmerge
:Git Merge Tool Setup
The merge tool can be used to process merge conflicts within a Git repositoryfrom the command line.
Mergetool Sublime Merge
After configuring
smerge
using the instructions above, run the following fromthe repository directory:Git Merge Tool Usage
To invoke the merge tool, run:
Mini portable external hard drive. ReferenceSublime Merge Command Line Documentation
Build 2047
Git Mergetool Sublime Merge
New Features
Sublime Merge Mergetool
- Location bar: find branches easily with the new filter bar
- Location bar: ahead / behind indicators can now be clicked to push / pull
- Location bar: branch folders now have context menus
- Tags: added command to checkout tags
- Tags: added command to delete remote tags
- Stashes: added command to delete all stashes (git stash clear)
- Push: added --no-verify option
- Remote branches: added command to checkout corresponding local branch
- Custom commands: select remotes with the new select_remote selector
- Added resize_window command
- Added commit message tooltip to each parent in the parents section of a commit
Improvements
- Windows: upgraded the application title bar
- Linux: upgraded the application title bar on Gnome
- Image diffs: PSD, TGA, PPM, and PGM files now display a rich diff
- Blame: significant loading time improvements
- Commit graph: simplified context menus
- Improved indentation detection
- Switch Repository dialog: open new tabs via Ctrl key (Cmd for MacOS)
- Updated Ctrl+R/Cmd+R to run navigate_to_branch command
- Updated refresh command keybinding to Ctrl+Shift+H/Cmd+Shift+H
- Updated diff titles to elide when space is limited
- Updated theming of the files list
- Added various syntax highlighting improvements
- Detached HEAD state is now more explicit
- Remember which workspace each window is in by default (controlled via the setting remember_workspace)
- Parent folders of the currently checked out branch are now highlighted in the location bar
- Navigation commands: a warning is displayed when exiting the merge tool
- Askpass dialog now supports fingerprint input
- Askpass dialog now detects keypad Enter
- Added themed_title_bar setting
- Menu files: added submenu IDs
- Interactive rebase: the break flag is now supported
- Mac: improved OpenGL rendering performance
- Windows and Mac: Updated bundled Git to 2.29.2
- Linux: added various performance optimisations
Fixes
- Editing commits now signs the edited commits
- Added back missing progress bar for long-running commands
- Fixed newly cloned repositories not loading preferences
- Previous commit messages are now saved per-repository
- Fixed incorrect context menus displaying in location bar
- Improved compatibility on filesystems with large timestamp imprecision
- Fixed inability to revert files if their parent directory does not exist
- Fixed crash when closing the preferences page
- Fixed empty selections being rendered as a line
- Fixed window positions not restoring correctly in certain situations
- Mac: smerge now correctly restores window positions
- Mac: updated icon to follow macOS 11 style
- Mac: added a workaround for Apple M1 OpenGL graphics driver bug that caused text to be rendered incorrectly
- Mac: fixed bug in batching of large Git commands
- Mac: added workaround for the command line helper when app translocation is in effect
- Windows: added a workaround for Intel OpenGL graphics driver bug that caused black bars at the top of some windows
- Windows: fixed glyph rendering bugs
- Windows: fixed flashing when using OpenGL and resizing a window
- Windows: fixed bug in subpixel antialiasing
- Linux and Mac: fixed clean and smudge filters hanging on certain files
- Linux: fixed bug with the caret not moving after performing a text drag
- Linux: fixed freezing on KDE Plasma