To set up git server on mac over ssh, you don't need extra tools. You will need ssh + git.
--
Feng
Once you set up a git repository on the server.
you can git clone it over ssh.
But I got this problem:
1. git-upload-pack cannot be found
bash: git-upload-pack: command not found
fatal: Could not read from remote repository.
Reason:
The ssh environment is different to terminal. The PATH has different value which doesn't contains git's path.
Solution:
add a .bashrc file in the home folder. and add this lines
export PATH=/usr/local/git/bin:$PATH
2. Symbol not found
dyld: lazy symbol binding failed: Symbol not found: ___strlcpy_chk
Referenced from: /usr/local/git/bin/git-upload-pack
Expected in: /usr/lib/libSystem.B.dylib
dyld: Symbol not found: ___strlcpy_chk
Referenced from: /usr/local/git/bin/git-upload-pack
Expected in: /usr/lib/libSystem.B.dylib
Then I cannot resolve this issue. (should be able to resolve by the path as well)
Then I installed the xcode command line tool... and delete the bashrc. The problem gone...
So... the solution is install xcode command line tool.
Because xcode command line tool will install another version of git under /usr/bin folder.
The git environment before is under /usr/local/git/bin, this version don't need to set the path.
Feng
没有评论:
发表评论