'How to regenerate deleted pom.xml file and add dependency in eclipse automatically

I mistakenly deleted my pom.xml file from my application. I created new pom.xml but dependencies are not added.

How can I add already generated dependencies automatically in created pom.xml file.



Solution 1:[1]

If you are using eclipse, you can try to go to:

C:\Users\user\.m2\repository\yoursAPP\yoursAPP\0.0.1-SNAPSHOT

And there you will find something like:

YourAPP-0.0.1-SNAPSHOT.pom

which is your Pom file, just rename it

I know, that question is old, but maybe it will help somebody.

Solution 2:[2]

Eclipse has this feature: Right Click on project -> Restore from Local History

Solution 3:[3]

Yes.. go for Right Click on project -> Restore from Local History and their you can find pom.xml.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1
Solution 2 karto
Solution 3 Pradnyesh Gaonkar