Closed ptn closed 5 months ago
I tried downgrading neovim to 0.9 and the error persists.
Having the same issue.
Hi @ptn , @bdemirtas , could you guys provide me output of this command brew doctor
.
This error happen because LD_LIBRARY_PATH isn't set up correctly. You should have this line in ~/.zprofile
file eval "$(/opt/homebrew/bin/brew shellenv)"
Hi @SuperBo thanks to answering quickly. In my case, I'm on Fedora and I have libgit2 installed. Here's a screenshot of what I'm getting.
Output of brew doctor
, before doing that change to .zprofile:
~ % 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: A newer Command Line Tools release is available.
Update them from Software Update in System Settings.
If that doesn't show you any updates, run:
sudo rm -rf /Library/Developer/CommandLineTools
sudo xcode-select --install
Alternatively, manually download them from:
https://developer.apple.com/download/all/.
You should download the Command Line Tools for Xcode 15.1.
Warning: Some installed formulae are deprecated or disabled.
You should find replacements for the following formulae:
ilmbase
openssl@1.1
python@3.8
Warning: Unbrewed header files were found in /usr/local/include.
If you didn't put them there on purpose they could cause problems when
building Homebrew formulae and may need to be deleted.
Unexpected header files:
/usr/local/include/python3.8/greenlet/greenlet.h
Warning: You have unlinked kegs in your Cellar.
Leaving kegs unlinked can lead to build-trouble and cause formulae that depend on
those kegs to fail to run properly once built. Run `brew link` on these:
ctags
node
Adding that line to .zprofile did not fix the issue, I am getting the same as the screenshot posted above.
@ptn , for you case, can you help me run these command then test whether Fugit2 works?
export LIBRARY_PATH="$LIBRARY_PATH:$(brew --prefix)/lib"
export LD_LIBRARY_PATH="$(brew --prefix)/lib${LD_LIBRARY_PATH:+:"${LD_LIBRARY_PATH}"}"
export DYLD_LIBRARY_PATH="$DYLD_LIBRARY_PATH:$(brew --prefix)/lib"
nvim
hi @ptn, please update to latest version then setting this to your config. Please make sure library file is on your system ls /opt/homebrew/lib/libgit2.dylib
{
"SuperBo/fugit2.nvim",
opts = {
libgit2_path = "/opt/homebrew/lib/libgit2.dylib",
width = 140,
},
config = true,
dependencies = {
"MunifTanjim/nui.nvim",
"nvim-tree/nvim-web-devicons",
"nvim-lua/plenary.nvim",
},
}
and for @bdemirtas case with Fedora, I updated README section for Fedora, please test it to verify it works or not. https://github.com/SuperBo/fugit2.nvim#fedora
You're fantastic, it's working.
The path in fedora for libgit it's /usr/lib64/libgit2.so.1.7.2
in case you would like to add in the readme.
Now I will be able to play with.
Thanks
@bdemirtas, based on testing env (fedora docker), just setting to "libgit2.so.1.7.2" or "libgit2.so.1.7" also works :D
It works! I had to use a different path though:
opts = {
libgit2_path = "/usr/local/opt/libgit2/lib/libgit2.dylib",
width = 140,
},
@ptn , thank you, I will add it to README
Did you check docs and existing issues?
Neovim version (nvim -v)
NVIM v0.10.0-dev-2960+g52d2851ca-Homebrew
Operating system/version
Sonoma 14.4.1
Describe the bug
After installing and triggering my keymap, I get the following error:
Here's my config via lazy.vim:
Libgit2 is indeed installed:
Steps To Reproduce
Expected Behavior
I expect the Fugit2 UI to appear, instead I get an error and the UI does not show.