git reflog will helps you to understand what triggered.This will produce like this
e507167f (HEAD -> beta, origin/beta) HEAD@{0}: checkout: moving from trunk to beta8ad36515 (origin/trunk, origin/HEAD, trunk) HEAD@{1}: checkout: moving from beta to trunke507167f (HEAD -> beta, origin/beta) HEAD@{2}: commit: sync file removede84ed164 HEAD@{3}: pull: Fast-forward53d627ed HEAD@{4}: checkout: moving from trunk to beta
both modified: file_3
This file may contains conflict markers.This is because of the merge operation.When a conflict happens,it will pause the merging and insert conflict markers into the conflicted file to highlight the areas where issue exists.To fix it,
1. Manually edit the file to keep the desired changes, remove the conflict markers (<<<<<<<, =======, >>>>>>>), and then commit the changes to finalize the merge
2.Run the following to return your branch to the state it was in before you started the merge attemptgit merge --abort
if this diaplays “mo merge” then need to hard resetgit reset --hard
NOTE: This will completely discard changes in the working directory and staging area