0

Clone attempt over ssh:

Cloning into repo...
Password:
bash: git-upload-pack: command not found
fatal: The remote end hung up unexpectedly


Chris-Muenchs-Mac-Book-Pro:rails_projects cmuench$ ssh chrismuench@example.com echo \$PATH
Password:
/usr/bin:/bin:/usr/sbin:/sbin

the git stuff is in:

/usr/local/git/bin (Defined in:  /etc/paths.d/git)

How can I get this in the system wide path for all users without having to modify ~/.bash_profile?

Chris Muench
  • 17,444
  • 70
  • 209
  • 362
  • Which OS runs on example.com? – Lars Noschinski Mar 09 '11 at 22:29
  • possible duplicate of [git-upload-pack: command not found, how to fix this correctly](http://stackoverflow.com/questions/225291/git-upload-pack-command-not-found-how-to-fix-this-correctly) – jrockway Nov 02 '11 at 18:56
  • There is a great answer over here: [Question 225291][1], and in specific this answer: [crewburn's answer][2] [1]: http://stackoverflow.com/questions/225291/git-upload-pack-command-not-found-how-to-fix-this-correctly [2]: http://stackoverflow.com/a/6495787/870975 – JackFrost Nov 14 '12 at 23:03

3 Answers3

3

from client aspect of view

ssh clone -u /usr/local/git/bin/git-upload-pack <repository>
linleno
  • 172
  • 2
  • 6
1

Put it in the system wide /etc/profile

cxreg
  • 11,088
  • 1
  • 20
  • 10
-1

I ended up symlinking the git commands in to /bin

Chris Muench
  • 17,444
  • 70
  • 209
  • 362