Skip to content

Commit 6e33593

Browse files
committed
pytest_plugin(fix[set_gitconfig]): Add GIT_CONFIG_GLOBAL for child processes
why: GIT_CONFIG is excluded from child process environment by git what: - Add GIT_CONFIG_GLOBAL env var which IS inherited by child processes - Fixes submodule operations in strict build environments
1 parent 7f1b465 commit 6e33593

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/libvcs/pytest_plugin.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -180,6 +180,7 @@ def set_gitconfig(
180180
) -> pathlib.Path:
181181
"""Set git configuration."""
182182
monkeypatch.setenv("GIT_CONFIG", str(gitconfig))
183+
monkeypatch.setenv("GIT_CONFIG_GLOBAL", str(gitconfig)) # For child processes
183184
return gitconfig
184185

185186

0 commit comments

Comments
 (0)