From 9a1e95b7e502f792b3de210f495a011720c75fd1 Mon Sep 17 00:00:00 2001 From: Chiahong Hong Date: Thu, 22 Aug 2024 02:09:34 +0800 Subject: [PATCH] fix: handle file paths with spaces --- src/Native/Windows.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Native/Windows.cs b/src/Native/Windows.cs index a48efe0a..18326fa6 100644 --- a/src/Native/Windows.cs +++ b/src/Native/Windows.cs @@ -203,7 +203,7 @@ namespace SourceGit.Native public void OpenWithDefaultEditor(string file) { var info = new FileInfo(file); - var start = new ProcessStartInfo("cmd", $"/c start {info.FullName}"); + var start = new ProcessStartInfo("cmd", $"/c start \"\" \"{info.FullName}\""); start.CreateNoWindow = true; Process.Start(start); }