Skip to content
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

lazygit not open file in nvim #32

Open
fecet opened this issue Dec 3, 2022 · 3 comments
Open

lazygit not open file in nvim #32

fecet opened this issue Dec 3, 2022 · 3 comments

Comments

@fecet
Copy link

fecet commented Dec 3, 2022

Press e at some lazygit file, neovim will be opened inside lazygit instead open it in original neovim like ranger

@raulbethencourt
Copy link

Same problem, but with xplr.

@niveK77pur
Copy link

vim-floaterm includes its own little binary/script which can be run from within a terminal to open said files into the current neovim instance. I see lazygit seems to open files using the $EDITOR (if set). I mention the vim-floaterm binary, because in this case we could set the EDITOR=floaterm and it will trick lazygit into opening the file into the current vim instance.

HOWEVER, I also found this section in the lazygit docs, which mentions nvim-remote. It allows to open the files in the current neovim instance as well, without intervention by this plugin here. I just gave it a try and it doesn't exactly work either (for me at least, not sure if my setup is problematic). When I launch :terminal and then open lazygit therein, then it opens (e) the file within my current neovim instance. However, when I open lazygit via this plugin it opens a nested neovim instance. I also had to alias my vim to nvr as this lazygit setting made it look for vim instead of nvr for some reason.

If anyone is interested, I'd be curious to know if you get this nvim-remote thing working for lazygit (maybe something is wrong in my setup)? If it does then that's great, this plugins seems to have gone stale for a year now.

@piersolenski
Copy link

Same for GitUI

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants