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

Automatically Install Luarocks Packages #1

Open
MasterTemple opened this issue Aug 21, 2023 · 4 comments
Open

Automatically Install Luarocks Packages #1

MasterTemple opened this issue Aug 21, 2023 · 4 comments

Comments

@MasterTemple
Copy link
Owner

The extension should automatically install lsqlite3 and dkjson.

@DevelopmentIntensified
Copy link

#3

@FreeKev
Copy link

FreeKev commented Jun 26, 2024

The extension should automatically install lsqlite3 and dkjson.

Ah yes. Should alternatively or additionally update the README to account for what needs to be installed.

E5108: Error executing lua ...i/lazy/telescope.nvim/lua/telescope/_extensions/in
it.lua:10: 'bible' extension doesn't exist or isn't installed: ...bible.nvim/lua
/telescope/_extensions/bible/reference.lua:1: module 'lsqlite3' not found:
no field package.preload['lsqlite3']

On another note - this looks great! Thank you for your work @MasterTemple

@MasterTemple
Copy link
Owner Author

@FreeKev Thanks to Claude, I learned that the necessary packages can be automatically installed with Lazy.nvim by adding this plugin:

{
	"nvim-lua/plenary.nvim",
	dependencies = {
		{
			"theHamsta/nvim_rocks",
			build = "pip3 install --user hererocks && python3 -mhererocks . -j2.1.0-beta3 -r3.0.0 && cp nvim_rocks.lua lua",
			config = function()
				local nvim_rocks = require("nvim_rocks")
				nvim_rocks.ensure_installed("lsqlite3")
				nvim_rocks.ensure_installed("dkjson")
			end,
		},
	},
},

I will update the README.

@MasterTemple
Copy link
Owner Author

It seems to give me this error:

Unable to load the luarocks package loader. Try re-running the build stage (`:Lazy build luarocks.nvim`). Full trace: ...cal/share/nvim/lazy/nvim_rocks/lua/luarocks/core/cfg.lua:713: attempt
 to concatenate field 'LUA_BINDIR' (a nil value)
Press ENTER or type command to continue

but it does at least work when I dismiss the error message.

I need to figure out if I should resolve the error or if I should just hide it.

@MasterTemple MasterTemple reopened this Jul 17, 2024
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

No branches or pull requests

3 participants