tags:

views:

129

answers:

1

Hello, upon cloning a git repository, I get an error message that I can't quite grasp.

$ git clone [email protected]:group07
Initialized empty Git repository in /cygdrive/C/Users/Martin Bigler/p2/group07/.
remote: Counting objects: 2269, done.
remote: Compressing objects: 100% (1936/1936), done.
git: 'index-pack' is not a git-command. See 'git --help'.

What could possibly cause this behavior?

+1  A: 

Is this similar to ticket 269?

git index-pack isn't a built-in in git.exe, so git.exe needs to find git-index-pack.exe in $GIT_EXEC_PATH (which should usually be "/libexec/git-core/"). Do you have "/libexec/git-core/git-index-pack.exe"?

Because if it is, this is the server which causes the error, not the locally installed git doing the push.

You can try logging interactively and check index-pack is available:

$ ssh git#***.com@***.com
Enter passphrase for key '/c/Users/***/.ssh/id_rsa':
Last login: Tue Feb  9 13:48:32 2010 from ***
-bash-3.2$ git version
git version 1.6.1
-bash-3.2$ git-index-pack
usage: git index-pack [-v] [-o <index-file>] [{ ---keep | --keep=<msg> }] [--strict] 
{ <pack-file> | --stdin [--fix-thin] [<pack-file>] }

That test prompted the following answer:

Your git-index-pack is found when logging in interactively.
But apparently not when you do not log in interactively.
That suggests that you adjusted your PATH appropriately in $HOME/.profile or $HOME/.bash_profile, but not in HOME/.bashrc

And the conclusion:

My solution is:

ssh user@server
cp .bash_profile .bashrc
VonC