Homebrew / brew

🍺 The missing package manager for macOS (or Linux)

Home Page:https://brew.sh

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

brew tap fails with git-lfs installed

mwf opened this issue · comments

Please note we will close your issue without comment if you delete, do not read or do not fill out the issue checklist below and provide ALL the requested information. If you repeatedly fail to use the issue template, we will block you from ever submitting issues to Homebrew again.

  • are reporting a bug others will be able to reproduce and not asking a question. If you're not sure or want to ask a question do so on our Discourse: https://discourse.brew.sh
  • ran a brew command and reproduced the problem with multiple formulae? If it's a problem with a single, official formula (not cask) please file this issue at Homebrew/homebrew-core: https://github.com/Homebrew/homebrew-core/issues/new/choose. If it's a brew cask problem please file this issue at https://github.com/Homebrew/homebrew-cask/issues/new/choose. If it's a tap (e.g. Homebrew/homebrew-php) problem please file this issue at the tap.
  • ran brew update and can still reproduce the problem?
  • ran brew doctor, fixed all issues and can still reproduce the problem?
  • ran brew config and brew doctor and included their output with your issue?

brew config

$ brew config
HOMEBREW_VERSION: 1.7.6
ORIGIN: https://github.com/Homebrew/brew
HEAD: f239b7a62790cfb4f33bda9aab7597d43f1b1e3b
Last commit: 5 days ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: 11b011c0e0f4133c9bdc653299f3181879018f3a
Core tap last commit: 2 hours ago
HOMEBREW_PREFIX: /usr/local
HOMEBREW_GIT: git
HOMEBREW_MACOS_VERSION_NUMERIC: 101306
CPU: quad-core 64-bit kabylake
Homebrew Ruby: 2.3.7 => /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/bin/ruby
Clang: 10.0 build 1000
Git: 2.17.1 => /Library/Developer/CommandLineTools/usr/bin/git
Curl: 7.54.0 => /usr/bin/curl
Java: N/A
macOS: 10.13.6-x86_64
CLT: 10.0.0.0.1.1535735448
CLT headers: N/A
Xcode: N/A
XQuartz: N/A

brew doctor - the Homebrew/homebrew-core is at stable branch, and doctor complains... Is it OK?

$ brew doctor
Please note that these warnings are just used to help the Homebrew maintainers
with debugging if you file an issue. If everything you use Homebrew for is
working fine: please don't worry or file an issue; just ignore this. Thanks!

Warning: Homebrew/homebrew-core is not on the master branch

Check out the master branch by running:
  git -C "$(brew --repo homebrew/core)" checkout master

I've installed git-lfs via brew install git-lfs and get problems with brew tap command after that.

$ brew tap johanhaleby/kubetail

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.

==> Tapping johanhaleby/kubetail
Cloning into '/usr/local/Homebrew/Library/Taps/johanhaleby/homebrew-kubetail'...
remote: Enumerating objects: 4, done.
remote: Counting objects: 100% (4/4), done.
remote: Compressing objects: 100% (4/4), done.
remote: Total 4 (delta 0), reused 3 (delta 0), pack-reused 0
Receiving objects: 100% (4/4), done.

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.

Error: Failure while executing; `git clone https://github.com/johanhaleby/homebrew-kubetail /usr/local/Homebrew/Library/Taps/johanhaleby/homebrew-kubetail --depth=1` exited with 2.

The problem reproduces with any tap.

And even brew update prints a warning.

$ brew update

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.


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.

could not detach HEAD
Updated 1 tap (homebrew/core).
==> Updated Formulae
yarn

git-lfs exists in my $PATH

$ which git-lfs
/usr/local/bin/git-lfs
$ ls -al /usr/local/bin/git-lfs
lrwxr-xr-x  1 ikorolev  staff  35 Sep 25 15:52 /usr/local/bin/git-lfs -> ../Cellar/git-lfs/2.5.2/bin/git-lfs

What am I doing wrong? :)

What am I doing wrong? :)

You have configured all repositories to use git-lfs. Adjust your configuration accordingly.

@MikeMcQuaid thanks, it worked!

git-lfs is a trap, because it recommends git lfs install, installing all the hooks globally...

If anyone ever finds this useful - just try:

git lfs uninstall
<cd to the repo, which uses lfs>
git lfs install --local