So I have an Eclipse project I have been working on for quite sometime now and my program that backs up the project hasnt been doing it for months, and I never bothered to check the back ups (stupid me). Well the project got corrupt and I lost all the files and dont have a back up that is even close to up to date. However I do have the jar file that is fairly recent (it only contains .class files) and I was curious if anyone knew how to convert a jar file with .class files into an eclipse project. Thanks for the help!
-
I don't know if you can do it in Eclipse, but IntelliJ has a fairly powerful decompiler. You won't get exactly your original source code, variable names, or comments, but you will get something you can work with.Brandon Dyer– Brandon Dyer2019-11-26 19:51:38 +00:00Commented Nov 26, 2019 at 19:51
-
I don't know how to do it in Eclipse, but I recommend you to use Git or SVN from now on, so your code is always safe so this doesn't happen againFrakcool– Frakcool2019-11-26 20:00:03 +00:00Commented Nov 26, 2019 at 20:00
-
Possible duplicate of restore project from jar file Extract source code from .jar filePetr Aleksandrov– Petr Aleksandrov2019-11-26 20:02:12 +00:00Commented Nov 26, 2019 at 20:02
Add a comment
|
1 Answer
You can follow the steps given below:
- Make sure you have a working decompiler in eclipse. If not, please install https://marketplace.eclipse.org/content/enhanced-class-decompiler into your eclipse.
- Create a new Java project in eclipse > Right-click the
srcfolder > Click import > SelectArchivefrom the list to import your JAR Expand the JAR in eclipse and double click a class file to decompile it.
1 Comment
mehnet ali
and in eclipse ?
