diff --git a/contrib/automation/hgautomation/aws.py b/contrib/automation/hgautomation/aws.py --- a/contrib/automation/hgautomation/aws.py +++ b/contrib/automation/hgautomation/aws.py @@ -191,6 +191,10 @@ $Setting = 'LocalAccountTokenFilterPolicy' Set-ItemProperty -Path $Key -Name $Setting -Value 1 -Force +# Avoid long usernames in the temp directory path because the '~' causes extra quoting in ssh output +[System.Environment]::SetEnvironmentVariable('TMP', 'C:\Temp', [System.EnvironmentVariableTarget]::User) +[System.Environment]::SetEnvironmentVariable('TEMP', 'C:\Temp', [System.EnvironmentVariableTarget]::User) + # Configure and restart the WinRM Service; Enable the required firewall exception Stop-Service -Name WinRM Set-Service -Name WinRM -StartupType Automatic