I tried to merge one file with another file, but there are many HEADs with Accept Current Change | Accept Incoming Change | ...
Is there a way to accept all current changes at once?
Git : accept all incoming changes Similar to how we used --ours to ignore incoming changes, you can use --theirs to ignore all changes made by yourself and merge other commits. In the case that you wish accept all incoming changes in the branch, you can cd to the repository and run git against the current directory.
git rebase repo. right click file with conflicts without left-click / opening file in editor pane. click "Accept all Incoming" / "Accept all Current"
The only way to "accept both" would be to just re-stage (marking as resolved) the conflicted files without resolving them ( >>> and <<< would be there still), but your result couldnt be compiled or executed. And this is terrible practice, even if you make commits later to resolve.
Its very easy just go to vs code and press Ctrl+shift+p (command palette) or go to view and open command palette manually and type "merge" in your command palette, now you can see the Accept all current changes.
select the list of files to resolve from the MERGE-CHANGES section, then right-click your mouse and select Accept all incoming. That should do the trick for all files.
You will need to save the updated files once the conflicts are resolved. Click File and then Save All
Select target file, right click and choose 'Accept All Incoming'.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With