mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-03 17:56:44 +02:00
This commit is contained in:
committed by
GitHub
parent
979d3c6011
commit
7b280ebde1
@@ -35,7 +35,7 @@ namespace Community.PowerToys.Run.Plugin.VSCodeWorkspaces.RemoteMachinesHelper
|
||||
|
||||
try
|
||||
{
|
||||
JsonElement vscodeSettingsFile = JsonSerializer.Deserialize<JsonElement>(fileContent);
|
||||
JsonElement vscodeSettingsFile = JsonSerializer.Deserialize<JsonElement>(fileContent, new JsonSerializerOptions() { AllowTrailingCommas = true, ReadCommentHandling = JsonCommentHandling.Skip });
|
||||
if (vscodeSettingsFile.TryGetProperty("remote.SSH.configFile", out var pathElement))
|
||||
{
|
||||
var path = pathElement.GetString();
|
||||
|
||||
@@ -21,7 +21,7 @@ namespace Community.PowerToys.Run.Plugin.VSCodeWorkspaces.SshConfigParser
|
||||
|
||||
public static IEnumerable<SshHost> Parse(string str)
|
||||
{
|
||||
str = str.Replace('\r', '\0');
|
||||
str = str.Replace("\r", string.Empty);
|
||||
var list = new List<SshHost>();
|
||||
foreach (Match match in _sshConfig.Matches(str))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user