Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to restore last saved code in eclipse?

In Eclipse, I accidentally SVN update my code to HEAD version of the repository. My local code is what I want to keep, so how do I revert to that? Tks.

like image 953
EyeQ Tech Avatar asked Jan 01 '12 09:01

EyeQ Tech


2 Answers

An easy way to do this:

  1. Right click on the file you would like to restore
  2. Go to Team
  3. Select Show Local History
  4. Choose the desired date
  5. Copy the content and paste in your actual file

And it's done... Enjoy.

like image 181
Milos Cuculovic Avatar answered Oct 03 '22 18:10

Milos Cuculovic


You can access the local history in eclipse. Refer to this link

http://help.eclipse.org/helios/index.jsp?topic=%2Forg.eclipse.platform.doc.isv%2Fguide%2Fteam_synchronize_localhistory_example.htm

like image 38
Shraddha Avatar answered Oct 03 '22 17:10

Shraddha