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

Rocks install gennaro-tedesco/nvim-peekup result confusing #427

Closed
teto opened this issue Jun 28, 2024 · 5 comments · Fixed by #445
Closed

Rocks install gennaro-tedesco/nvim-peekup result confusing #427

teto opened this issue Jun 28, 2024 · 5 comments · Fixed by #445

Comments

@teto
Copy link
Member

teto commented Jun 28, 2024

I was experimenting with the UX a bit and thought I would try Rocks install gennaro-tedesco/nvim-peekup see how it goes thinking rocsk.nvim would fetch from github or propose "do you want to install rocks-git.nvim" ?.

INFO | 2024-06-28 11:20:35 | ...ckages/start/rocks.nvim/lua/rocks/operations/helpers.lua:38 | Installing: gennaro-tedesco/nvim-peekup
INFO | 2024-06-28 11:20:35 | ...myNeovimPackages/start/rocks.nvim/lua/rocks/luarocks.lua:85 | { "luarocks", "--lua-version=5.1", "--tree=/home/teto/.local/share/nvim/rocks", "--server='https://luarocks.org/manifests/neorocks/'", "--server='https://nvim-neorocks.github.io/rocks-binaries/'", "install", "gennaro-tedesco/nvim-peekup" }
INFO | 2024-06-28 11:20:38 | ...ckages/start/rocks.nvim/lua/rocks/operations/helpers.lua:83 | Installed: gennaro-tedesco/nvim-peekup -> nil
INFO | 2024-06-28 11:20:38 | ...myNeovimPackages/start/rocks.nvim/lua/rocks/luarocks.lua:85 | { "luarocks", "--lua-version=5.1", "--tree=/home/teto/.local/share/nvim/rocks", "list", "--porcelain" }
INFO | 2024-06-28 11:20:38 | .../myNeovimPackages/start/rocks.nvim/lua/rocks/adapter.lua:39 | Creating symlink directory: nvim-peekup

Turns out this worked (no error) and looking at the rocks/ folder, it contains a fodler with lua files from nvim-peekup.
Now nvim-peelkup doesn't show in my rocks.toml so sounds like a bug (2.26.0).

The nil in Installed: gennaro-tedesco/nvim-peekup -> nil seems fishy.

The rockspec is at https://luarocks.org/modules/gennaro-tedesco/nvim-peekup

@mrcjkb
Copy link
Member

mrcjkb commented Jun 28, 2024

🤔 Perhaps it's picking up the luarocks.org user name?

@mrcjkb
Copy link
Member

mrcjkb commented Jul 1, 2024

🤔 Perhaps it's picking up the luarocks.org user name?

Yep, this is what's happening. We shouldn't support that, because it adds a whole load of complexity.
If needed, we can create a separate issue for installing from specific manifests. But I'd say YAGNI for now.

@teto
Copy link
Member Author

teto commented Jul 2, 2024

thanks for confirming the behavior.

We shouldn't support that, because it adds a whole load of complexity.

Maybe it's not something we can support now but the syntax could be useful. For instance if I fork a plugin and want to install my fork via rocks.nvim without pointing at a local dir (to test a patch for instance), how can/should I do that currently ? can I specify an alternate manifest than "roots" ?
Actually I didn't know luarocks accepted the user/package syntax, I was more thinking of a lazy/plug syntax that would fetch from github.
I haven't used rocks-git.nvim yet but does it support sthg like Rocks install user/package ?

@teto
Copy link
Member Author

teto commented Jul 2, 2024

answering my question about rocks-it:

The `:Rocks install {plugin} {args?}` command is extended by this module as follows:
 - `plugin`: The plugin, e.g. `owner/repo` or a git HTTPS/SSH URL.
             Can also be one of the following short hands (HTTPS only):
               - gitlab:owner/repo
               - sourcehut:owner/repo
               - github:owner/repo
               - codeberg:owner/repo

but I guess it will ignore any rockspec in that repo ?

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

Successfully merging a pull request may close this issue.

2 participants