Instead of creating bunch of repositories for different modules of one project on github, you can make one repository for the entire project (which makes more sense), and import each module separately in your eclipse.
Note: unlike IntelliJ, in eclipse terminology, module is called project. I’m going to switch back to eclipse terminology in the following part.
You need 9 steps to do it:
- Create a repo on github
- Install EGit in eclipse
- Import the repo on github into eclipse with a Local Destination
- Eclipse will download files in this repo, but it’s just a normal folder, not a project
- Create new local module with eclipse (so the project can be configured by eclipse)
- In the file system, copy local module to the repo folder
- Refresh the repo folder in eclipse, and do a commit
- Delete the local project (the original one) in eclipse
- Import the local repo, and now you should be able to choose the project built earlier as an existing Eclipse project