I have a git server and it has a user called git
For remote clients, they use git@gitserver to clone, push and pull.
For this to work, I need to give the password for user git.
Is there a better way of dealing with this?
You can use ssh key for authentication. Each user make their own ssh key pair and then the public keys are collected inside
~/.ssh/authorized_keys of the git user. After this is set up, users don't need to enter nor know the password of the git user.