Linux – Git version control with multiple users

gitlinuxrepositoryuser

i am a little bit lost with this issue, let me explain you my problem:
I want to setup a git repository, three of four users will contribute, so they need to download the code and shall be able to upload their changes to the server or update their branch with the latest modifications.

So, i setup a linux machine, install git, setup the repository, then add the users in order to enable the acces throught ssh.

Now my question is, What's next?, the git documentation is a little bit confusing,
i.e. when i try from a dummy user account to clone the repository i got:

xxx@xxx-desktop:~/Documentos/git/test$ git clone -v ssh://xxx@192.168.1.104/pub.git
Initialized empty Git repository in /home/xxx/Documentos/git/test/pub/.git/
xxx@192.168.1.104's password: 
fatal: '/pub.git' does not appear to be a git repository
fatal: The remote end hung up unexpectedly

is that a problem of privileges?
need any special configuration?

i want to avoid using git-daemon or gitosis, sorry, maybe my question sound silly but git is powerfull but i admit not so user friendly.

Thanks
Br

Best Answer

You should start with this error:

fatal: '/pub.git' does not appear to be a git repository

Git doesn't think this is a git repository.

So, it's very likely that the path to the repository is incorrect in the clone command.

Is the path to your repository on the server in the clone command correct?

According to your command, the repository is in the server's / (root) directory (e.g. /pub.git)

You need to specify the full path to the repository on the server.

If the repository is in a user's home directory then you'd have to include those directories in the command also:

$git clone -v ssh://xxx@192.168.1.104/~/pub.git

or

$git clone -v ssh://xxx@192.168.1.104/home/username/pub.git
Related Question