New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
'git-lfs' was not found on your path in SourceTree #853
Comments
There's a similar bug filed in #846. I think you'll have to go to SourceTree support. I have no idea how it manages its git version and paths. |
@pprochazka72 I had the same problem and received the same error message using Source Tree 1.8.2.2 on Windows. For me the solution was to open the Source Tree Terminal window and inspect the paths and locations of files there. Ultimately I copied the git-lfs executable into one of the folders being searched on the path. To help troubleshoot the path I injected more output into the error message window by editing the script file mentioned by the error message: '.git/hooks/pre-push' and added the command 'which git-lfs' to the output. It spit out a list of paths being searched. I copied the git-lfs executable into one of those. These are steps to help troubleshoot. I won't specify any more granularity because the environments differ and this information should be enough to help some other people having the same issue. |
I delete .git/hooks/pre-push in my local repository and it worked for me |
@chocolim delete .git/hooks/pre-push means you will not use git-lfs. You will just commit your large file into your git repository. |
@pprochazka72 You may config SourceTree use git within it self. ln /Applications/SmartGit.app/Contents/Resources/git/bin/git-lfs /Applications/GitHub\ Desktop.app/Contents/Resources/git-lfs/bin/git-lfs |
Very clever and thank k8nd sir. Sent from my Samsung Galaxy smartphone.-------- Original message --------From: 勤 notifications@github.com Date: 2016-04-28 11:04 PM (GMT-07:00) To: github/git-lfs git-lfs@noreply.github.com Subject: Re: [github/git-lfs] 'git-lfs' was not found on your path in Your SourceTree will not find git-lfs in your system PATH. I use SmartGit, and I use follow command to make git-lfs available for my SmartGit. You can modify it for your SourceTree ln /Applications/SmartGit.app/Contents/Resources/git/bin/git-lfs /Applications/GitHub\ Desktop.app/Contents/Resources/git-lfs/bin/git-lfs — |
For SmartGit 8 and git-lfs installed via brew I used the following command to make git-lfs available to SmartGit:
|
@chocolim Thank you it works for me! |
Removing file .git/hooks/pre-push solved this problem |
installation guide is here : https://git-lfs.github.com/ . Just download and follow the instructions to install git-lfs on your local |
deleting: .git/hooks/pre-push solves the problem immediatly. |
SmartGit 8.0.5 does not have git-lfs inside. Also it has some weird internal PATH:
To make it see my HomeBrew git-lfs I had to run
Is there any doc explaining where SmartGit searches for git-lfs provided we use externa git executable? |
@diophung Thank you it works for me! |
Funny, for me it says "This repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting .git/hooks/post-checkout." |
**Don't delete: .git/hooks/pre-push ** That just turns off LFS - and will cause issues if you're submitting to a shared repository. It's much better to resolve the errors by linking LFS as other posters have outlined above. Of course if you never intended to use LFS then removing LFS hooks is reasonable. |
execute this command |
This solved for me |
This returns "ln: /usr/local/git/libexec/git-core/git-lfs: No such file or directory" for me. I have no git directory in "/usr/local/git/". |
I downloaded Github for MAC OS and setup git lfs for my repo. All works great when I am using my repo with Github MAC app. When I open the same repo with SourceTree and push to remote, I get the following error:
This repository is configured for Git LFS but 'git-lfs' was not found on your path. If you no longer wish to use Git LFS, remove this hook by deleting .git/hooks/pre-push.
I know that my SourceTree app is using the System Git version. How do I set the 'git-lfs' into my path? And why does 'git-lfs' complains in one client and not in the other one?
The text was updated successfully, but these errors were encountered: