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

Bad compatibility with Oil file explorer #24

Closed
Drowze opened this issue May 21, 2024 · 1 comment · Fixed by #26
Closed

Bad compatibility with Oil file explorer #24

Drowze opened this issue May 21, 2024 · 1 comment · Fixed by #26

Comments

@Drowze
Copy link

Drowze commented May 21, 2024

Oil is an alternative file explorer for Neovim that lets you edit the filesystem inside a normal buffer. The buffer has the type oil and is named oil:///<file path> (or, I believe, oil-ssh:///<file path>, since Oil also has ssh support)

The issue is that since the Oil opens directories in simple buffers, vim-helm calls this function on them (also, I'm not sure why, but findfile("Chart.yaml", expand('%:p:h').';') is always returning something, regardless of the current directory being emtpy. i.e. if I'm on an empty /foo directory and I call findfile("Chart.yaml", expand('%:p:h').';') on it, it will return /foo/Chart.yaml)

Reproducing:

Considering a neovim installation with both Oil.nvim and vim-helm, and an empty directory /Users/foo, when I open that directory with nvim /Users/foo and execute:

:echo findfile("Chart.yaml", expand('%:p:h').';')

I see:
Screenshot 2024-05-21 at 10 44 42
(notice the filetype set to helm and the output of the findfile command)

@luisdavim
Copy link
Contributor

can you check #26 ?

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