Skip to content

Commit

Permalink
feat: add option to auto set up luarocks on the user's machine
Browse files Browse the repository at this point in the history
  • Loading branch information
vhyrro committed Nov 27, 2023
1 parent 07f006d commit 1895d67
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion installer.lua
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,8 @@ Once you start editing a value, you may exit it by pressing Enter or by clicking
Rocks installation path: [install_path:50:{{vim.fs.joinpath(vim.fn.stdpath('data'), "rocks")}}]
Should rocks.nvim set up luarocks?: [setup_luarocks:5:{{vim.fn.executable('luarocks') == 0}}]
]],
"\n",
{ plain = true }
Expand Down Expand Up @@ -140,7 +142,7 @@ local function install()

if start then
-- Attempt to execute the code that will give us the default value
default_value = assert(loadstring("return " .. default_value))()
default_value = assert(loadstring("return tostring(" .. default_value .. ")"))()

-- Create necessary padding for the input window and recenter the line where we placed the new window.
acquire_buffer_lock(buffer, function()
Expand Down

0 comments on commit 1895d67

Please sign in to comment.