In Eclipse, how to copy an existing project to another project?
- Close Eclipse
- Copy the folder of existing project to anywhere on your disk.
- Start Eclipse. Turn off the automatically build.
- In the Eclipse do Refactor / Rename to the new project name. (If it connected to CVS/SVN disconnect before rename.)
- Import back the old project from place where you copied in the second step.
- Turn on the automatically build.
Enjoy them!
This question appears in Google search as top result for query "copy project in eclipse".
To copy project in Eclipse:
1) right click on project in Package Explorer view;
2) choose Copy;
3) right click on free place in Package Explorer view;
4) choose Paste;
5) enter new name in the prompt window.
To answer actual question, the best way is to delete project B and after -- copy project A as explained above and give it name B.