diff --git a/lib/git-environment.ts b/lib/git-environment.ts index ae4f4a57..4eb57a44 100644 --- a/lib/git-environment.ts +++ b/lib/git-environment.ts @@ -103,6 +103,10 @@ export function setupEnvironment( } } + if (process.platform !== 'win32' && !env.GIT_CONFIG_SYSTEM) { + env.GIT_CONFIG_SYSTEM = path.join(gitDir, 'etc', 'gitconfig') + } + if (process.platform === 'darwin' || process.platform === 'linux') { // templates are used to populate your .git folder // when a repository is initialized locally