feature<Linux>: try to support Linux

This commit is contained in:
leo 2024-02-22 12:26:01 +08:00
parent 79084c9a9a
commit cf09ab463c
3 changed files with 87 additions and 1 deletions

View file

@ -1,6 +1,5 @@
using System;
using System.Diagnostics;
using System.IO;
namespace SourceGit.Native {
public static class OS {
@ -31,6 +30,9 @@ namespace SourceGit.Native {
} else if (OperatingSystem.IsWindows()) {
_backend = new Windows();
VSCodeExecutableFile = _backend.FindVSCode();
} else if (OperatingSystem.IsLinux()) {
_backend = new Linux();
VSCodeExecutableFile = _backend.FindVSCode();
} else {
throw new Exception("Platform unsupported!!!");
}