After opening a .zig file, line 40 of fplugin/zig.vim clobbers the path variable causing the vim fuzzy finder (:find) to start looking in the std lib directory instead of the cwd.
Plugin clobbers the path variable, breaking fuzzy finding #54
Seems like @LemonBoy added this behavior. I want to ask them what their intention was before thinking about removing it
I only added some more error checking around that logic, I guess whoever added that wanted gf to work on import statements.
@SamTebbs33 Did you try swapping, ie to write in ftplugin/zig.vim
let &l:path= &l:path . ',' . json_decode(s:env)['std_dir']
Vim/Neovim should then first look in the current path.
For anyone else impacted by this, you can fix it by altering line 47 in ftplugin/zig.vim (just swap the path priority)
Change it from:
let &l:path = g:zig_std_dir . ',' . &l:path
To:
let &l:path = &l:path . ',' . g:zig_std_dir
I think this should be closed, since the issue author gave no feedback, if the suggested solution worked or clarify why not.
https://ziglang.org/news/announcing-donor-bounties
Observed behavior contradicts documented or intended behavior.
This issue is limited in scope and/or knowledge of project internals.
An issue with a third-party project that uses this project.
Solving this issue will likely involve adding new logic or components to the codebase.
An issue related to project infrastructure, e.g. continuous integration.
A task to improve performance and/or resource usage.
No questions on the issue tracker; use a community space instead.
A bug that did not occur in a previous version.
An issue with a third-party project that this project uses.
No due date set.
No dependencies set.
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?