deleted by mistake an entire package in eclipse ide

214 Views Asked by At

I have deleted by mistake an entire package in eclipse.

I tried to search in the local history as written in the :
"Restoring deleted resources from local history" , but it is still writing that the folders don't exist !!

I have searched also in the folders of the whole project in the bin & src.

2

There are 2 best solutions below

0
Sriram Narayanan On

That's where Version control comes to picture.

In case if you've checked "Delete contents on disk" checkbox while you accidentally deleted the package, then I am pretty sure you'll not be able to recover it.

The situation is quite unfortunate. This can be prevented in the future by a VCS.

0
Abhishek Tiwari On

It is always better to use any revision control system to avoid loss of code. These situation can be avoided by reverting the local state. In this case code will get replaced by state on repository. SVN and GIT are good revision control systems.