I’m using a box as a shared repo, and my team connects to it via ssh.
What I do is:
-
Create an empty git repository on the central machine
git init -
Then from each workstation do something like
git clone ssh://user@central-box/Users/user/Projects/my-project/.git/
This works nice, but git keeps yelling at me every time I make a push something like this:

Is there a better way of sharing a repo over ssh.
IMPORTANT: I’m well aware of the existence of gitosis and tools like that, I do not want anything fancy. Just sharing a .git repo over ssh.
Thanks
On the host machine you should do
Because you don’t need the actual files, just the repo.
If the warning message is on a FIRST push to a repo, and no one has touched it, do a
Otherwise, this error means your branch scheme isn’t correct. You should NOT be editing the branch origin/branchname. You want your own local branch called branchname, then when you are ready to check in your code you do
And you will push from your local branchname to origin/branchname.
Edit
I would like to see the output of this command in your local repo:
You should not see the word origin or your server name anywhere in the output