skywind3000 / skywind3000/z.lua
clink's installscript not supported fully correctly
Nobody has claimed this yet.
- Dominant language
- Lua
- Stars
- 3.1k
- Forks
- 148
- PR merge metrics
- No merged PRs in 30d
Description
Hello, if you use clink's new better way to install modules, so: clink installscripts C:\path\to\z.lua\, z.lua works mostly fine, except for one small issue. Every time you launch cmd you see this annoying error at the top:
...cations\Plugins\Windows\System\clink\z.lua\test_path.lua:1: module 'z' not found:
no field package.preload['z']
no file 'D:\Backups\Applications\Plugins\Windows\System\clink\clink-completions\modules/z.lua'
no file 'C:\Program Files (x86)\Lua\5.1\lua\z.luac'
no file 'C:\Windows\system32\z.dll'
no file 'C:\Windows\system32\loadall.dll'
no file '.\z.dll'
Basically what happens is that clink installscripts only accepts dirs not files, so you provide a path which also contains test_path.lua file and that file doesn't work well when it's initialized in clink.
The fix would be to move test_path.lua to a separate directory, e.g. modules or helpers or something, as clink installscripts ignores subdirectories. I'm not sure what the file does though (well, it tests the path, but I don't know under which circumstances, I can't see any references) and why it's in the root of the project.
EDIT: oh, from the commit history I see it's some kind of a test/helper. So moving it shouldn't be any sort of a problem.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the root-level test_path.lua and inspect how clink installscripts initializes files in the z.lua installation directory. Move the test/helper file into a subdirectory ignored by clink installscripts, then verify that launching cmd no longer reports the missing z module error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- lua
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100