Skip to content

Commit

Permalink
feat(config): add validation that luarocks binary is executable
Browse files Browse the repository at this point in the history
  • Loading branch information
mrcjkb committed Jun 11, 2024
1 parent f726d3a commit 09c93f1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lua/rocks/config/check.lua
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@ function check.validate(cfg)
if not ok then
return false, err
end
if vim.fn.executable(cfg.luarocks_binary) ~= 1 then
return false, ("Cannot execute %s"):format(cfg.luarocks_binary)
end
return true
end

Expand Down

0 comments on commit 09c93f1

Please sign in to comment.