DEV Community


Posted on

Plz Help, 2 Repos inside each other to upload on Github

There is a Chat App (Socketio/React/Node) that I'm trying to create. I want to upload it on github. The directory root has two separate folders - Client & Server, while I'm try to upload it, it is saying

"warning: adding embedded git repository: extractor/annotator-server
hint: You've added another git repository inside your current repository."

So, what I'm supposed to do? How to upload my project on github, when it has 2 repos inside?Any hints?

Top comments (5)

harveyhalwin profile image
Heinek Halwin

You probably copied one of those folders into the chat app folder. It might have a .git file in it, that's why it says another repo inside ur current respository. The .git file is hidden, so u need to enable hidden files to be viewed, inorder to see it.

hemant profile image
Hemant Joshi • Edited

Open your client and server and delete the .git folder from both.

Go to your main folder with client and server.

Simply hit
Git init
Git add . && Git commit -m "Hii your issue is resolved"

git remote add origin πŸ™‚

Git pushπŸ¦„

Thank youπŸ™‚

lennythedev profile image
Lenmor Ld • Edited

You'll probably have to remove the git repo stuff for each inner folder, so they don't conflict with the parent one

$ cd server/
$ rm rf - .git/
$ cd ../client/
$ rm rf - .git/

Then you can follow @hemantjoshi's suggestion above to put both of them in a parent repo that includes then both

ajboni profile image

add them as git submodules

shashharsh profile image
Harsh Mangal

You can remove .git files from inner repo.