I'm getting errors when cloning a repository with a Git LFS filter using Eclipse eGit.
git-lfs 2.4.0 is installed via brew and in the usual location.
$ which git-lfs
/usr/local/bin/git-lfs
Cloning over HTTPS on the command line works fine.
$ git clone https://...@bitbucket.org/.../<repos>.git
Cloning into '<repos>'...
remote: Counting objects: 3453, done.
remote: Compressing objects: 100% (2289/2289), done.
remote: Total 3453 (delta 1073), reused 3328 (delta 1009)
Receiving objects: 100% (3453/3453), 7.33 MiB | 374.00 KiB/s, done.
Resolving deltas: 100% (1073/1073), done.
Checking out files: 100% (3070/3070), done.
Filtering content: 100% (309/309), 197.75 MiB | 1.80 MiB/s, done.
When cloning with Eclipse Oxygen 4.7.3a and Eclipse eGit 4.9.2, the clone operation works fine, but there is an error when it gets to retrieving LFS assets:
org.eclipse.jgit.api.errors.FilterFailedException:
Execution of filter command 'git-lfs smudge -- '<file1>'' on file '<file1>'
failed with return code '127', message on stderr:
'git-lfs smudge -- '<file1>': git-lfs: command not found'
org.eclipse.jgit.api.errors.FilterFailedException:
Execution of filter command 'git-lfs smudge -- '<file2>'' on file '<file2>'
failed with return code '127', message on stderr:
'git-lfs smudge -- '<file2>': git-lfs: command not found'
It seems that git-lfs
in /usr/local/bin
is not discovered. If I open a Eclipse terminal, echo $PATH
prints:
/usr/bin:/bin:/usr/sbin:/sbin
However, from a standard terminal, echo $PATH
prints:
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
Do I need to add /usr/local/bin
to the path that eGit sees? If so, how can that be done?
3 of my colleagues have the same issue and I'm working from a new install of Eclipse IDE for C/C++ Developers.