Skip to content

Commit

Permalink
Update health functions to use non-deprecated versions.
Browse files Browse the repository at this point in the history
  • Loading branch information
acoffman authored and MagicDuck committed May 10, 2024
1 parent 3ff27f5 commit 105c0bc
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lua/grug-far/health.lua
Original file line number Diff line number Diff line change
Expand Up @@ -37,26 +37,26 @@ local check_binary_installed = function(package)
end

function M.check()
vim.health.report_start("Checking external dependencies")
vim.health.start("Checking external dependencies")

for _, dep in pairs(dependencies) do
for _, package in ipairs(dep.package) do
local installed, version = check_binary_installed(package)
if not installed then
local err_msg = ("%s: not found."):format(package.name)
if package.optional then
vim.health.report_warn(("%s %s"):format(err_msg,
vim.health.warn(("%s %s"):format(err_msg,
("Install %s for extended capabilities"):format(package.url)))
else
vim.health.report_error(
vim.health.error(
("%s %s"):format(
err_msg,
("`GrugFar` will not function without %s installed."):format(package.url)
)
)
end
else
vim.health.report_ok(("%s: found %s"):format(package.name, version))
vim.health.ok(("%s: found %s"):format(package.name, version))
end
end
end
Expand Down

0 comments on commit 105c0bc

Please sign in to comment.