Skip to content

The agent that grows with you

fix(activate.ps1): force UTF-8 console and cmdlet encoding

ethernet612ce5b5a9ed
diff --git a/activate.ps1 b/activate.ps1
index 75ebdf7695c..7aaa9d9d9cb 100755
--- a/activate.ps1
+++ b/activate.ps1
@@ -1,5 +1,9 @@
# Source this file to sync and apply the PM environment; deactivate restores it.
$ErrorActionPreference = 'Stop'
+
+$OutputEncoding = [System.Console]::OutputEncoding = [System.Console]::InputEncoding = [System.Text.Encoding]::UTF8
+$PSDefaultParameterValues['*:Encoding'] = 'utf8'
+
$repo = $PSScriptRoot
$bootstrapSaved = @{}
foreach ($key in @('PYTHONPATH', 'PYTHONHOME', 'VIRTUAL_ENV')) {