I am new with Git, but I would need some help. How to get rid of those X commits? I don't want to push those local commits, since I don't have the rights to push into that specific branch (it's protected) and I realized that after I commited those changes.
I had some local commits, but I want somehow to discard them (they were not pushed to the origin/<branch_name>) and get rid of this error somehow.
In my IDE, it is showing me the 2 commits that exist in the <branch_name>, but don't exist in origin/<branch_name>.