refactor(git): extract repo.resolve_cwd helper
This commit is contained in:
+1
-5
@@ -189,11 +189,7 @@ end
|
||||
|
||||
---@param args string[]
|
||||
function M.run(args)
|
||||
local path = vim.api.nvim_buf_get_name(0)
|
||||
if path == "" then
|
||||
path = vim.fn.getcwd()
|
||||
end
|
||||
local _, worktree = repo.resolve(path)
|
||||
local _, worktree = repo.resolve_cwd()
|
||||
if not worktree then
|
||||
log.warning("not in a git repository")
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user