Hi, I am trying to push a git repo to a test server. When I try:
git push origin master
I receive the following error:
bash: git-receive-pack: command not found
fatal: the remote end hung up unexpectedly

This would indicate to me that when I ssh that the git-receive-pack
executable isn't found. However, if I just do a straight ssh to the
server with the same username that I set for my remote origin for git,
I can invoke git-receive-pack.

echo $PATH returns /usr/local/git/bin which is where git-receive-pack
is located. If I just type git-receive-pack at the prompt when I SSH,
then I see "usage: git-receive-pack <git-dir>"

Google brought me to this post:

I tried to create the .bashrc file and add the command suggested, but
it doesn't help.

It looks like the "git push" command on my development machine is
sending the wrong information to the test server. If I use the
git push --receive-pack /usr/local/git/bin/git-receive-pack
then all works as I would expect.

Does anybody have any idea what I need to do in order to avoid typing
the --receive-pack parameter each time that I want to push to the
repo? As far as I can tell, my .bash_profile and .bashrc files are set


You received this message because you are subscribed to the Google Groups "Git 
for human beings" group.
To post to this group, send email to git-us...@googlegroups.com.
To unsubscribe from this group, send email to 
For more options, visit this group at 

Reply via email to