Commit 1781e3f
committed
fix: properly implement UTF-8 support for Windows terminals
- Add LANG and LC_ALL environment variables for UTF-8 encoding
- Prepend 'chcp 65001' command on Windows to set code page to UTF-8
- Handle both PowerShell and CMD syntax for code page switching
- Remove incorrect CHCP environment variable approach
- Update tests to reflect the corrected implementation
This properly fixes non-ASCII characters (Cyrillic, Chinese, Hindi, etc.)
being displayed as '?' or diamond symbols in terminal output on Windows.
Fixes #85301 parent f30e88e commit 1781e3f
File tree
3 files changed
+16
-46
lines changed- src/integrations/terminal
- __tests__
3 files changed
+16
-46
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
165 | 165 | | |
166 | 166 | | |
167 | 167 | | |
168 | | - | |
169 | | - | |
170 | | - | |
171 | | - | |
172 | | - | |
173 | 168 | | |
174 | 169 | | |
175 | 170 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
114 | 114 | | |
115 | 115 | | |
116 | 116 | | |
117 | | - | |
118 | | - | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
119 | 130 | | |
| 131 | + | |
120 | 132 | | |
121 | 133 | | |
122 | 134 | | |
| |||
126 | 138 | | |
127 | 139 | | |
128 | 140 | | |
129 | | - | |
130 | | - | |
131 | | - | |
132 | | - | |
133 | 141 | | |
134 | 142 | | |
| 143 | + | |
| 144 | + | |
135 | 145 | | |
136 | 146 | | |
137 | 147 | | |
| |||
Lines changed: 0 additions & 35 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
126 | 126 | | |
127 | 127 | | |
128 | 128 | | |
129 | | - | |
130 | | - | |
131 | | - | |
132 | | - | |
133 | | - | |
134 | | - | |
135 | | - | |
136 | | - | |
137 | | - | |
138 | | - | |
139 | | - | |
140 | | - | |
141 | | - | |
142 | | - | |
143 | | - | |
144 | | - | |
145 | | - | |
146 | | - | |
147 | | - | |
148 | | - | |
149 | | - | |
150 | | - | |
151 | | - | |
152 | | - | |
153 | | - | |
154 | | - | |
155 | | - | |
156 | | - | |
157 | | - | |
158 | | - | |
159 | | - | |
160 | | - | |
161 | | - | |
162 | | - | |
163 | | - | |
164 | 129 | | |
165 | 130 | | |
0 commit comments