Skip to content

Commit

Permalink
fix(git): unset GIT_DIR when spawning a process. Fixes #434
Browse files Browse the repository at this point in the history
  • Loading branch information
folke committed Jan 20, 2023
1 parent 75dcd57 commit 9858001
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lua/lazy/manage/process.lua
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,9 @@ function M.spawn(cmd, opts)
for key, value in
pairs(uv.os_environ() --[[@as string[] ]])
do
table.insert(env, key .. "=" .. value)
if key ~= "GIT_DIR" then
table.insert(env, key .. "=" .. value)
end
end

local stdout = uv.new_pipe()
Expand Down

0 comments on commit 9858001

Please sign in to comment.