Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to ignore uncommited change in Github gui for MAC?

I am using Github GUI for Mac. Now I've some changes in my local repository, but I want to ignore them and pull latest remote repository. I tried Repository/Pull, but got Git Error.

"•error: Your local changes to the following files would be overwritten by merge: Classes/xxx.m Please, commit your changes or stash them before you can merge."

I tried Repository/Synchronize, but got following error.

"Sync Failed. Please commit all your changes before syncing."

Any idea?

like image 806
ttotto Avatar asked Jul 08 '12 17:07

ttotto


2 Answers

Place a checkmark near each of the changed files, then go to the Repository menu and click Discard Changes to Selected Files.

like image 78
user01380121 Avatar answered Nov 07 '22 08:11

user01380121


If you mean using MAC GUI only, check and right click the changed files then select the discard the changes.

like image 21
Leo wang Avatar answered Nov 07 '22 09:11

Leo wang