🎉Extension merged into vscode 🎉
This extension is now part of the official Visual Studio Code feature set, as of 1.13.0. This version of the extension will no longer be maintained and any issues or pull requests should be opened against Microsoft/vscode.
See PR #27150.
- Configuration
better-merge.enableCodeLens
-->merge-conflict.codeLens.enabled
better-merge.enableDecorations
andbetter-merge.enableEditorOverview
-->merge-conflict.decorators.enabled
- Commands. All commands are identical, but have been moved from
better-merge.*
tomerge-conflict.*
The code here is now a reference for anyone interested 😎
Better visual merge conflict support for Visual Studio Code, inspired by merge-conflicts for Atom.
Available on the Visual Studio Extension Marketplace.
- Individual conflicts are highlighted in each file
- Command palette commands for resolving and navigating between merge conflicts (see below)
- CodeLens actions to either accept "current", "incoming" or "both" changes
- Navigation shortcuts between conflicts
All commands use a double key chord combination by default. First press Alt+M
then press the second key.
Accept current
-Alt+M, 1
- Accept current (local) change in the current conflictAccept incoming
-Alt+M, 2
- Accept incoming change in the current conflictAccept both
-Alt+M, 3
- Accept the union of both the current and incoming change for the current conflictAccept selection
-Alt+M, Enter
- Accept the change the editor cursor is currently withinNext conflict
-Alm+M, Down Arrow
- Navigate to the next conflict in the current filePrevious conflict
-Alm+M, Down Arrow
- Navigate to the previous conflict in the current fileAccept all current
- Accept all current changes in the current fileAccept all incoming
- Accept all incoming changes in the current fileAccept all both
- Accept all changes as a "both" merge in the current fileCompare current conflict
- Compares the active conflict in the VSCode diff utility
NOTE: All accept commands can be undone with Undo (Ctrl+Z
/ Cmd+Z
)
The following commands are exposed if you wish to customize key bindings (Preferences > Keyboard Shortcuts)
better-merge.accept.current
better-merge.accept.incoming
better-merge.accept.both
better-merge.accept.selection
better-merge.next
better-merge.previous
better-merge.accept.all-current
better-merge.accept.all-incoming
better-merge.accept.all-both
better-merge.compare
better-merge.enableCodeLens
(default:true
) - Enable / disable inline code lens actions above merge conflict blocksbetter-merge.enableDecorations
(default:true
) - Enable / disable additional editor decoration (background color, etc) of merge conflict blocksbetter-merge.enableEditorOverview
(default:true
) - Enable / disable highlighting of merge conflicts in the editor overview area (right hand side)