You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Because git-lfs.exe (64bit) is spawned as a child process of git.exe, it appears to be incapable of inheriting the ENV variables that are passed into the exec function. This leads to zombie background processes/memory leaks for handling applications such as Github Desktop when you need to perform commands like git lfs locks asking for user authentication for HTTP repos. Github Desktop uses the GIT_TERMINAL_PROMPT=0 environment variable hack to avoid this for vanilla Git. It functions properly if authentication is provided.
A simple, albeit not the most efficient, solution is to perform an args.includes('lfs') check and have it handled differently.
The text was updated successfully, but these errors were encountered:
Actually, this might not even be in Dugite's wheelhouse. GIT_TERMINAL_PROMPT isn't respected at all by git-lfs no matter what version I try when calling from Node. The ENV is all reading correctly, and the GIT_TERMINAL_PROMPT does work if I run tests in the shell, so I'm unsure what's going on there.
I'm expanding the LFS functionality for Github Desktop, so I'm a little uneasy about there being a leak . My short-term hack solution (aside from assuming people have credentials setup), is going to involve using the stdin from the spawner to force-fail any login prompt if credentials are set.
chasse20
changed the title
GitLFS does not receive ENV variables
GitLFS does not handle GIT_TERMINAL_PROMPT env
Jan 4, 2020
Because git-lfs.exe (64bit) is spawned as a child process of git.exe, it appears to be incapable of inheriting the ENV variables that are passed into the exec function. This leads to zombie background processes/memory leaks for handling applications such as Github Desktop when you need to perform commands like
git lfs locks
asking for user authentication for HTTP repos. Github Desktop uses theGIT_TERMINAL_PROMPT=0
environment variable hack to avoid this for vanilla Git. It functions properly if authentication is provided.A simple, albeit not the most efficient, solution is to perform an
args.includes('lfs')
check and have it handled differently.The text was updated successfully, but these errors were encountered: