How to git pull with two users?

I deploy my applications by cloning repository into production server.
When I make some changes I just go to the production server and invoke : git pull .
I don’t know if this is the right way of deploying but it works fine for me for now.

But I have one issue, recently I’ve started working with another developer and to
update the repository we have to know each other passwords and do git pull on production server, which is of course nonsense . Before GIT I used SVN and there was no such issues,
everybody could invoke svn update with his account.

  • Gitolite with LDAP not working
  • github error: insufficient permission for adding an object to repository database
  • Git: How to create a new branch from a tag?
  • Error with git: remote HEAD is ambiguous, may be one of the following
  • How make Eclipse/EGit recognize existing repository information after update?
  • git erroneously states I'm ahead of origin/master by 1 commit
  • How to solve this issue or what is recommended way of deploying application from git ?

  • Git stash: How to see if there are stashed changes in a branch
  • An error was raised by libgit2. Category = Os (Error)
  • Is there a way to add a directory to Git but exclude extensions in .gitgnore?
  • Git: after preparing a real merge commit, how to create a simple commit?
  • Git: Failed to erase credential: Element not found tried all other solutions
  • When would you use the different git merge strategies?
  • One Solution collect form web for “How to git pull with two users?”

    If the problem is that you don’t have the right permissions to run git pull on a repository checked out by another user, you can try to initialise your production repository using --shared=all, which will tell git to set permissions so that anyone can run git commands.

    Git Baby is a git and github fan, let's start git clone.