posh-git messes with the HOME environment variable #718
Closed
Description
This happens with posh-git 1.0.0 beta, and possibly earlier. We have the following lines in the psm1:
if (!$Env:HOME) { $Env:HOME = "$Env:HOMEDRIVE$Env:HOMEPATH" }
if (!$Env:HOME) { $Env:HOME = "$Env:USERPROFILE" }
This is a problem if the HOME variable wasn't previously set, as it may affect various unrelated programs.
In our particular case we have USERPROFILE pointing to the local C:\Users\name as usual, and HOMEDRIVE set to a mapped network drive. Some programs might default to HOME, then USERPROFILE then HOMEDRIVE, which is now reversed after posh-git has been imported.
posh-git shouldn't mess with important environment variables that affect other things than Git.
Metadata
Assignees
Labels
No labels