Skip to content

Commit

Permalink
fix: expand the command path
Browse files Browse the repository at this point in the history
  • Loading branch information
lopi-py committed Aug 14, 2024
1 parent 3014ae6 commit ec1f20c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lua/conform/runner.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ M.build_cmd = function(formatter_name, ctx, config)
if type(command) == "function" then
command = command(config, ctx)
end
local exepath = vim.fn.exepath(command)
if exepath ~= "" then
command = exepath
end
---@type string|string[]
local args = {}
if ctx.range and config.range_args then
Expand Down

0 comments on commit ec1f20c

Please sign in to comment.