Conflict Resolver Assistant
A simple visual tool to help you resolve Git merge conflicts. Paste a conflict block, choose the code you want to keep, and get the clean, merged version.
How to Use
Paste Conflict: Paste the entire Git conflict block, including the <<<<<<<
, =======
, and >>>>>>>
markers.
Choose a Version: Use the buttons to select "Use 'Ours'", "Use 'Theirs'", or manually edit the final output.
Copy Merged Code: Copy the final, clean version of your code from the output pane.
Conflict Block
"Ours" Changes (Current Branch)
"Theirs" Changes (Incoming Branch)
Resolved Output
The resolved code will appear here...
About the Conflict Resolver Assistant
The Conflict Resolver Assistant is a visual aid designed to simplify the often-daunting task of resolving Git merge conflicts. It parses the conflict markers, presents the conflicting code blocks side-by-side, and allows you to choose which version to keep with a single click.
Common Use Cases
Resolving Merge Conflicts
The primary use case. When `git merge` or `git rebase` results in a conflict, this tool helps you visually inspect both versions and choose the one to keep.
Learning Git
For those new to Git, this tool provides a safe and intuitive way to understand how merge conflicts work without the risk of messing up a real repository.
Collaborative Editing
Even outside of Git, you can use this tool to merge text from two different versions of a document.
Applying Patches Manually
If a patch file doesn't apply cleanly, you can use this tool to manually resolve the conflicts.
Example of Resolving a Conflict:
Pasting the conflict block into the input will allow you to choose which version to keep.
Frequently Asked Questions
What do 'ours' and 'theirs' mean?
In Git, 'ours' refers to the version of the code in your current branch (the branch you are merging into). 'Theirs' refers to the version of the code in the branch you are trying to merge.
Can this tool handle multiple conflicts in one file?
This tool is designed to resolve one conflict block at a time. If your file has multiple conflicts, you should copy and paste each conflict block into the tool separately.
Is this a replacement for a graphical merge tool like VS Code's?
This is a lightweight, web-based assistant for simple conflicts. For complex merges involving multiple files or intricate conflicts, a full-featured graphical merge tool integrated into your IDE is often a better choice.
What happens if I need to manually edit the result?
You can directly edit the text in the 'Resolved Output' area. This is useful if you need to combine parts of both 'ours' and 'theirs', or write a completely new version. The 'Use This Version' buttons are just for convenience.
Does this tool save my code?
No. All processing is done in your browser. Your code is not sent to any server, ensuring your data remains private and secure. When you close the page, the data is gone.