csharpdeeb25a2 | 1 | using System.Diagnostics; |
| 2 | using System.Text; |
| 3 | |
| 4 | namespace CascadeIDE.Features.Build.DataAcquisition; |
| 5 | |
| 6 | /// <summary>Кодировка stdout/stderr для <c>dotnet</c> CLI (согласовано с LSP/ACP хостами и dotnet-build-test-mcp).</summary> |
| 7 | internal static class DotnetProcessIoEncoding |
| 8 | { |
| 9 | internal static readonly Encoding Utf8NoBom = new UTF8Encoding(encoderShouldEmitUTF8Identifier: false); |
| 10 | |
| 11 | internal static void ApplyUtf8(ProcessStartInfo psi) |
| 12 | { |
| 13 | ArgumentNullException.ThrowIfNull(psi); |
| 14 | psi.StandardOutputEncoding = Utf8NoBom; |
| 15 | psi.StandardErrorEncoding = Utf8NoBom; |
| 16 | } |
| 17 | } |
| 18 | |
View only · write via MCP/CIDE