Non-interactive shells do not get the paths from /etc/. So when cloning you'll get
bash: git-upload-pack: command not found
fatal: The remote end hung up unexpectedly
This means ssh couldn't find git-upload-pack. A quick solution to this is adding the following line to your ~/.bash_profile --
[ "$PATH" =~ "git" ] || export PATH=$PATH:/usr/local/git/bin
this will only add the path if its not already present. Which means interactive shells wont have the same path twice, but non-interactive shells will get it too.
No comments:
Post a Comment