-
Notifications
You must be signed in to change notification settings - Fork 29
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
add rockspec #136
add rockspec #136
Conversation
teto
commented
May 31, 2022
- add rockspec: sqlite is a dependency but I chose not to expose it
- hack to fix tests: wouldn't it be simpler to use the envvar in all cases ?
so that the package can be published on luarocks, describes dependencies, and can be redistributed in distributions too.
hey @teto, do you mean to say that this env var is auto set? or users need to set it manually in there zsh/bash config? |
Currently the ci tests failing for two reason:
|
I tried to make unrelated but would also be nice to have a vim.health script to check sqlite is correctly loaded. |
In that case, how about if not vim, try to read path from env var? or regardless if not set then read from env var. That way users may have the freedom to pick either one.
Definitely it would, can you open an issue so we can later implement |
this should be more acceptable.
sry I didn't check those, could you rerun the workflow so I have a look please ? |
LGTM, I will fix test later, in another pr along with ci issues |
I've added a makefile target to run stylua locally so that I could fix the issues. The problem is that the stylua version I use locally may be different than the one on the CI. Since you are a nix user, would you mind if I added a flake just for development ? to get lualint/stylint and correctly export LIBSQLITE ? |
Not at all. I like where this is going. |
I've added the flake, running |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm seeing luacheck and style lua still failing but for absolute nonsense it should have been warning instead of errors
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @teto
sqlite.lua-scm-1.rockspec
Outdated
tag = "master" | ||
} | ||
dependencies = { | ||
"plenary.nvim" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh wait, sqlite.lua doesn't depend on plenary only on luv, have you seen script/gen_rockspec.lua
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I had seen it then forgot about it when I resumed the PR xD I've submitted an update that adds plenary as a test dependency though. It won't work because plenary is not in the root manifest of luarocks.org but I think this can be done with the help of @tjdevries
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
😆 no worries, @teto what do u mean by it won't work .., isn't plenary up in luarocks and https://github.com/nvim-lua/plenary.nvim/blob/master/plenary.nvim-scm-1.rockspec? or is it having as test dependency breaking t?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
luarocks test ./sqlite-master-0.rockspec
Missing dependencies for sqlite master-0:
plenary.nvim (not installed)
sqlite master-0 depends on plenary.nvim (not installed)
Installing https://luarocks.org/plenary.nvim-scm-1.rockspec
fails .
adding my manifest fixes it (https://luarocks.org/modules/teto/plenary.nvim) but it is not scalable so I wonder if I should manage plenary myself or if @tjdevries has enough time/interest to do it (or another maintainer) .
I think it's fine to merge as is as luarocks install ./sqlite-master-0.rockspec --tree /tmp
keeps working
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've just pushed a linting fix. I think it would be best to have the CI use the flake to run the code rather than CI actions. We would have the same results locally as on github + it would work on other CI/CD pipelines without limiting oneself to github. but that's a suggestion.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, the CI setup was pre getting into nix. this would make things a lot simpler and won't have this out sync issue.
vim would only care about vim.g.sqlite_clib_path.
to be able to run mae lint/make lualint quickly
and improve makefile dependencies