I have a git repository which linked to a remote repository. I'm currently working on one of the folders present in this git repository. This folder contains src
,META-INF
,WEB-INF
and jsp
files. It doesn't contain .project file (to import it as a project in eclipse). I believe the reason is multiple developers use different IDEs. So uploading their settings file to git repository doesn't seem good.
Question 1: How is this usually handled? What directory structure is used to share a web application
in git?
To load this files into my eclipse project, i tried these 3 ways:
Creating a new dynamic web project and copying the files from the git repository. After modifications copy these into the git repository. This is by far the easiest to setup and mundane task to do!
Using
git import
of Eclipse. Import -> Git -> Projects from Git -> Existing local repositories -> (selecting the Repository) -> Import as general project -> Next -> Finish. This gives kind of a file view in eclipse. But navigating between java classes and other content assistant features of Eclipse are not working in this method!I tried creating a
dynamic web project
and linking the files. I could link thesrc
folder easily. But mappingWEB-INF
,META-INF
folders insideWebContent
folder and mapping.jsp
files into direct path of the project doesn't seems to be working!
Question 2: Could you make any of these 3 steps better? Or is there any other way to map these files?
Here is the folder structure:
├───.gitFolder
│
├───AnotherProject
│ └───itsSubDirectories
└───DesiredProject
├───META-INF
├───src
│ └───com
│ └───pack
│ ├───module1
│ └───module2
├───WEB-INF
│ ├───classes
│ │ └───resources
│ └───lib
└───jspFiles