fix: get abs path (#1232)

This commit is contained in:
yetone 2025-02-10 02:08:58 +08:00 committed by GitHub
parent 26e40e5483
commit 59fdbd72a4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -7,6 +7,7 @@ local M = {}
---@param rel_path string
---@return string
local function get_abs_path(rel_path)
if Path:new(rel_path):is_absolute() then return rel_path end
local project_root = Utils.get_project_root()
return Path:new(project_root):joinpath(rel_path):absolute()
end